src/Decorator.php
public function setDecoratedObject($decorated)
    {
        if (!is_object($decorated)) {
            throw new \InvalidArgumentException(
                sprintf(
                    'Expected an object but got an argument of type "%s" instead.',
                    gettype($decorated)
                )
            );
        }

        $this->decoratedObject = $decorated;
    }
public function setDecoratedObject($decorated)
    {
        if (!is_object($decorated)) {
            throw new \InvalidArgumentException(
                sprintf(
                    'Expected an object but got an argument of type "%s" instead.',
                    gettype($decorated)
                )
            );
        }

        $this->decoratedObject = $decorated;
    }
public function setDecoratedObject ( $ decorated ) { if ( ! is_object ( $ decorated ) ) { throw new \ InvalidArgumentException ( sprintf ( 'Expected an object but got an argument of type "%s" instead.' , gettype ( $ decorated ) ) ) ; } $ this -> decoratedObject = $ decorated ; }
Sets the decorated object.

@param object $decorated
Sets the decorated object .