src/Mutator/Mutator.php
protected function getInstanceMethod(ReflectionClass $class, ReflectionMethod $method)
    {
        if (!$method->isPublic()) {
            throw new InvalidCallableException("Instance method [{$class}@{$method->getName()}] is not public.");
        }

        if (!$this->canInstantiate($class)) {
            throw new InvalidCallableException("Can't instantiate class [{$class->getName()}].");
        }

        return [$class->newInstance(), $method->getName()];
    }
protected function getInstanceMethod(ReflectionClass $class, ReflectionMethod $method)
    {
        if (!$method->isPublic()) {
            throw new InvalidCallableException("Instance method [{$class}@{$method->getName()}] is not public.");
        }

        if (!$this->canInstantiate($class)) {
            throw new InvalidCallableException("Can't instantiate class [{$class->getName()}].");
        }

        return [$class->newInstance(), $method->getName()];
    }
protected function getInstanceMethod ( ReflectionClass $ class , ReflectionMethod $ method ) { if ( ! $ method -> isPublic ( ) ) { throw new InvalidCallableException ( "Instance method [{$class}@{$method->getName()}] is not public." ) ; } if ( ! $ this -> canInstantiate ( $ class ) ) { throw new InvalidCallableException ( "Can't instantiate class [{$class->getName()}]." ) ; } return [ $ class -> newInstance ( ) , $ method -> getName ( ) ] ; }
Get instance callable.

@param  \ReflectionMethod  $method
@return callable

@throws \Sofa\Eloquence\Mutator\InvalidCallableException
Get instance callable .