markwilson/array-key-filter

This package is abandoned and no longer maintained. No replacement package was suggested.

Array filtering by keys

0.1.1 2018-02-02 12:33 UTC

This package is not auto-updated.

Last update: 2021-01-23 09:21:43 UTC


README

Array filtering by key.

use MarkWilson\ArrayKeyFilter;
use MarkWilson\ArrayFiltering\ArrayFiltering;

$myArray = [ ... ];

$filter = new ArrayKeyFilter\KeyPatternFilter('/^prefix/');

$filtering = new ArrayFiltering($myArray);

$filteredArray = $filtering->filterBy($filter);