src/Utilities/Helper.php
public static function replacePatternWithKeyword(array $subject, $keyword, $pattern = '$1')
    {
        $parameters = [];
        foreach ($subject as $param) {
            if (is_array($param)) {
                $parameters[] = self::replacePatternWithKeyword($param, $keyword, $pattern);
            } else {
                $parameters[] = str_replace($pattern, $keyword, $param);
            }
        }

        return $parameters;
    }
public static function replacePatternWithKeyword(array $subject, $keyword, $pattern = '$1')
    {
        $parameters = [];
        foreach ($subject as $param) {
            if (is_array($param)) {
                $parameters[] = self::replacePatternWithKeyword($param, $keyword, $pattern);
            } else {
                $parameters[] = str_replace($pattern, $keyword, $param);
            }
        }

        return $parameters;
    }
public static function replacePatternWithKeyword ( array $ subject , $ keyword , $ pattern = '$1' ) { $ parameters = [ ] ; foreach ( $ subject as $ param ) { if ( is_array ( $ param ) ) { $ parameters [ ] = self :: replacePatternWithKeyword ( $ param , $ keyword , $ pattern ) ; } else { $ parameters [ ] = str_replace ( $ pattern , $ keyword , $ param ) ; } } return $ parameters ; }
Replace all pattern occurrences with keyword.

@param array  $subject
@param string $keyword
@param string $pattern
@return array
Replace all pattern occurrences with keyword .