src/Proxy/ProxyTrait.php
private function pushCallerStatedClassName(StateInterface $state): ProxyInterface
    {
        $stateClass = \get_class($state);

        if (!isset($this->classesByStates[$stateClass])) {
            throw new \RuntimeException("Error, no original class name defined for $stateClass");
        }

        $this->callerStatedClassesStack->push($this->classesByStates[$stateClass]);

        return $this;
    }
private function pushCallerStatedClassName(StateInterface $state): ProxyInterface
    {
        $stateClass = \get_class($state);

        if (!isset($this->classesByStates[$stateClass])) {
            throw new \RuntimeException("Error, no original class name defined for $stateClass");
        }

        $this->callerStatedClassesStack->push($this->classesByStates[$stateClass]);

        return $this;
    }
private function pushCallerStatedClassName ( StateInterface $ state ) : ProxyInterface { $ stateClass = \ get_class ( $ state ) ; if ( ! isset ( $ this -> classesByStates [ $ stateClass ] ) ) { throw new \ RuntimeException ( "Error, no original class name defined for $stateClass" ) ; } $ this -> callerStatedClassesStack -> push ( $ this -> classesByStates [ $ stateClass ] ) ; return $ this ; }
To push in the caller stated classes name stack
the class of the current object.

@param StateInterface $state

@return ProxyInterface
To push in the caller stated classes name stack the class of the current object .