collection(iterable $items): Cake\Collection\Collection
Returns a new {@link \Cake\Collection\Collection} object wrapping the passed argument.
iterable
$items
The items from which the collection will be built.
Cake\Collection\Collection
Describes the methods a Collection should implement. A collection is an immutable list of elements exposing a number of traversing and extracting method for generating other collections.
A collection is an immutable list of elements with a handful of functions to iterate, group, transform and extract information from it.