Code Duplication    Length = 10-12 lines in 2 locations

lib/Doctrine/ODM/MongoDB/Mapping/ClassMetadataInfo.php 2 locations

@@ 515-526 (lines=12) @@
512
     *
513
     * @param string $repositoryClassName The class name of the custom repository.
514
     */
515
    public function setCustomRepositoryClass($repositoryClassName)
516
    {
517
        if ($this->isEmbeddedDocument) {
518
            return;
519
        }
520
        
521
        if ($repositoryClassName && strpos($repositoryClassName, '\\') === false && strlen($this->namespace)) {
522
            $repositoryClassName = $this->namespace . '\\' . $repositoryClassName;
523
        }
524
525
        $this->customRepositoryClassName = $repositoryClassName;
526
    }
527
528
    /**
529
     * Dispatches the lifecycle event of the given document by invoking all
@@ 1664-1673 (lines=10) @@
1661
     *
1662
     * @param string[] $subclasses The names of all mapped subclasses.
1663
     */
1664
    public function setSubclasses(array $subclasses)
1665
    {
1666
        foreach ($subclasses as $subclass) {
1667
            if (strpos($subclass, '\\') === false && strlen($this->namespace)) {
1668
                $this->subClasses[] = $this->namespace . '\\' . $subclass;
1669
            } else {
1670
                $this->subClasses[] = $subclass;
1671
            }
1672
        }
1673
    }
1674
1675
    /**
1676
     * Sets the parent class names.