Zend\Filter\Inflector
Filter chain for string inflection
Synopsis
class Inflector
extends AbstractFilter
{
- // members
- protected FilterPluginManager $pluginManager;
- protected string $target;
- protected bool $throwTargetExceptionsOn;
- protected string $targetReplacementIdentifier;
- protected array $rules;
- // Inherited members from AbstractFilter
- protected array $options;
- // methods
- public void __construct()
- public FilterPluginManager getPluginManager()
- public self setPluginManager()
- public self setOptions()
- public self setThrowTargetExceptionsOn()
- public bool isThrowTargetExceptionsOn()
- public self setTargetReplacementIdentifier()
- public string getTargetReplacementIdentifier()
- public self setTarget()
- public string getTarget()
- public self setTargetReference()
- public self setRules()
- public self addRules()
- public array|false getRules()
- public FilterInterface|false getRule()
- public self clearRules()
- public self setFilterRule()
- public self addFilterRule()
- public self setStaticRule()
- public self setStaticRuleReference()
- public string filter()
- protected string _normalizeSpec()
- protected FilterInterface _getRule()
- // Inherited methods from AbstractFilter
- public static bool hasPcreUnicodeSupport()
- public self setOptions()
- public array getOptions()
- public mixed __invoke()
- protected static bool isOptions()
Hierarchy
Extends
Members
protected
- $options
—
array
Filter options - $pluginManager — Zend\Filter\FilterPluginManager
- $rules — array
- $target — string
- $targetReplacementIdentifier — string
- $throwTargetExceptionsOn — Zend\Filter\bool
Methods
protected
- _getRule() — Resolve named filters and convert them to filter objects.
- _normalizeSpec() — Normalize spec string
public
- __construct() — Constructor
- addFilterRule() — Add a filter rule for a spec
- addRules() — Multi-call to setting filter rules.
- clearRules() — Clears the rules currently in the inflector
- filter() — Inflect
- getPluginManager() — Retrieve plugin manager
- getRule() — Returns a rule set by setFilterRule(), a numeric index must be provided
- getRules() — Get rules
- getTarget() — Retrieve target
- getTargetReplacementIdentifier() — Get Target Replacement Identifier
- isThrowTargetExceptionsOn() — Will exceptions be thrown?
- setFilterRule() — Set a filtering rule for a spec. $ruleSet can be a string, Filter object or an array of strings or filter objects.
- setOptions() — Set options
- setPluginManager() — Set plugin manager
- setRules() — Is the same as calling addRules() with the exception that it clears the rules before adding them.
- setStaticRule() — Set a static rule for a spec. This is a single string value
- setStaticRuleReference() — Set Static Rule Reference.
- setTarget() — Set a Target ex: 'scripts/:controller/:action.:suffix'
- setTargetReference() — Set Target Reference
- setTargetReplacementIdentifier() — Set the Target Replacement Identifier, by default ':'
- setThrowTargetExceptionsOn() — Set Whether or not the inflector should throw an exception when a replacement identifier is still found within an inflected target.
Inherited from Zend\Filter\AbstractFilter
protected
public
- __invoke() — Invoke filter as a command
- getOptions() — Retrieve options representing object state
- hasPcreUnicodeSupport()
- setOptions()