|
|
@ -91,3 +91,25 @@ class IslandoraTuque { |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function islandora_object_load($object_id) { |
|
|
|
|
|
|
|
static $islandora_tuque = NULL; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(!$islandora_tuque) { |
|
|
|
|
|
|
|
$islandora_tuque = new IslandoraTuque(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(IslandoraTuque::exists()) { |
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
$fedora_object = $islandora_tuque->repository->getObject($object_id); |
|
|
|
|
|
|
|
} catch (Exception $e) { |
|
|
|
|
|
|
|
return NULL; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
return $fedora_object; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else { |
|
|
|
|
|
|
|
IslandoraTuque::getError(); |
|
|
|
|
|
|
|
return NULL; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|