{"id":21882693,"url":"https://github.com/jjgrainger/collection","last_synced_at":"2025-07-10T09:38:18.189Z","repository":{"id":56999551,"uuid":"77850769","full_name":"jjgrainger/Collection","owner":"jjgrainger","description":"A PHP Collection class for working with arrays","archived":false,"fork":false,"pushed_at":"2020-04-07T15:51:33.000Z","size":21,"stargazers_count":12,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-16T17:45:04.297Z","etag":null,"topics":["collection","php"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jjgrainger.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-01-02T17:39:14.000Z","updated_at":"2023-07-29T02:47:26.000Z","dependencies_parsed_at":"2022-08-21T13:20:46.221Z","dependency_job_id":null,"html_url":"https://github.com/jjgrainger/Collection","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/jjgrainger/Collection","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjgrainger%2FCollection","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjgrainger%2FCollection/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjgrainger%2FCollection/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjgrainger%2FCollection/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jjgrainger","download_url":"https://codeload.github.com/jjgrainger/Collection/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjgrainger%2FCollection/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264559671,"owners_count":23628040,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["collection","php"],"created_at":"2024-11-28T09:34:27.524Z","updated_at":"2025-07-10T09:38:18.172Z","avatar_url":"https://github.com/jjgrainger.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Collection v1.1\n\n\u003e A collection class for working with arrays\n\n[![Build Status](https://travis-ci.org/jjgrainger/Collection.svg?branch=master)](https://travis-ci.org/jjgrainger/Collection) [![Total Downloads](https://poser.pugx.org/jjgrainger/collection/downloads)](https://packagist.org/packages/jjgrainger/collection) [![Latest Stable Version](https://poser.pugx.org/jjgrainger/collection/v/stable)](https://packagist.org/packages/jjgrainger/collection) [![License](https://poser.pugx.org/jjgrainger/collection/license)](https://packagist.org/packages/jjgrainger/collection)\n\n## Principles\n\n* Immutable - Most methods return a new collection, leaving the previous untouched\n* Chainable - Methods can be chained to create fluent mapping and reduce original collection\n\n## Requirements\n\n* PHP \u003e=7.2\n* [Composer](https://getcomposer.org/)\n\n## Installation\n\n```\n$ composer require jjgrainger/collection\n```\n\n## Usage\n\n```php\n$collection = new Collection([1, 2, 3]);\n\n$total = $collection-\u003esum(); // 6\n```\n\n## Notes\n\n* This project was created to learn unit testing, not intended for production use.\n* Inspired by [Laravel Collections](https://laravel.com/docs/5.8/collections)\n* Licensed under the [MIT License](https://github.com/jjgrainger/wp-posttypes/blob/master/LICENSE)\n* Maintained under the [Semantic Versioning Guide](https://semver.org)\n\n## Author\n\n**Joe Grainger**\n\n* [https://jjgrainger.co.uk](https://jjgrainger.co.uk)\n* [https://twitter.com/jjgrainger](https://twitter.com/jjgrainger)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjgrainger%2Fcollection","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjjgrainger%2Fcollection","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjgrainger%2Fcollection/lists"}