Parse param and replace {{.*}} by its Fixtures::get() value if exists

@param string $param

@return \mixed|null Returns parameter's value if exists, else parameter's name
355048
final protected function getValueFromParam(string $param)
  {
    if (preg_match(self::$regEx['match'], $param)) {
      $arg = preg_filter(self::$regEx['filter'], '', $param);
      if (preg_match(self::$regEx['config'], $arg)) {
        return $this->getValueFromConfig($arg);
      } elseif (preg_match(self::$regEx['array'], $arg)) {
        return $this->getValueFromArray($arg);
      } else {
        return Fixtures::get($arg);
      }
    } else {
      return $param;
    }
  }
617033
public function get($parameter=null) {

        if ( is_null($parameter) ) return $this->parameters;

        return array_key_exists($parameter, $this->parameters) ?
            $this->parameters[$parameter] : null;

        // substitution by backreference is cool but hard compute for a large set of values :(
        //
        // if ( is_scalar($value) && preg_match_all('/%(.+?)%/', $value, $matches, PREG_SET_ORDER) ) {
        //
        //     $substitutions = array();
        //
        //     foreach ( $matches as $match ) {
        //
        //         $backreference = $match[1];
        //
        //         if ( $backreference != $property && !isset($substitutions['/%'.$backreference.'%/']) ) {
        //
        //             $substitutions['/%'.$backreference.'%/'] = $this->get($backreference);
        //
        //         }
        //
        //     }
        //
        //     $value = preg_replace(array_keys($substitutions), array_values($substitutions), $value);
        //
        // }

    }
892131
public function get($param)
    {
        if (isset($this->{$param})) {
            return $this->{$param};
        }

        throw new Exception(sprintf('Filter variable "%s" not found.', $param));
    }
734978
function (param) {
        _.assign(this, /** @lends QueryParam.prototype */ _.isString(param) ? QueryParam.parseSingle(param) : {
            key: _.get(param, 'key'), // we do not replace falsey with blank string since null has a meaning
            value: _.get(param, 'value')
        });
        _.has(param, 'system') && (this.system = param.system);
    }
568614
public function getRequest($param, $method = null)
    {
        if ($method === null) {
            $method = $this->_sendMethod;
        }

        $method = Str::lowerCase($method);
        // get root request as array or string
        switch ($method) {
            case 'get':
                $request = App::$Request->query->get($this->getFormName(), null);
                break;
            case 'post':
                $request = App::$Request->request->get($this->getFormName(), null);
                break;
            case 'file':
                $request = App::$Request->files->get($this->getFormName(), null);
                break;
            default:
                $request = App::$Request->get($this->getFormName(), null);
                break;
        }

        $response = null;
        // param is a dot-separated array type
        if (Str::contains('.', $param)) {
            $response = $request;
            foreach (explode('.', $param) as $path) {
                if ($response !== null && !array_key_exists($path, $response)) {
                    return null;
                }
                // find deep array nesting offset
                $response = $response[$path];
            }
        } else {
            $response = $request[$param];
        }

        return $response;
    }
1193909
public static function getDefaultValue($param = null)
    {
        $result = null;

        if (empty($param)) {
            return static::$defaults;
        }

        if (isset(static::$defaults[$param])) {
            $result = static::$defaults[$param];
        }

        return $result;
    }
1372174
final protected function getValueFromArray(string $param)
  {
    $value = null;

    preg_match_all(self::$regEx['array'], $param, $args);
    $array = Fixtures::get($args['var'][0]);
    if (array_key_exists($args['key'][0], $array)) {
        $value = $array[$args['key'][0]];
    }
    return $value;
  }
195616
protected static function compilePaging($param)
    {
        $parameters = self::parseParameters($param);
        $result = '';
        if (!empty($parameters['template']))
            $result .= "\$this->pagination->setTemplate(\$this->render('{$parameters['template']}'));\n?>";
        $link = 'null';
        if (!empty($parameters['link'])) {
            if ('$' != $parameters['link']{0})
                $parameters['link'] = '\'' . $parameters['link'] . '\'';
            $link = $parameters['link'];
        }
        $page = !empty($parameters['page']) ? $parameters['page'] : 'null';
        $total = !empty($parameters['total']) ? $parameters['total'] : 'null';
        $size = !empty($parameters['size']) ? $parameters['size'] : 'null';
        $result .= "<?php echo \$this->pagination->render({$link}, {$page}, {$total}, {$size});\n?>";

        return $result;
    }
572891
public function getResponseParam($param) {
    if (isset($this->notifyParams[$param])) {
      return $this->notifyParams[$param];
    }
    return NULL;
  }
339304
public function getParameterDescription(ReflectionParameter $param): ?string
    {
        $name = preg_quote($param->getName());

        if (preg_match('~@param\h+\H+\h+\$' . $name . '\h+(.*)~', $this->comment, $m)) {
            return ucfirst(trim($m[1]));
        }

        return null;
    }
280695
protected function getParam($param)
    {
        $params = $this->getParams();
        if (! isset($params[$param])) {
            return false;
        }
        return $params[$param];
    }
337309
public function getParam($param = null)
    {
        if (null === $param) {
            return $this->_params;
        }

        return isset($this->_params[$param]) ? $this->_params[$param] : null;
    }
697894
public function route( $param = null ) {
		$route = call_user_func( $this->get_route_resolver() );

		if ( is_null( $route ) || is_null( $param ) ) {
			return $route;
		}

		return array_key_exists( $param, $route[2] ) ? $route[2][ $param ] : null;
	}
1252935
private function parseParameter(string $key, string $value, &$params): string
    {
        if (isset($params[$key])) {
            $par = $params[$key];
            unset($params[$key]);

            $value = $value ? $value . '_' . $par : $par;
        }

        return static::makeParam($key, $value);
    }
1275882
public function getParam($param = null)
    {
        if (null === $param) {
            return $this->params;
        }

        return isset($this->params[$param]) ? $this->params[$param] : null;
    }
359539
protected function getParamDefaultLocal($param)
    {
        $param = $this->getParameter($param);
        if (!is_null($param))
            return $param;

        return $this->getLocal($param);
    }
1019462
protected final function getArg(ReflectionParameter $param, CacheInterface $cache = null)
   {
       $match = [];
       $delimiter = "@param";
       $type = "string|int|bool|float|array|callable";
       preg_match(
           '/^.+' . $delimiter . '\s+(?!' . $type
         . ')([A-Za-z0-9\\\]{1,})\s+\$'
         . $param->name . '/m',
           $param->getDeclaringFunction()->getDocComment(),
           $match);
       if (array_key_exists(1, $match)) {
           return $this->resolve($match[1], $cache);
       }
   }