PHP Classes

Collections PHP Library: Manipulate collections of values

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 69%Total: 439 All time: 6,263 This week: 455Up
Version License PHP version Categories
collections-php 1.0MIT/X Consortium ...5.4.0PHP 5, Libraries, Data types, Design ...
Description 

Author

This package can be used to manipulate collections of values.

It provides several classes that implement different types of operations to build and access values of items organized as collections.

The package has classes to organize collections as dictionaries that associate names to values, lists of enumerated values, queues, stacks, etc..

These classes implement operations with the collection items like adding, removing, searching, sorting, etc..

Picture of Italo Lelis de Vietro
  Performance   Level  
Name: Italo Lelis de Vietro <contact>
Classes: 7 packages by
Country: Brazil Brazil
Age: 33
All time rank: 75454 in Brazil Brazil
Week rank: 215 Up19 in Brazil Brazil Up

Details

# Collections [![Build Status](https://travis-ci.org/italolelis/collections.svg?style=flat-square)](https://travis-ci.org/italolelis/collections) [![Scrutinizer Code Quality](http://img.shields.io/scrutinizer/g/italolelis/collections.svg?style=flat-square)](https://scrutinizer-ci.com/g/italolelis/collections/) [![Code Coverage](http://img.shields.io/scrutinizer/coverage/g/italolelis/collections.svg?style=flat-square)](https://scrutinizer-ci.com/g/italolelis/collections/) [![Latest Stable Version](http://img.shields.io/packagist/v/easyframework/collections.svg?style=flat-square)](https://packagist.org/packages/easyframework/collections) [![Downloads](https://img.shields.io/packagist/dt/easyframework/collections.svg?style=flat-square)](https://packagist.org/packages/easyframework/collections) [![SensioLabsInsight](https://insight.sensiolabs.com/projects/1f67b9bd-f120-43d5-9f02-f73aa6132d86/small.png)](https://insight.sensiolabs.com/projects/1f67b9bd-f120-43d5-9f02-f73aa6132d86) Collections Abstraction library for PHP The Collection library is one of the most useful things that many modern languages has, but for some reason PHP doesn't has a built in collection layer. For that reason we created Collections, an incredible library that gathers the best of .NET's and Java's collections patterns and unify it with PHP array power. Take a look and see what we're talking about!! ## Install ``` json { "require": { "easyframework/collections": "~4.0" } } ``` ## Usage ### The Collection Class The Collection represents the List in .NET language or simply non-associative arrays in php: ```php $collection = new Collections\ArrayList(); $collection->add('John'); $collection->add('Maria'); $collection->add('Anderson'); $collection->each(function($item){ echo $item; }); ``` ## Contributing Please see [CONTRIBUTING](https://github.com/LellysInformatica/collections/blob/master/CONTRIBUTING.md) for details. ## Credits - [italolelis](https://github.com/italolelis) - [philipe](https://github.com/philipe) - [AyrtonRicardo](https://github.com/AyrtonRicardo) - [All Contributors](https://github.com/LellysInformatica/collections/contributors) ## License The MIT License (MIT). Please see [License File](https://github.com/LellysInformatica/collections/blob/master/LICENSE) for more information. ### Documentation More information can be found in the online documentation at http://collections.readthedocs.org/.

  Files folder image Files (121)  
