public function getEntityIterator(IEntity $parent = null)
{
if ($this->relationshipMapper) {
return $this->relationshipMapper->getIterator($parent, $this);
}
if ($this->result === null) {
$this->execute();
}
return new EntityIterator($this->result);
}