PHP Class Hal\Component\BusinessRule\Collection

For the full copyright and license information, please view the LICENSE file that was distributed with this source code.
Inheritance: implements IteratorAggregate, implements Countable
Mostra file Open project: Halleck45/DesignPatternDetector Class Usage Examples

Public Methods

Method Description
__construct ( array $datas ) Constructor
count ( ) : integer Get number of valid items
first ( ) : mixed
getIterator ( ) : ArrayIterator | Traversable Get datas (implementation of IteratorAggregate)
push ( $item ) Push item in the stack
where ( $clause ) Add a where clause ->where('x => x > 5')

Protected Methods

Method Description
applyFilter ( ) : void Filter datas

Method Details

__construct() public method

Constructor
public __construct ( array $datas )
$datas array

applyFilter() protected method

Filter datas
protected applyFilter ( ) : void
return void

count() public method

Get number of valid items
public count ( ) : integer
return integer

first() public method

public first ( ) : mixed
return mixed

getIterator() public method

Get datas (implementation of IteratorAggregate)

push() public method

Push item in the stack
public push ( $item )
$item

where() public method

Add a where clause ->where('x => x > 5')
public where ( $clause )
$clause