public function to($impl): self
    {
        if (!is_string($impl) && !($impl instanceof \ReflectionClass)) {
            throw new \InvalidArgumentException(
                    '$impl must be a string or an instance of \ReflectionClass'
            );
        }

        $this->impl = $impl;
        return $this;
    }
public function to($impl): self
    {
        if (!is_string($impl) && !($impl instanceof \ReflectionClass)) {
            throw new \InvalidArgumentException(
                    '$impl must be a string or an instance of \ReflectionClass'
            );
        }

        $this->impl = $impl;
        return $this;
    }
public function to ( $ impl ) : self { if ( ! is_string ( $ impl ) && ! ( $ impl instanceof \ ReflectionClass ) ) { throw new \ InvalidArgumentException ( '$impl must be a string or an instance of \ReflectionClass' ) ; } $ this -> impl = $ impl ; return $ this ; }
set the concrete implementation

@api
@param   \ReflectionClass|string  $impl
@return  \stubbles\ioc\binding\ClassBinding
@throws  \InvalidArgumentException
set the concrete implementation