public function getPredecessors()
{
/*
* predecessors is a multivalue property with REFERENCE.
* get it as string so we can create the Version instances from uuid
* with the objectManager. see 3.13.2.6
*/
$predecessors = $this->getProperty("jcr:predecessors")->getString();
$results = array();
foreach ($predecessors as $uuid) {
// OPTIMIZE: use objectManager->getNodes instead of looping
$results[] = $this->objectManager->getNodeByIdentifier($uuid, 'Version\\Version');
}
return $results;
}