public function attachParents(array $parents)
    {
        $this->_parents = [];

        foreach ($parents as $parent) {
            $this->attachParent($parent, false);
        }
    }
public function attachParents(array $parents)
    {
        $this->_parents = [];

        foreach ($parents as $parent) {
            $this->attachParent($parent, false);
        }
    }
public function attachParents ( array $ parents ) { $ this -> _parents = [ ] ; foreach ( $ parents as $ parent ) { $ this -> attachParent ( $ parent , false ) ; } }
Loops on each given parent and attach it to this object.

The order matters: the first item will be added as a direct parent
whereas the last one will be the remote parent.

Note that this function will also reset

@param object[] $parents
Loops on each given parent and attach it to this object .