public static function findOne($pattern, $entries)
    {
        $found = [];

        foreach ($entries as $entry)
        {
            if (static::match($pattern, $entry))
            {
                $found[] = $entry;
            }
        }

        return $found;
    }
public static function findOne($pattern, $entries)
    {
        $found = [];

        foreach ($entries as $entry)
        {
            if (static::match($pattern, $entry))
            {
                $found[] = $entry;
            }
        }

        return $found;
    }
public static function findOne ( $ pattern , $ entries ) { $ found = [ ] ; foreach ( $ entries as $ entry ) { if ( static :: match ( $ pattern , $ entry ) ) { $ found [ ] = $ entry ; } } return $ found ; }
Filter and return entries that match specified pattern.

@param string $pattern
@param string[] $entries
@return string[]
Filter and return entries that match specified pattern .