public function setParam($index, $value)
    {
        if (!isset($this->params[$index])) {
            throw new \InvalidArgumentException('Route parameter does not exist at specified index');
        }
        $this->params[$index] = $value;
    }
public function setParam($index, $value)
    {
        if (!isset($this->params[$index])) {
            throw new \InvalidArgumentException('Route parameter does not exist at specified index');
        }
        $this->params[$index] = $value;
    }
public function setParam ( $ index , $ value ) { if ( ! isset ( $ this -> params [ $ index ] ) ) { throw new \ InvalidArgumentException ( 'Route parameter does not exist at specified index' ) ; } $ this -> params [ $ index ] = $ value ; }
Set route parameter value
@param  string                    $index     Name of URL parameter
@param  mixed                     $value     The new parameter value
@return void
@throws \InvalidArgumentException            If route parameter does not exist at index
@api
Set route parameter value