Matthias\SymfonyServiceDefinitionValidator\ServiceDefinitionValidator::validateFactoryClassAndMethod PHP Method

validateFactoryClassAndMethod() private method

private validateFactoryClassAndMethod ( $factoryClass, $factoryMethod )
    private function validateFactoryClassAndMethod($factoryClass, $factoryMethod)
    {
        if ($factoryClass && !$factoryMethod) {
            throw new MissingFactoryMethodException();
        }
        $factoryClass = $this->resolveValue($factoryClass);
        if (!class_exists($factoryClass) && !interface_exists($factoryClass)) {
            throw new ClassNotFoundException($factoryClass);
        }
        if (!method_exists($factoryClass, $factoryMethod)) {
            throw new MethodNotFoundException($factoryClass, $factoryMethod);
        }
    }