File Role Description
Files folder imageComparer (2 files)
Files folder imagedocs (7 files, 1 directory)
Files folder imageExpr (6 files)
Files folder imageGeneric (1 file)
Files folder imagesrc (25 files, 4 directories)
Files folder imagetests (9 files)
Accessible without login Plain text file .scrutinizer.yml Data Auxiliary data
Accessible without login Plain text file .travis.yml Data Auxiliary data
Accessible without login Plain text file CHANGELOG.md Data Auxiliary data
Plain text file Collection.php Class Class source
Plain text file CollectionBase.php Class Class source
Plain text file CollectionInterface.php Class Class source
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file composer.lock Data Auxiliary data
Accessible without login Plain text file CONTRIBUTING.md Data Auxiliary data
Plain text file Criteria.php Class Class source
Plain text file Dictionary.php Class Class source
Plain text file DictionaryInterface.php Class Class source
Plain text file Enumerable.php Class Class source
Plain text file EnumerableInterface.php Class Class source
Plain text file ExpressionBuilder.php Class Class source
Accessible without login Plain text file LICENSE Data Auxiliary data
Plain text file ListInterface.php Class Class source
Accessible without login Plain text file phpci.yml Data Auxiliary data
Accessible without login Plain text file phpunit.xml.dist Data Auxiliary data
Plain text file Queue.php Class Class source
Accessible without login Plain text file README.md Data Auxiliary data
Plain text file SelectableInterface.php Class Class source
Plain text file Stack.php Class Class source

  Files folder image Files (121)  /  Comparer  
File Role Description
  Plain text file NumericKeyComparer.php Class Class source
  Plain text file StringComparer.php Class Class source

  Files folder image Files (121)  /  docs  
File Role Description
Files folder image_templates (1 file)
  Accessible without login Plain text file conf.py Data Auxiliary data
  Accessible without login Plain text file index.rst Data Auxiliary data
  Accessible without login Plain text file Makefile Data Auxiliary data
  Accessible without login Plain text file overview.rst Data Auxiliary data
  Accessible without login Plain text file quickstart.rst Data Auxiliary data
  Accessible without login Plain text file reactive-extension.rst Data Auxiliary data
  Accessible without login Plain text file requirements.txt Doc. Documentation

  Files folder image Files (121)  /  docs  /  _templates  
File Role Description
  Accessible without login HTML file nav_links.html Doc. Documentation

  Files folder image Files (121)  /  Expr  
File Role Description
  Plain text file ClosureExpressionVisitor.php Class Class source
  Plain text file Comparison.php Class Class source
  Plain text file CompositeExpression.php Class Class source
  Plain text file Expression.php Class Class source
  Plain text file ExpressionVisitor.php Class Class source
  Plain text file Value.php Class Class source

  Files folder image Files (121)  /  Generic  
File Role Description
  Plain text file ComparerInterface.php Class Class source

  Files folder image Files (121)  /  src  
File Role Description
Files folder imageComparer (2 files)
Files folder imageException (10 files)
Files folder imageGeneric (1 file)
Files folder imageIterator (34 files)
  Plain text file AbstractCollection.php Class Class source
  Plain text file AbstractCollectionArray.php Class Class source
  Plain text file ArrayList.php Class Class source
  Plain text file AvlTree.php Class Class source
  Plain text file BinarySearchTreeInterface.php Class Class source
  Plain text file BinaryTree.php Class Class source
  Plain text file CollectionConvertableInterface.php Class Class source
  Plain text file CollectionInterface.php Class Class source
  Plain text file ConstIndexAccessInterface.php Class Class source
  Plain text file Dictionary.php Class Class source
  Plain text file ExtractTrait.php Class Class source
  Plain text file GuardTrait.php Class Class source
  Plain text file IndexAccessInterface.php Class Class source
  Plain text file LinkedQueue.php Class Class source
  Plain text file LinkedStack.php Class Class source
  Plain text file MapConvertableInterface.php Class Class source
  Plain text file MapInterface.php Class Class source
  Plain text file Pair.php Class Class source
  Plain text file Queue.php Class Class source
  Plain text file QueueInterface.php Class Class source
  Plain text file SortTrait.php Class Class source
  Plain text file Stack.php Class Class source
  Plain text file StackInterface.php Class Class source
  Plain text file VectorConvertableInterface.php Class Class source
  Plain text file VectorInterface.php Class Class source

  Files folder image Files (121)  /  src  /  Comparer  
File Role Description
  Plain text file NumericKeyComparer.php Class Class source
  Plain text file StringComparer.php Class Class source

  Files folder image Files (121)  /  src  /  Exception  
