protected function newValidator(ResourceConfiguration $config)
 {
     $class = $config->getValidatorClass();
     return $config->isUsingYamlValidation() ? new YamlResourceValidator($config->getYamlValidation()) : new SymfonyResourceValidator(new $class(), $this->container->get('form.factory'));
 }