eZPublishCommunityProject  2013.9
eZ\Publish\Core\Persistence\TransformationProcessor Class Reference

Interface for processing a set of transformations on a string. More...

+ Inheritance diagram for eZ\Publish\Core\Persistence\TransformationProcessor:

Public Member Functions

 __construct (PcreCompiler $compiler, array $ruleFiles=array())
 Construct instance of TransformationProcessor. More...
 
 transform ($string, array $ruleNames=array())
 Transform the given string. More...
 
 transformByGroup ($string, $ruleGroup)
 Transform the given string by group. More...
 

Public Attributes

const T_COMMENT = 1
 
const T_MAP = 11
 
const T_REPLACE = 12
 
const T_SECTION = 10
 
const T_TRANSPOSE = 13
 
const T_TRANSPOSE_MODULO = 14
 
const T_WHITESPACE = 2
 

Protected Member Functions

 getRules ()
 Loads rules. More...
 

Protected Attributes

 $compiledRules = null
 
 $compiler = null
 
 $ruleFiles = array()
 

Detailed Description

Interface for processing a set of transformations on a string.

Constructor & Destructor Documentation

eZ\Publish\Core\Persistence\TransformationProcessor::__construct ( PcreCompiler  $compiler,
array  $ruleFiles = array() 
)

Construct instance of TransformationProcessor.

Through the $ruleFiles array, a list of files with full text transformation rules is given.

Parameters
\eZ\Publish\Core\Persistence\TransformationProcessor\PcreCompiler$compiler
array$ruleFiles

Member Function Documentation

eZ\Publish\Core\Persistence\TransformationProcessor::getRules ( )
abstractprotected
eZ\Publish\Core\Persistence\TransformationProcessor::transform (   $string,
array  $ruleNames = array() 
)

Transform the given string.

Transform the given string using the given rules. If no rules are specified, all available rules will be used for the transformation.

Parameters
string$string
array$ruleNames
Returns
string
eZ\Publish\Core\Persistence\TransformationProcessor::transformByGroup (   $string,
  $ruleGroup 
)

Transform the given string by group.

Transform the given string using a rule group.

Parameters
string$string
string$ruleGroup
Returns
string

Member Data Documentation

eZ\Publish\Core\Persistence\TransformationProcessor::$compiledRules = null
protected
eZ\Publish\Core\Persistence\TransformationProcessor::$compiler = null
protected

The documentation for this class was generated from the following file: