1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
<?php
/**
* @author @jenschude <jens.schulze@commercetools.de>
*/
namespace Commercetools\Core\Model\Common;
interface ObjectTreeInterface
{
/**
* set the parent of the object, has to be set on instantiation
* @param $parent
* @return static
*/
public function parentSet($parent);
/**
* sets the root of the object hierarchy, has to be set on instantiation
* @param $parent
* @return static
*/
public function rootSet($parent);
/**
* returns the root of the object hierarchy
* if no root is given returns the object itself
* @return object
*/
public function rootGet();
}