Highway to PSR2
[openemr.git] / portal / patient / fwk / libs / savant / Savant3 / Filter.php
blobd983efb9ecace8925f9ad033e751061166c14ea8
1 <?php
3 /**
5 * Abstract Savant3_Filter class.
7 * @package Savant3
9 * @author Paul M. Jones <pmjones@ciaweb.net>
11 * @license http://www.gnu.org/copyleft/lesser.html LGPL
13 * @version $Id: Filter.php,v 1.5 2005/04/29 16:23:50 pmjones Exp $
17 /**
19 * Abstract Savant3_Filter class.
21 * You have to extend this class for it to be useful; e.g., "class
22 * Savant3_Filter_example extends Savant3_Filter".
24 * @package Savant3
26 * @author Paul M. Jones <pmjones@ciaweb.net>
30 abstract class Savant3_Filter
33 /**
35 * Optional reference to the calling Savant object.
37 * @access protected
39 * @var object
42 protected $Savant = null;
44 /**
46 * Constructor.
48 * @access public
50 * @param array $conf
51 * An array of configuration keys and values for
52 * this filter.
54 * @return void
57 public function __construct($conf = null)
59 settype($conf, 'array');
60 foreach ($conf as $key => $val) {
61 $this->$key = $val;
65 /**
67 * Stub method for extended behaviors.
69 * @access public
71 * @param string $text
72 * The text buffer to filter.
74 * @return string The text buffer after it has been filtered.
77 public static function filter($text)
79 return $text;