PHPackages                             alexeyshockov/colada - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. alexeyshockov/colada

AbandonedArchivedLibrary

alexeyshockov/colada
====================

Collections framework for PHP

v1.0.0(12y ago)312.8k61MITPHPPHP &gt;=5.3.2

Since May 15Pushed 6y ago5 watchersCompare

[ Source](https://github.com/alexeyshockov/colada)[ Packagist](https://packagist.org/packages/alexeyshockov/colada)[ Docs](http://github.com/alexeyshockov/colada)[ RSS](/packages/alexeyshockov-colada/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (11)Used By (1)

Colada
======

[](#colada)

[![Latest Stable Version](https://camo.githubusercontent.com/c8d801658e1a124e7c02412495d6908e9af74cc7b1cc851aa27df43f20f1f429/68747470733a2f2f706f7365722e707567782e6f72672f616c6578657973686f636b6f762f636f6c6164612f762f737461626c65)](https://packagist.org/packages/alexeyshockov/colada)[![Build Status](https://camo.githubusercontent.com/84b4ece02128346e28b566e1a9c2619796cfc60da5c26a998f3887c91b144736/68747470733a2f2f7472617669732d63692e6f72672f616c6578657973686f636b6f762f636f6c6164612e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/alexeyshockov/colada)[![Test Coverage](https://camo.githubusercontent.com/24b269e3fef82489aeaf5c95372cfb05152841962efe60ef2c46bc761cd0e991/68747470733a2f2f6170692e636f6465636c696d6174652e636f6d2f76312f6261646765732f39666164373061633262383265336135326335632f746573745f636f766572616765)](https://codeclimate.com/github/alexeyshockov/colada/test_coverage)

Goal
----

[](#goal)

*Convenient* and *safe* way to work with collections.

...And it's been (more or less) solved by some other libraries, like [nikic/iter](https://github.com/nikic/iter), [doctrine/collections](https://github.com/doctrine/collections) or even [php-ds/php-ds](https://github.com/php-ds/polyfill). That's why the current version of the library contains just a few helpers for that libraries, to conveniently integrate them together.

Installation
------------

[](#installation)

```
composer require alexeyshockov/colada:~3.0

```

Usage
-----

[](#usage)

The library's functions are split by namespaces, one namespace = specific function a dependency (in most cases).

### `\Colada\ds\{group_by}`

[](#coladadsgroup_by)

Helpers from this namespace require [php-ds/php-ds](https://github.com/php-ds/polyfill) to be available.

`group_by()` function prodices a two dimension array (`\ArrayObject` or `\Ds\Map`, depends on the group key type), from an iterable based on a group function.

```
TODO
```

### `\Colada\GuzzleHttp\{coroutine_invoke, coroutine, time_sleep}`

[](#coladaguzzlehttpcoroutine_invoke-coroutine-time_sleep)

### `\Colada\React\{coroutine_invoke, coroutine}`

[](#coladareactcoroutine_invoke-coroutine)

Helpers from this namespace require [guzzlehttp/promises](https://github.com/guzzle/promises) or [react/promise](https://github.com/reactphp/promise) to be available.

This is the same concept applied to two most popular libs with async capabilities. If you are familiar with async/await in C# or node.js or coroutines in Go, this should be simple. Take a look at the script, written in callback-style and in coroutine-style:

```
TODO
```

```
TODO
```

### `\Colada\iter\opt\{get, head, last, find_one}`

[](#coladaiteroptget-head-last-find_one)

Helpers from this namespace require [phpoption/phpoption](https://github.com/schmittjoh/php-option) to be available.

### `\Colada\iter\{to_kv_pairs, each_n_and_last, uasort, uksort}`

[](#coladaiterto_kv_pairs-each_n_and_last-uasort-uksort)

Simple helpers for general `iterable` types.

`uasort()` and `uksort()` are basically equivalents for the internal ones, but work for arbitrary `iterable` type.

Contributing
------------

[](#contributing)

### Running Tests

[](#running-tests)

To run all the tests, install the vendors (with Composer) and execute:

```
vendor/bin/phpunit --testdox

```

### Public API

[](#public-api)

All classes or functions that are intended to be used by a user should be marked with `@api` PHPDoc tag. Anything without this mark are internal and should not be used by the end user (no guarantees that the interface will stay the same between versions).

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 97.8% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~276 days

Recently: every ~48 days

Total

10

Last Release

2249d ago

Major Versions

1.x-dev → 2.x-dev2016-04-27

2.x-dev → v3.0.0-beta12019-03-20

PHP version history (3 changes)v1.0.0PHP &gt;=5.3.2

2.x-devPHP ~5.6 || ~7.0

v3.0.0-beta1PHP ~7.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/dbb1137342b76983ce06549ef8a9eb3332c3f35c30a45298c9070bc93b26db95?d=identicon)[alexeyshockov](/maintainers/alexeyshockov)

---

Top Contributors

[![alexeyshockov](https://avatars.githubusercontent.com/u/203120?v=4)](https://github.com/alexeyshockov "alexeyshockov (131 commits)")[![include-x](https://avatars.githubusercontent.com/u/1597916?v=4)](https://github.com/include-x "include-x (1 commits)")[![paulchubatyy](https://avatars.githubusercontent.com/u/98631?v=4)](https://github.com/paulchubatyy "paulchubatyy (1 commits)")[![pborreli](https://avatars.githubusercontent.com/u/77759?v=4)](https://github.com/pborreli "pborreli (1 commits)")

---

Tags

collections

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/alexeyshockov-colada/health.svg)

```
[![Health](https://phpackages.com/badges/alexeyshockov-colada/health.svg)](https://phpackages.com/packages/alexeyshockov-colada)
```

###  Alternatives

[doctrine/collections

PHP Doctrine Collections library that adds additional functionality on top of PHP arrays.

6.0k411.1M1.2k](/packages/doctrine-collections)[dusank/knapsack

Collection library for PHP

5351.0M25](/packages/dusank-knapsack)[cakephp/collection

Work easily with arrays and iterators by having a battery of utility traversal methods

899.9M10](/packages/cakephp-collection)[phootwork/collection

The phootwork library fills gaps in the php language and provides better solutions than the existing ones php offers.

3924.8M15](/packages/phootwork-collection)[qaribou/immutable.php

Immutable, highly-performant collections, well-suited for functional programming and memory-intensive applications.

344146.0k](/packages/qaribou-immutablephp)[ilya/belt

A handful of tools for PHP developers.

71020.8k1](/packages/ilya-belt)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
