PHP Class Scalr\Model\Collections\EntityIterator

This is the iterator of the AbstractEntity objects It is actually outer iterator for ADORecordSet_mysqli
Since: 5.4.0 (13.03.2014)
Author: Vitaliy Demidov ([email protected])
Inheritance: extends IteratorIterator, implements Countable
显示文件 Open project: scalr/scalr

Public Properties

Property Type Description
$totalNumber integer This property is set after use find() method

Public Methods

Method Description
__call ( string $name, array $args ) : ArrayCollection Implements some convenient magic methods
__construct ( string $entityClass, ADORecordSet_mysqli $recordSet ) Constructor
count ( )
current ( ) : AbstractEntity
getArrayCopy ( ) : array Creates a copy of the ArrayObject.
map ( callable $callback ) : array Implementation of array_map for EntityIterator Applies the callback to the elements of the Iterator

Method Details

__call() public method

Implements some convenient magic methods
public __call ( string $name, array $args ) : ArrayCollection
$name string The method name
$args array The arguments
return ArrayCollection

__construct() public method

Constructor
public __construct ( string $entityClass, ADORecordSet_mysqli $recordSet )
$entityClass string The name of the class of the Entity in the collection
$recordSet ADORecordSet_mysqli Result record set

count() public method

See also: Countable::count()
public count ( )

current() public method

See also: IteratorIterator::current()
public current ( ) : AbstractEntity
return Scalr\Model\AbstractEntity

getArrayCopy() public method

Creates a copy of the ArrayObject.
public getArrayCopy ( ) : array
return array Returns copy as an array

map() public method

Implementation of array_map for EntityIterator Applies the callback to the elements of the Iterator
public map ( callable $callback ) : array
$callback callable Callback function to run for each element in each array
return array An array containing all the elements after applying the callback function to each one

Property Details

$totalNumber public_oe property

This property is set after use find() method
public int $totalNumber
return integer