Rearchitected to use traits and interfaces
-
Tonnes of new methods and re-architected the package to rely on interfaces and traits.
-
Consumers of this package that want to make any of their application's classes (that already have a parent class) leverage the functionality in this package only need to implement and use either CollectionInterface and CollectionInterfaceImplementationTrait or StrictlyTypedCollectionInterface and StrictlyTypedCollectionInterfaceImplementationTrait
-
More unit tests and almost on par with Laravel's collections in terms of features
-
The randomItem(), randomItems(), randomKey() and randomKeys() methods use PHP 7's random_int() ( a cryptographically secure pseudo-random integers generator) for better randomness than php's array_rand() (which uses a pseudo random number generator that is not suitable for cryptographic purposes). paragonie/random_compat is used by this package to provide random_int() functionality for PHP 5.6 users of this package
-
Using sebastian/exporter for dumping variables when exceptions occur. This is because php's var_export() does not handle recursion in objects properly
-
Added ArraysCollection
-
Got rid of the BaseCollection class and now using CollectionInterfaceImplementationTrait instead
-
Got rid of the StrictlyTypedCollection class and now using StrictlyTypedCollectionInterfaceImplementationTrait instead
-
Renamed collection classes with singular prefixes to now use plural prefixes for consistency sake. E.g. IntCollection is now IntsCollection
-
Added powerful sorting methods
-
and tonnes of improvements