Pinq\Expressions\ParameterExpression::update PHP Method

update() public method

public update ( string $name, string | null $typeHint, Expression $defaultValue = null, boolean $isPassedByReference, boolean $isVariadic ) : self
$name string
$typeHint string | null
$defaultValue Expression
$isPassedByReference boolean
$isVariadic boolean
return self
    public function update($name, $typeHint, Expression $defaultValue = null, $isPassedByReference, $isVariadic)
    {
        if ($this->name === $name && $this->typeHint === $typeHint && $this->defaultValue === $defaultValue && $this->isPassedByReference === $isPassedByReference && $this->isVariadic === $isVariadic) {
            return $this;
        }
        return new self($name, $typeHint, $defaultValue, $isPassedByReference, $isVariadic);
    }