PHP Class Phulp\Collection

Inheritance: extends Doctrine\Common\Collections\ArrayCollection
Afficher le fichier Open project: reisraff/phulp Class Usage Examples

Protected Properties

Свойство Type Description
$type array Type of the elements.

Méthodes publiques

Méthode Description
__construct ( array $collection = [], $type = null ) Initializes a new Collection.
__toString ( ) : string Returns a string representation of this object.
add ( $value ) {@inheritDoc}
getType ( ) : string Returns which is the type of the elements.
set ( $key, $value ) {@inheritDoc}

Méthodes protégées

Méthode Description
checkType ( $item ) : boolean Checks the immutability of the elements type
getItemType ( mixed $item ) : string Returns which is the type of the item.

Method Details

__construct() public méthode

Initializes a new Collection.
public __construct ( array $collection = [], $type = null )
$collection array

__toString() public méthode

Returns a string representation of this object.
public __toString ( ) : string
Résultat string

add() public méthode

{@inheritDoc}
public add ( $value )

checkType() protected méthode

Checks the immutability of the elements type
protected checkType ( $item ) : boolean
Résultat boolean

getItemType() protected méthode

Returns which is the type of the item.
protected getItemType ( mixed $item ) : string
$item mixed
Résultat string

getType() public méthode

Returns which is the type of the elements.
public getType ( ) : string
Résultat string

set() public méthode

{@inheritDoc}
public set ( $key, $value )

Property Details

$type protected_oe property

Type of the elements.
protected array $type
Résultat array