File Role Description
  Plain text file DomainException.php Class Class source
  Plain text file EmptyException.php Class Class source
  Plain text file Exception.php Class Class source
  Plain text file FullException.php Class Class source
  Plain text file FunctionException.php Class Class source
  Plain text file IndexException.php Class Class source
  Plain text file KeyException.php Class Class source
  Plain text file LookupException.php Class Class source
  Plain text file StateException.php Class Class source
  Plain text file TypeException.php Class Class source

  Files folder image Files (121)  /  src  /  Generic  
File Role Description
  Plain text file ComparerInterface.php Class Class source

  Files folder image Files (121)  /  src  /  Iterator  
File Role Description
  Plain text file ArrayIterator.php Class Class source
  Plain text file BinaryTreeIteratorInterface.php Class Class source
  Plain text file CountableIteratorInterface.php Class Class source
  Plain text file CountableSeekableIteratorInterface.php Class Class source
  Plain text file ExtractIterator.php Class Class source
  Plain text file FilteringIterator.php Class Class source
  Plain text file HashMapIterator.php Class Class source
  Plain text file HashSetIterator.php Class Class source
  Plain text file InOrderIterator.php Class Class source
  Plain text file InsertInterator.php Class Class source
  Plain text file IteratorCollectionAdapter.php Class Class source
  Plain text file IteratorCollectionTrait.php Class Class source
  Plain text file KeyIterator.php Class Class source
  Plain text file LevelOrderIterator.php Class Class source
  Plain text file LimitingIterator.php Class Class source
  Plain text file LinkedQueueIterator.php Class Class source
  Plain text file LinkedStackIterator.php Class Class source
  Plain text file MapIteratorInterface.php Class Class source
  Plain text file MappingIterator.php Class Class source
  Plain text file NoChildrenIterator.php Class Class source
  Plain text file PostOrderIterator.php Class Class source
  Plain text file PreOrderIterator.php Class Class source
  Plain text file QueueIteratorInterface.php Class Class source
  Plain text file ReplaceIterator.php Class Class source
  Plain text file SeekableIteratorInterface.php Class Class source
  Plain text file SetIteratorInterface.php Class Class source
  Plain text file SkippingIterator.php Class Class source
  Plain text file SlicingIterator.php Class Class source
  Plain text file SortedMapIterator.php Class Class source
  Plain text file SortedSetIterator.php Class Class source
  Plain text file StackIteratorInterface.php Class Class source
  Plain text file UnfoldIterator.php Class Class source
  Plain text file ValueIterator.php Class Class source
  Plain text file VectorIterator.php Class Class source

  Files folder image Files (121)  /  tests  
File Role Description
  Accessible without login Plain text file ArrayListTest.php Test Unit test script
  Accessible without login Plain text file bootstrap.php Test Unit test script
  Accessible without login Plain text file CollectionsTestCase.php Test Unit test script
  Accessible without login Plain text file DictionaryTest.php Test Unit test script
  Accessible without login Plain text file LinkedQueueTest.php Test Unit test script
  Accessible without login Plain text file LinkedStackTest.php Test Unit test script
  Accessible without login Plain text file QueueTest.php Test Unit test script
  Accessible without login Plain text file RxTest.php Test Unit test script
  Accessible without login Plain text file StackTest.php Test Unit test script

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
Downloadcollections-php-2015-03-29.zip 86KB
Downloadcollections-php-2015-03-29.tar.gz
Install with ComposerInstall with Composer
Needed packages  
Class DownloadWhy it is needed Dependency
Generics PHP Download .zip .tar.gz The generics interfaces are needed to all classes work correctly Required
 Version Control Unique User Downloads Download Rankings  
 81%
Total:439
This week:0
All time:6,263
This week:455Up
User Ratings User Comments (1)
 All time
Utility:90%StarStarStarStarStar
Consistency:90%StarStarStarStarStar
Documentation:81%StarStarStarStarStar
Examples:-
Tests:75%StarStarStarStar
Videos:-
Overall:69%StarStarStarStar
Rank:318