src/Collection/ParameterCollection.php
public function has(string $name): bool
    {
        $parts = explode('[', $name);
        $lastKey = trim(array_pop($parts), ']');
        $current = &$this->parameters;
        foreach ($parts as $part) {
            $target = trim($part, ']');
            if (!is_array($current) || !array_key_exists($target, $current)) {
                return false;
            }

            $current = &$current[$target];
        }

        if (!array_key_exists($lastKey, $current)) {
            return false;
        }

        return true;
    }
public function has(string $name): bool
    {
        $parts = explode('[', $name);
        $lastKey = trim(array_pop($parts), ']');
        $current = &$this->parameters;
        foreach ($parts as $part) {
            $target = trim($part, ']');
            if (!is_array($current) || !array_key_exists($target, $current)) {
                return false;
            }

            $current = &$current[$target];
        }

        if (!array_key_exists($lastKey, $current)) {
            return false;
        }

        return true;
    }
public function has ( string $ name ) : bool { $ parts = explode ( '[' , $ name ) ; $ lastKey = trim ( array_pop ( $ parts ) , ']' ) ; $ current = & $ this -> parameters ; foreach ( $ parts as $ part ) { $ target = trim ( $ part , ']' ) ; if ( ! is_array ( $ current ) || ! array_key_exists ( $ target , $ current ) ) { return false ; } $ current = & $ current [ $ target ] ; } if ( ! array_key_exists ( $ lastKey , $ current ) ) { return false ; } return true ; }
Checks if a parameter exists.

@param string $name name of the parameter

@return bool
Checks if a parameter exists .