/**
* {@inheritdoc}
*/
protected function buildCollection(array $nodes)
{
$collection = new ArrayResourceCollection();
if (!$nodes) {
return $collection;
}
foreach ($nodes as $node) {
$path = $this->unresolvePath($node->getPath());
$resource = new PhpcrResource($path, $node);
$resource->attachTo($this);
$collection->add($resource);
}
return $collection;
}