PHP Interface Pinq\ICollection

Author: Elliot Levin ([email protected])
Inheritance: extends pinq\ITraversable
ファイルを表示 Open project: timetoogo/pinq Interface Usage Examples

Public Methods

Method Description
addRange ( array | Traversable $values ) : void Adds a range of values to the collection.
append ( $values ) : pinq\ICollection {@inheritDoc}
apply ( callable $function ) : void Walks the elements with the supplied function.
clear ( ) : void Removes all the values.
difference ( $values ) : pinq\ICollection {@inheritDoc}
except ( $values ) : pinq\ICollection {@inheritDoc}
getSource ( ) : pinq\ICollection {@inheritDoc}
groupBy ( callable $function ) : pinq\ICollection {@inheritDoc}
groupJoin ( $values ) : Pinq\Interfaces\IJoiningOnCollection {@inheritDoc}
indexBy ( callable $function ) : pinq\ICollection {@inheritDoc}
intersect ( $values ) : pinq\ICollection {@inheritDoc}
join ( $values ) : Pinq\Interfaces\IJoiningOnCollection {@inheritDoc}
keys ( ) : pinq\ICollection {@inheritDoc}
orderBy ( callable $function, $direction ) : Pinq\Interfaces\IOrderedCollection {@inheritDoc}
orderByAscending ( callable $function ) : Pinq\Interfaces\IOrderedCollection {@inheritDoc}
orderByDescending ( callable $function ) : Pinq\Interfaces\IOrderedCollection {@inheritDoc}
reindex ( ) : pinq\ICollection {@inheritDoc}
remove ( mixed $value ) : void Removes all occurrences of the supplied value from the collection.
removeRange ( array | Traversable $values ) : void Removes all occurrences of the supplied values from the collection.
removeWhere ( callable $predicate ) : void Removes all the values matched by the predicate.
select ( callable $function ) : pinq\ICollection {@inheritDoc}
selectMany ( callable $function ) : pinq\ICollection {@inheritDoc}
skip ( $amount ) : pinq\ICollection {@inheritDoc}
slice ( $start, $amount ) : pinq\ICollection {@inheritDoc}
take ( $amount ) : pinq\ICollection {@inheritDoc}
union ( $values ) : pinq\ICollection {@inheritDoc}
unique ( ) : pinq\ICollection {@inheritDoc}
where ( callable $predicate ) : pinq\ICollection {@inheritDoc}
whereIn ( $values ) : pinq\ICollection {@inheritDoc}

Method Details

addRange() public method

The collection will be reindexed.
public addRange ( array | Traversable $values ) : void
$values array | Traversable The values to add
return void

append() public method

{@inheritDoc}
public append ( $values ) : pinq\ICollection
return pinq\ICollection

apply() public method

Walks the elements with the supplied function.
public apply ( callable $function ) : void
$function callable
return void

clear() public method

Removes all the values.
public clear ( ) : void
return void

difference() public method

{@inheritDoc}
public difference ( $values ) : pinq\ICollection
return pinq\ICollection

except() public method

{@inheritDoc}
public except ( $values ) : pinq\ICollection
return pinq\ICollection

getSource() public method

{@inheritDoc}
public getSource ( ) : pinq\ICollection
return pinq\ICollection

groupBy() public method

{@inheritDoc}
public groupBy ( callable $function ) : pinq\ICollection
$function callable
return pinq\ICollection

groupJoin() public method

{@inheritDoc}
public groupJoin ( $values ) : Pinq\Interfaces\IJoiningOnCollection
return Pinq\Interfaces\IJoiningOnCollection

indexBy() public method

{@inheritDoc}
public indexBy ( callable $function ) : pinq\ICollection
$function callable
return pinq\ICollection

intersect() public method

{@inheritDoc}
public intersect ( $values ) : pinq\ICollection
return pinq\ICollection

join() public method

{@inheritDoc}
public join ( $values ) : Pinq\Interfaces\IJoiningOnCollection
return Pinq\Interfaces\IJoiningOnCollection

keys() public method

{@inheritDoc}
public keys ( ) : pinq\ICollection
return pinq\ICollection

orderBy() public method

{@inheritDoc}
public orderBy ( callable $function, $direction ) : Pinq\Interfaces\IOrderedCollection
$function callable
return Pinq\Interfaces\IOrderedCollection

orderByAscending() public method

{@inheritDoc}
public orderByAscending ( callable $function ) : Pinq\Interfaces\IOrderedCollection
$function callable
return Pinq\Interfaces\IOrderedCollection

orderByDescending() public method

{@inheritDoc}
public orderByDescending ( callable $function ) : Pinq\Interfaces\IOrderedCollection
$function callable
return Pinq\Interfaces\IOrderedCollection

reindex() public method

{@inheritDoc}
public reindex ( ) : pinq\ICollection
return pinq\ICollection

remove() public method

Removes all occurrences of the supplied value from the collection.
public remove ( mixed $value ) : void
$value mixed The value to remove
return void

removeRange() public method

Removes all occurrences of the supplied values from the collection.
public removeRange ( array | Traversable $values ) : void
$values array | Traversable The values to remove
return void

removeWhere() public method

Removes all the values matched by the predicate.
public removeWhere ( callable $predicate ) : void
$predicate callable
return void

select() public method

{@inheritDoc}
public select ( callable $function ) : pinq\ICollection
$function callable
return pinq\ICollection

selectMany() public method

{@inheritDoc}
public selectMany ( callable $function ) : pinq\ICollection
$function callable
return pinq\ICollection

skip() public method

{@inheritDoc}
public skip ( $amount ) : pinq\ICollection
return pinq\ICollection

slice() public method

{@inheritDoc}
public slice ( $start, $amount ) : pinq\ICollection
return pinq\ICollection

take() public method

{@inheritDoc}
public take ( $amount ) : pinq\ICollection
return pinq\ICollection

union() public method

{@inheritDoc}
public union ( $values ) : pinq\ICollection
return pinq\ICollection

unique() public method

{@inheritDoc}
public unique ( ) : pinq\ICollection
return pinq\ICollection

where() public method

{@inheritDoc}
public where ( callable $predicate ) : pinq\ICollection
$predicate callable
return pinq\ICollection

whereIn() public method

{@inheritDoc}
public whereIn ( $values ) : pinq\ICollection
return pinq\ICollection