Go\Proxy\ClassProxy::override PHP Method

override() public method

Override parent method with new body
public override ( string $methodName, string $body ) : static
$methodName string Method name to override
$body string New body for method
return static
    public function override($methodName, $body)
    {
        $this->methodsCode[$methodName] = $this->getOverriddenFunction($this->class->getMethod($methodName), $body);
        return $this;
    }