Code Duplication    Length = 10-10 lines in 2 locations

src/Builder.php 2 locations

@@ 416-425 (lines=10) @@
413
         * Iterate all properties and create internal scope reflection class instance if
414
         * at least one property in not public
415
         */
416
        foreach ($propertiesMetadata as $propertyMetadata) {
417
            if (!$propertyMetadata->isPublic) {
418
                $this->generator
419
                    ->comment('Create reflection class for injecting private/protected properties and methods')
420
                    ->newLine($reflectionVariable . ' = new \ReflectionClass(\'' . $className . '\');')
421
                    ->newLine();
422
423
                return true;
424
            }
425
        }
426
427
        /**
428
         * Iterate all properties and create internal scope reflection class instance if
@@ 431-440 (lines=10) @@
428
         * Iterate all properties and create internal scope reflection class instance if
429
         * at least one property in not public
430
         */
431
        foreach ($methodsMetadata as $methodMetadata) {
432
            if (!$methodMetadata->isPublic) {
433
                $this->generator
434
                    ->comment('Create reflection class for injecting private/protected properties and methods')
435
                    ->newLine($reflectionVariable . ' = new \ReflectionClass(\'' . $className . '\');')
436
                    ->newLine();
437
438
                return true;
439
            }
440
        }
441
442
        return false;
443
    }