Code Duplication    Length = 6-6 lines in 5 locations

lib/Doctrine/ORM/Mapping/Driver/NewAnnotationDriver.php 5 locations

@@ 87-92 (lines=6) @@
84
        );
85
86
        // Evaluate @Cache annotation
87
        if (isset($classAnnotations[Annotation\Cache::class])) {
88
            $cacheAnnot = $classAnnotations[Annotation\Cache::class];
89
            $cache      = $this->convertCacheAnnotationToCacheMetadata($cacheAnnot, $classMetadata);
90
91
            $classMetadata->setCache($cache);
92
        }
93
94
        // Evaluate annotations on properties/fields
95
        /* @var \ReflectionProperty $reflectionProperty */
@@ 716-721 (lines=6) @@
713
        }
714
715
        // Check for Cache
716
        if (isset($propertyAnnotations[Annotation\Cache::class])) {
717
            $cacheAnnot    = $propertyAnnotations[Annotation\Cache::class];
718
            $cacheMetadata = $this->convertCacheAnnotationToCacheMetadata($cacheAnnot, $classMetadata, $fieldName);
719
720
            $assocMetadata->setCache($cacheMetadata);
721
        }
722
723
        // Check for JoinColumn/JoinColumns annotations
724
        switch (true) {
@@ 795-800 (lines=6) @@
792
        }
793
794
        // Check for Cache
795
        if (isset($propertyAnnotations[Annotation\Cache::class])) {
796
            $cacheAnnot    = $propertyAnnotations[Annotation\Cache::class];
797
            $cacheMetadata = $this->convertCacheAnnotationToCacheMetadata($cacheAnnot, $classMetadata, $fieldName);
798
799
            $assocMetadata->setCache($cacheMetadata);
800
        }
801
802
        // Check for JoinColumn/JoinColumns annotations
803
        switch (true) {
@@ 886-891 (lines=6) @@
883
        }
884
885
        // Check for Cache
886
        if (isset($propertyAnnotations[Annotation\Cache::class])) {
887
            $cacheAnnot    = $propertyAnnotations[Annotation\Cache::class];
888
            $cacheMetadata = $this->convertCacheAnnotationToCacheMetadata($cacheAnnot, $classMetadata, $fieldName);
889
890
            $assocMetadata->setCache($cacheMetadata);
891
        }
892
893
        return $assocMetadata;
894
    }
@@ 963-968 (lines=6) @@
960
        }
961
962
        // Check for Cache
963
        if (isset($propertyAnnotations[Annotation\Cache::class])) {
964
            $cacheAnnot    = $propertyAnnotations[Annotation\Cache::class];
965
            $cacheMetadata = $this->convertCacheAnnotationToCacheMetadata($cacheAnnot, $classMetadata, $fieldName);
966
967
            $assocMetadata->setCache($cacheMetadata);
968
        }
969
970
        return $assocMetadata;
971
    }