Pull merge.
[yaffs-website] / vendor / symfony / validator / ValidatorBuilder.php
index 704d76baad0f0b09fd5ccd4963da9e91857c450f..3562b945922af3ac34bea7bca8efaf16cfff99e5 100644 (file)
@@ -37,24 +37,9 @@ use Symfony\Component\Validator\Validator\RecursiveValidator;
  */
 class ValidatorBuilder implements ValidatorBuilderInterface
 {
-    /**
-     * @var array
-     */
     private $initializers = array();
-
-    /**
-     * @var array
-     */
     private $xmlMappings = array();
-
-    /**
-     * @var array
-     */
     private $yamlMappings = array();
-
-    /**
-     * @var array
-     */
     private $methodMappings = array();
 
     /**
@@ -83,7 +68,7 @@ class ValidatorBuilder implements ValidatorBuilderInterface
     private $translator;
 
     /**
-     * @var null|string
+     * @var string|null
      */
     private $translationDomain;
 
@@ -228,7 +213,7 @@ class ValidatorBuilder implements ValidatorBuilderInterface
      */
     public function setMetadataFactory(MetadataFactoryInterface $metadataFactory)
     {
-        if (count($this->xmlMappings) > 0 || count($this->yamlMappings) > 0 || count($this->methodMappings) > 0 || null !== $this->annotationReader) {
+        if (\count($this->xmlMappings) > 0 || \count($this->yamlMappings) > 0 || \count($this->methodMappings) > 0 || null !== $this->annotationReader) {
             throw new ValidatorException('You cannot set a custom metadata factory after adding custom mappings. You should do either of both.');
         }
 
@@ -318,9 +303,9 @@ class ValidatorBuilder implements ValidatorBuilderInterface
             $loaders = $this->getLoaders();
             $loader = null;
 
-            if (count($loaders) > 1) {
+            if (\count($loaders) > 1) {
                 $loader = new LoaderChain($loaders);
-            } elseif (1 === count($loaders)) {
+            } elseif (1 === \count($loaders)) {
                 $loader = $loaders[0];
             }