PHP Class Horde_Core_Factory_TextFilter, horde

Copyright 2010-2016 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
Inheritance: extends Horde_Core_Factory_Base
Datei anzeigen Open project: horde/horde

Public Methods

Method Description
create ( string $driver, array $params = [] ) : Horde_Text_Filter_Base Return the Horde_Text_Filter_Base:: instance.
filter ( string $text, mixed $filters = [], mixed $params = [] ) : string Applies a set of patterns to a block of text.

Protected Methods

Method Description
_getDriver ( string $driver, array $params ) : array Gets the driver/params for a given base Horde_Text_Filter driver.

Method Details

_getDriver() protected method

Gets the driver/params for a given base Horde_Text_Filter driver.
protected _getDriver ( string $driver, array $params ) : array
$driver string Either a driver name, or the full class name to use.
$params array A hash containing any additional configuration parameters a subclass might need.
return array Driver as the first value, params list as the second.

create() public method

Return the Horde_Text_Filter_Base:: instance.
public create ( string $driver, array $params = [] ) : Horde_Text_Filter_Base
$driver string Either a driver name, or the full class name to use.
$params array A hash containing any additional configuration parameters a subclass might need.
return Horde_Text_Filter_Base The singleton instance.

filter() public method

Applies a set of patterns to a block of text.
public filter ( string $text, mixed $filters = [], mixed $params = [] ) : string
$text string The text to filter.
$filters mixed The list of filters (or a single filter).
$params mixed The list of params to use with each filter.
return string The transformed text.