Code Duplication    Length = 10-12 lines in 2 locations

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

@@ 532-543 (lines=12) @@
529
     *
530
     * @param string $repositoryClassName The class name of the custom repository.
531
     */
532
    public function setCustomRepositoryClass($repositoryClassName)
533
    {
534
        if ($this->isEmbeddedDocument) {
535
            return;
536
        }
537
        
538
        if ($repositoryClassName && strpos($repositoryClassName, '\\') === false && strlen($this->namespace)) {
539
            $repositoryClassName = $this->namespace . '\\' . $repositoryClassName;
540
        }
541
542
        $this->customRepositoryClassName = $repositoryClassName;
543
    }
544
545
    /**
546
     * Dispatches the lifecycle event of the given document by invoking all
@@ 1720-1729 (lines=10) @@
1717
     *
1718
     * @param string[] $subclasses The names of all mapped subclasses.
1719
     */
1720
    public function setSubclasses(array $subclasses)
1721
    {
1722
        foreach ($subclasses as $subclass) {
1723
            if (strpos($subclass, '\\') === false && strlen($this->namespace)) {
1724
                $this->subClasses[] = $this->namespace . '\\' . $subclass;
1725
            } else {
1726
                $this->subClasses[] = $subclass;
1727
            }
1728
        }
1729
    }
1730
1731
    /**
1732
     * Sets the parent class names.