Browse Source

Updated documentation to use the list style instead of @code sections.

pull/243/head
Nigel Banks 12 years ago
parent
commit
12cce15665
  1. 71
      islandora.api.php

71
islandora.api.php

@ -100,24 +100,22 @@ function hook_islandora_edit_object_alter(&$object, &$rendered) {
* @param AbstractFedoraObject $object * @param AbstractFedoraObject $object
* The object to alter. * The object to alter.
* @param array $context * @param array $context
* The context for the alter action, this will always contain at the * An associative array containing:
* following properties. * - action: A string either 'ingest', 'purge', 'modify'.
* * - block: Either TRUE or FALSE, if TRUE the action won't take place.
* @code * Defaults to FALSE.
* array( * - purge: Either TRUE or FALSE, only present when the action is 'purge'.
* // Either 'ingest', 'purge', 'modify'. * If 'delete' or 'block' is set to TRUE, they will take precedence.
* 'action' => 'ingest', * Defaults to TRUE.
* // Either TRUE or FALSE, if TRUE the action won't take place. * - delete: Either TRUE or FALSE, only present when the action is 'purge'.
* // Set by the implementing alter hook. * If TRUE it will cause the object's state to be set to 'D' instead.
* 'block' => FALSE, * If 'block' is set to TRUE, it will take precedence.
* ) * Defaults to FALSE,
* @endcode * - params: An associative array, only present when the action is 'modify'.
* * The key value pairs repersent what values will be changed. The params
* When the action is "purge" two additional boolean properties are present * will match the same params as passed to FedoraApiM::modifyObject().
* 'delete' defaults to FALSE, and 'purge' defaults to TRUE. If only purge *
* is set to TRUE the object will be 'purged' if delete is set to TRUE and * @see FedoraApiM::modifyObject()
* block is not then the object state will be set to 'Deleted'. If 'block'
* is set to TRUE the object will not be deleted or purged.
*/ */
function hook_islandora_object_alter(AbstractFedoraObject $object, array &$context) { function hook_islandora_object_alter(AbstractFedoraObject $object, array &$context) {
} }
@ -151,27 +149,22 @@ function hook_CMODEL_PID_islandora_object_alter(AbstractFedoraObject $object, ar
* @param AbstractFedoraDatastream $datastream * @param AbstractFedoraDatastream $datastream
* The datastream to alter. * The datastream to alter.
* @param array $context * @param array $context
* The context for the alter action, this will always contain at the * An associative array containing:
* following properties. * - action: A string either 'ingest', 'purge', 'modify'.
* * - block: Either TRUE or FALSE, if TRUE the action won't take place.
* @code * Defaults to FALSE.
* array( * - purge: Either TRUE or FALSE, only present when the action is 'purge'.
* // Either 'ingest', 'purge', 'modify'. * If 'delete' or 'block' is set to TRUE, they will take precedence.
* 'action' => 'ingest', * Defaults to TRUE.
* // Either TRUE or FALSE, if TRUE the action won't take place. * - delete: Either TRUE or FALSE, only present when the action is 'purge'.
* // Set by the implementing alter hook. * If TRUE it will cause the object's state to be set to 'D' instead.
* 'block' => FALSE, * If 'block' is set to TRUE, it will take precedence.
* ) * Defaults to FALSE,
* @endcode * - params: An associative array, only present when the action is 'modify'.
* * The key value pairs repersent what values will be changed. The params
* When the action is "purge" two additional boolean properties are present * will match the same params as passed to FedoraApiM::modifyDatastream().
* 'delete' (defaults to FALSE), and 'purge' (defaults to TRUE). If only purge *
* is set to TRUE the datastream will be 'purged' if delete is set to TRUE and * @see FedoraApiM::modifyDatastream()
* block is not then the datastream state will be set to 'Deleted'. If 'block'
* is set to TRUE the datastream will not be deleted or purged.
*
* When the action is "modify" there is an additional property "params" that
* contains the modifications about to take place.
*/ */
function hook_islandora_datastream_alter(AbstractFedoraObject $object, AbstractFedoraDatastream $datastream, array &$context) { function hook_islandora_datastream_alter(AbstractFedoraObject $object, AbstractFedoraDatastream $datastream, array &$context) {
} }

Loading…
Cancel
Save