PHP Class neos\flow\aop\builder\ClassNameIndex

Datei anzeigen Open project: neos/flow-development-collection Class Usage Examples

Protected Properties

Property Type Description
$classNames array Indexed array by class name

Public Methods

Method Description
__construct ( array $classNames = [] ) Constructor. Note: If you pass a data array here, make sure to key sort it before!
applyIntersect ( ClassNameIndex $classNameIndex ) : void Sets this index to all class names which are present currently and contained in the given index
applyUnion ( ClassNameIndex $classNameIndex ) : void Sets this index to all class names which are either already present or are contained in the given index
count ( ) : integer
filterByPrefix ( string $prefixFilter ) : ClassNameIndex Returns a new index object which contains all class names of this index starting with the given prefix
getClassNames ( ) : array Returns the class names contained in this index
hasClassName ( string $className ) : boolean Checks, if a class name is contained in this index
intersect ( ClassNameIndex $classNameIndex ) : ClassNameIndex Returns a new index object with all class names contained in this and the given index
setClassNames ( array $classNames ) : void Set the data of this index to the given class names. Note: Make sure to sort the array before!
sort ( ) : array
union ( ClassNameIndex $classNameIndex ) : ClassNameIndex Returns a new index object containing all class names of this index and the given one

Method Details

__construct() public method

Constructor. Note: If you pass a data array here, make sure to key sort it before!
public __construct ( array $classNames = [] )
$classNames array Array with class names as keys

applyIntersect() public method

Sets this index to all class names which are present currently and contained in the given index
public applyIntersect ( ClassNameIndex $classNameIndex ) : void
$classNameIndex ClassNameIndex
return void

applyUnion() public method

Sets this index to all class names which are either already present or are contained in the given index
public applyUnion ( ClassNameIndex $classNameIndex ) : void
$classNameIndex ClassNameIndex
return void

count() public method

public count ( ) : integer
return integer The number of class names contained in this index

filterByPrefix() public method

Returns a new index object which contains all class names of this index starting with the given prefix
public filterByPrefix ( string $prefixFilter ) : ClassNameIndex
$prefixFilter string A prefix string to filter the class names of this index
return ClassNameIndex A new index object

getClassNames() public method

Returns the class names contained in this index
public getClassNames ( ) : array
return array An array of class names contained in this index

hasClassName() public method

Checks, if a class name is contained in this index
public hasClassName ( string $className ) : boolean
$className string The class name to check for
return boolean TRUE, if the given class name is contained in this index

intersect() public method

Returns a new index object with all class names contained in this and the given index
public intersect ( ClassNameIndex $classNameIndex ) : ClassNameIndex
$classNameIndex ClassNameIndex
return ClassNameIndex A new index object

setClassNames() public method

Set the data of this index to the given class names. Note: Make sure to sort the array before!
public setClassNames ( array $classNames ) : void
$classNames array
return void

sort() public method

public sort ( ) : array
return array An key sorted array with all class names of this index as keys

union() public method

Returns a new index object containing all class names of this index and the given one
public union ( ClassNameIndex $classNameIndex ) : ClassNameIndex
$classNameIndex ClassNameIndex
return ClassNameIndex A new index object

Property Details

$classNames protected_oe property

Indexed array by class name
protected array $classNames
return array