Subscribers/DoctrineEncryptSubscriber.php
private function encryptorFactory($classFullName, $secretKey) {
        $refClass = new \ReflectionClass($classFullName);
        if ($refClass->implementsInterface(self::ENCRYPTOR_INTERFACE_NS)) {
            return new $classFullName($secretKey);
        } else {
            throw new \RuntimeException('Encryptor must implements interface EncryptorInterface');
        }
    }
private function encryptorFactory($classFullName, $secretKey) {
        $refClass = new \ReflectionClass($classFullName);
        if ($refClass->implementsInterface(self::ENCRYPTOR_INTERFACE_NS)) {
            return new $classFullName($secretKey);
        } else {
            throw new \RuntimeException('Encryptor must implements interface EncryptorInterface');
        }
    }
private function encryptorFactory ( $ classFullName , $ secretKey ) { $ refClass = new \ ReflectionClass ( $ classFullName ) ; if ( $ refClass -> implementsInterface ( self :: ENCRYPTOR_INTERFACE_NS ) ) { return new $ classFullName ( $ secretKey ) ; } else { throw new \ RuntimeException ( 'Encryptor must implements interface EncryptorInterface' ) ; } }
Encryptor factory. Checks and create needed encryptor
@param string $classFullName Encryptor namespace and name
@param string $secretKey Secret key for encryptor
@return EncryptorInterface
@throws \RuntimeException
Encryptor factory . Checks and create needed encryptor