Documentation

Horde_Core_Factory_TextFilter extends Horde_Core_Factory_Base
in package

A Horde_Injector:: based Horde_Text_Filter_Base:: factory.

Copyright 2010-2017 Horde LLC (http://www.horde.org/)

See the enclosed file LICENSE for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.

Tags
category

Horde

author

Michael Slusarz slusarz@horde.org

license

http://www.horde.org/licenses/lgpl21 LGPL 2.1

Table of Contents

Properties

$_injector  : Horde_Injector
The injector.

Methods

__construct()  : mixed
Constructor.
create()  : Horde_Text_Filter_Base
Return the Horde_Text_Filter_Base:: instance.
filter()  : string
Applies a set of patterns to a block of text.
_getDriver()  : array<string|int, mixed>
Gets the driver/params for a given base Horde_Text_Filter driver.
_getDriverName()  : string
Return the classname of the driver to load.

Properties

$_injector

The injector.

protected Horde_Injector $_injector

Methods

__construct()

Constructor.

public __construct(Horde_Injector $injector) : mixed
Parameters
$injector : Horde_Injector

The injector to use.

create()

Return the Horde_Text_Filter_Base:: instance.

public create(string $driver[, array<string|int, mixed> $params = array() ]) : Horde_Text_Filter_Base
Parameters
$driver : string

Either a driver name, or the full class name to use.

$params : array<string|int, mixed> = array()

A hash containing any additional configuration parameters a subclass might need.

Tags
throws
Horde_Text_Filter_Exception
Return values
Horde_Text_Filter_Base

The singleton instance.

filter()

Applies a set of patterns to a block of text.

public filter(string $text[, mixed $filters = array() ][, mixed $params = array() ]) : string
Parameters
$text : string

The text to filter.

$filters : mixed = array()

The list of filters (or a single filter).

$params : mixed = array()

The list of params to use with each filter.

Return values
string

The transformed text.

_getDriver()

Gets the driver/params for a given base Horde_Text_Filter driver.

protected _getDriver(string $driver, array<string|int, mixed> $params) : array<string|int, mixed>
Parameters
$driver : string

Either a driver name, or the full class name to use.

$params : array<string|int, mixed>

A hash containing any additional configuration parameters a subclass might need.

Return values
array<string|int, mixed>

Driver as the first value, params list as the second.

_getDriverName()

Return the classname of the driver to load.

protected _getDriverName(string $driver, string $base) : string
Parameters
$driver : string

Driver name.

$base : string

The base classname.

Tags
throws
Horde_Exception
Return values
string

Classname.


        
On this page

Search results