foxworn3365 / listdictionaries
Use arrays and object in PHP as List<T> and Dictionary<T, T> in C#
dev-main
2024-01-15 15:14 UTC
Requires
- php: ^8.0
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-08-15 21:05:15 UTC
README
List<T> and Dictionary<T, T> in PHP
Install
You can install it on composer
composer require foxworn3365/listdictionaries
Examples
List
$list = PHPList::new("string|int", [ "hello", "goodbye", "your name is owo" ]); $list->where(fn($el) => strpos($el, "e"))->foreach(function ($el) { echo $el . PHP_EOL; });
Result:
hello
your name is owo