Browse Source

Merge pull request #10 from bwoodhead/6.x

Removed ILives.
pull/11/head
Ben Woodhead 13 years ago
parent
commit
9e4ffd059c
  1. 337
      ilives/book.inc
  2. 7
      ilives/fedora_ilives.info
  3. 14
      ilives/fedora_ilives.install
  4. 749
      ilives/fedora_ilives.module
  5. 110
      ilives/image_rotator_tagger_block.inc
  6. 67
      ilives/searchTerms.xml
  7. 133
      ilives/tests/fedora_ilives.test
  8. 83
      ilives/tests/test_files/mods_record.xml
  9. 22
      ilives/xml/book_collection_policy.xml
  10. 139
      ilives/xml/ilives_CollectionModel.xml
  11. 524
      ilives/xml/ilives_bookCModel.xml
  12. 56
      ilives/xml/ilives_collection.xml
  13. 20
      ilives/xml/ilives_figuresCModel.xml
  14. 81
      ilives/xml/ilives_jp2Sdef.xml
  15. 179
      ilives/xml/ilives_jp2Sdep-pageCModel.xml
  16. 101
      ilives/xml/ilives_pageCModel.xml
  17. 64
      ilives/xml/ilives_tei2htmlSdef.xml
  18. 233
      ilives/xml/ilives_tei2htmlSdep-pageCModel.xml
  19. 64
      ilives/xml/ilives_viewerSdef.xml
  20. 133
      ilives/xml/ilives_viewerSdep-bookCModel.xml
  21. 133
      ilives/xml/ilives_viewerSdep-pageCModel.xml
  22. 412
      ilives/xsl/MODS3-22simpleDC.xsl
  23. 174
      ilives/xsl/book_view.xsl
  24. 45
      ilives/xsl/book_view.xsl.bak
  25. 44
      ilives/xsl/book_view.xsl2009-05-26
  26. 165
      ilives/xsl/pageResults.xsl
  27. 395
      ilives/xsl/results.xsl

337
ilives/book.inc

@ -1,337 +0,0 @@
<?php
/**
* @file
*
*/
class IslandoraBook {
function __construct($pid = '') {
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
if (!empty($pid)) {
$this->pid = $pid;
$this->item = new Fedora_Item($pid);
}
}
public function buildDrupalForm($form = array(), $ingest_form = array(), &$form_state = array()) {
$mods_save = '';
if (isset($form_state['mods_save'])) {
$mods_save = $form_state['mods_save'];
}
// Set #cache to true to create the $form_state cache
$form['#cache'] = TRUE;
// Give the user an option to enter a custom PID
$form['custom_pid'] = array(
'#type' => 'textfield',
'#title' => 'Custom PID',
'#description' => 'If you want to manually specify the PID for the new object, enter it here. ' .
'Leave it blank for an automatically-generated PID.',
);
// Prompt the user to enter a record ID to be looked up in Evergreen.
$form['unapi_url'] = array(
'#type' => 'textfield',
'#title' => 'Catalogue item URL',
);
$form['unapi_url_submit'] = array(
'#type' => 'submit',
'#value' => t('Retrieve MODS record'),
'#submit' => array('fedora_ilives_retrieve_unapi_submit'),
'#ahah' => array(
'path' => 'fedora/ilives/retrieve_unapi/js', // path we defined in hook_menu
'wrapper' => 'mods-wrapper', // the HTML that wraps the element that needs to be replaced
'method' => 'replace', // the method we're going to use: a replace operation
//'effect' => 'fade', // the effect used when replacing the element (try fade!)
),
'#suffix' => '<br/>',
);
drupal_add_js('', 'inline');
// We define a <div> wrapper. Everything in it will be replaced.
$form['mods'] = array(
'#tree' => TRUE,
'#prefix' => '<div id="mods-wrapper">',
'#suffix' => '</div>',
);
$form['mods']['mods_record'] = array(
'#type' => 'textarea',
'#title' => 'MODS Record to Import',
'#rows' => 20,
);
if (!empty($mods_save)) {
$form['mods']['mods_record']['#value'] = $mods_save['mods']['mods_record'];
}
return $form;
}
public function buildEditMetadataForm($form = array()) {
$form['submit'] = array(
'#type' => 'submit',
'#weight' => 10,
'#value' => 'Update'
);
$form['pid'] = array(
'#type' => 'hidden',
'#value' => $this->pid,
);
$form['dsid'] = array(
'#type' => 'hidden',
'#value' => "DARWIN_CORE",
);
return $this->buildDrupalForm($form);
}
public function handleEditMetadataForm($form_id, $form_values) {
/*
* Process the metadata form
* Update the datastreams
*/
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
module_load_include('inc', 'fedora_repository', 'plugins/DarwinCore');
module_load_include('inc', 'fedora_repository', 'MimeClass');
global $user;
$mimetype = new MimeClass();
$dwc = new DarwinCore($this->item);
$dwc->handleForm($form_values);
$this->item->purge_datastream('DARWIN_CORE');
$this->item->add_datastream_from_string($dwc->darwinCoreXML, 'DARWIN_CORE',
'Darwin Core Metadata', 'text/xml', 'X');
return TRUE;
}
public function handleIngestForm($form_values, &$form_state) {
/*
* process the metadata form
* Create fedora object
* Add the datastreams
*/
module_load_include('inc', 'fedora_repository', 'MimeClass');
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
if ($form_state['clicked_button']['#value'] == 'Retrieve MODS record') {
return;
}
$mods_list_doc = new DomDocument();
$mods_list_doc->loadXML($form_values['mods']['mods_record']);
$mods_item_doc = new DomDocument();
$mods_item = $mods_list_doc->getElementsByTagNameNS('http://www.loc.gov/mods/v3', 'mods')->item(0);
$new_mods_item = $mods_item_doc->importNode($mods_item, TRUE);
$mods_item_doc->appendChild($new_mods_item);
$title_info = $mods_item_doc->getElementsByTagNameNS('http://www.loc.gov/mods/v3', 'titleInfo')->item(0);
$title = '';
foreach (array('nonSort', 'title') as $title_field) {
$title .= $title_info->getElementsByTagNameNS('http://www.loc.gov/mods/v3', $title_field)->item(0)->nodeValue . ' ';
}
$title = trim($title);
$mods_text = $mods_item_doc->saveXML();
global $user;
$mimetype = new MimeClass();
$new_item = Fedora_Item::ingest_new_item(!empty($form_values['custom_pid']) ? $form_values['custom_pid'] : $form_values['pid'], 'A', $title,
$user->name);
$new_item->add_datastream_from_string($mods_text, 'MODS',
'MODS Metadata', 'text/xml', 'X');
$dc = transform_mods_to_dc($mods_text);
if ($dc) {
// Add the PID to a dc:identifier field.
$dc_doc = simplexml_load_string($dc);
$dc_doc->registerXPathNamespace('oai_dc', 'http://www.openarchives.org/OAI/2.0/oai_dc/');
$dc_item = $dc_doc->xpath('//oai_dc:dc');
foreach ($dc_item as $node) {
$node->addChild('dc:identifier', $new_item->pid, 'http://purl.org/dc/elements/1.1/');
}
$new_item->modify_datastream_by_value($dc_doc->saveXML(), 'DC', 'Dublin Core XML Metadata', 'text/xml');
}
$new_item->add_relationship('hasModel', $form_values['content_model_pid'], FEDORA_MODEL_URI);
$new_item->add_relationship(!empty($form_values['relationship']) ? $form_values['relationship'] : 'isMemberOfCollection', $form_values['collection_pid']);
drupal_set_message(t("Item !pid created successfully.", array('!pid' => l($new_item->pid, 'fedora/repository/' . $new_item->pid))), "status");
}
public function buildAddPagesForm($form = array()) {
}
public function showFieldSets() {
module_load_include('inc', 'fedora_repository', 'plugins/tagging_form');
module_load_include('inc', 'fedora_repository', 'plugins/DarwinCore');
module_load_include('module', 'fedora_ilives');
global $base_url;
$show_purge_tab = (!empty($_POST['form_id']) && ($_POST['form_id'] == 'fedora_ilives_purge_pages_form'));
$first_page = new Fedora_Item($this->pid . '-001');
$hasPage = $first_page->exists();
$tabset = array();
global $user;
$qs = '';
if ($user->uid != 0) {
$qs = '?uid=' . base64_encode($user->name . ':' . $user->pass);
}
$viewer_url = variable_get('fedora_base_url', '') . '/get/' . $this->pid . '/ilives:viewerSdef/getViewer' . $qs;
$html = '<iframe src="' . $viewer_url . '" scrolling="0" frameborder="0" style="width: 100%; height: 800px;">Errors: unable to load viewer</iframe>';
$tabset['first_tab'] = array(
// #type and #title are the minimum requirements.
'#type' => 'tabpage',
'#title' => t('Description'),
// This will be the content of the tab.
'#content' => fedora_ilives_create_book_view($this->pid),
);
if ($hasPage) {
$tabset['second_tab'] = array(
'#type' => 'tabpage',
'#title' => t('Read'),
'#content' => $html
);
}
if (!$hasPage && user_access('ingest new fedora objects')) {
$tabset['third_tab'] = array(
'#type' => 'tabpage',
'#title' => t('Add pages'),
'#content' => drupal_get_form('book_add_pages_form', $this->pid),
);
}
if ($hasPage && user_access('purge objects and datastreams')) {
$tabset['fourth_tab'] = array(
'#type' => 'tabpage',
'#title' => t('Purge all pages'),
'#selected' => $show_purge_tab,
'#content' => drupal_get_form('fedora_ilives_purge_pages_form', $this->pid),
);
}
return $tabset;
}
}
function book_add_pages_form(&$form_state, $pid, $page_cmodel = 'ilives:pageCModel', $relation = 'isMemberOf') {
$form['pid'] = array(
'#type' => 'hidden',
'#value' => $pid,
);
$form['page_cmodel'] = array(
'#type' => 'hidden',
'#value' => $page_cmodel,
);
$form['relation'] = array(
'#type' => 'hidden',
'#value' => $relation,
);
$form['tiff_dir'] = array(
'#type' => 'textfield',
'#title' => t('TIFF folder'),
'#required' => TRUE,
'#description' => t('Path to a web-accessible folder contining the book\'s page images in TIFF format on this server.'),
);
$form['submit'] = array(
'#type' => 'submit',
'#weight' => 10,
'#value' => 'Ingest Pages'
);
return $form;
}
function book_add_pages_form_validate($form, &$form_state) {
if ($form_state['values']['tiff_dir'] == '') {
form_set_error('', t('You must select a name for this group of settings.'));
}
}
function book_add_pages_form_submit($form, &$form_state) {
$pid = $form_state['values']['pid'];
if (!empty($form_state['values']['tiff_dir'])) {
$file_list = array();
if ($tiff_dir = opendir($form_state['values']['tiff_dir'])) {
while (FALSE !== ($file_name = readdir($tiff_dir))) {
$ext = strrchr($file_name, '.');
if ($ext == '.tif' || $ext == '.tiff') {
array_push($file_list, $form_state['values']['tiff_dir'] . '/' . $file_name);
}
}
closedir($tiff_dir);
sort($file_list);
ilives_create_page_objects($pid, $file_list, $form_state['values']['page_cmodel'], $form_state['values']['relation']);
}
}
}
/**
* Create a page object for each element in $image_list as a child object of $pid
*/
function ilives_create_page_objects($pid, $image_list = array(), $page_cmodel = 'ilives:pageCModel', $relation = 'isMemberOfCollection') {
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
module_load_include('inc', 'fedora_repository', 'ObjectHelper');
$book = new Fedora_Item($pid);
if (!$book->exists()) {
return FALSE;
}
$page_pids = array();
$batch = array(
'title' => 'Creating page objects',
'operations' => array(),
'file' => drupal_get_path('module', 'fedora_ilives') . '/book.inc',
);
$page_num = 1;
$book_title = $book->objectProfile->objLabel;
foreach ($image_list as $image_path) {
$batch['operations'][] = array('ilives_add_single_page_object', array($pid, $image_path, $page_num, "$book_title - Page " . sprintf("%03d", $page_num), $page_cmodel, $relation));
$page_num++;
}
batch_set($batch);
$objectHelper = new ObjectHelper;
$dc_xml = $objectHelper->getStream($pid, 'DC');
$xml = new DOMDocument();
$xml->loadXML($dc_xml);
$root = $xml->documentElement;
$typeNode = $xml->createElement('dc:type', 'ingested');
$typeNode = $xml->createElementNS("http://purl.org/dc/elements/1.1/", 'dc:type', 'ingested');
$root->appendChild($typeNode);
$book->modify_datastream_by_value($xml->saveXML(), 'DC', 'Dublin core', 'text/xml', TRUE, "Added Type of Ingest", FALSE);
}
function ilives_add_single_page_object($book_pid, $page_file, $page_num = 1, $page_title = NULL, $page_cmodel = 'ilives:pageCModel', $relation = 'isMemberOfCollection') {
module_load_include('inc', 'fedora_repository', 'api/fedora_utils');
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
$page_item = Fedora_Item::ingest_new_item("$book_pid-" . sprintf("%03d", $page_num), 'A', $page_title);
$page_item->add_relationship('hasModel', $page_cmodel, FEDORA_MODEL_URI);
$page_item->add_relationship($relation, $book_pid);
$page_item->add_datastream_from_file($page_file, 'TIFF', 'Archival TIFF', 'image/tiff', 'M');
}
function transform_mods_to_dc($mods) {
$xp = new XsltProcessor();
// create a DOM document and load the XSL stylesheet
$xsl = new DomDocument;
$xsl->load(drupal_get_path('module', 'fedora_ilives') . '/xsl/MODS3-22simpleDC.xsl');
// import the XSL styelsheet into the XSLT process
$xp->importStylesheet($xsl);
// create a DOM document and load the XML datat
$xml_doc = new DomDocument;
$xml_doc->loadXML($mods);
// transform the XML into HTML using the XSL file
if ($dc = $xp->transformToXML($xml_doc)) {
return $dc;
}
else {
return FALSE;
}
}

7
ilives/fedora_ilives.info

@ -1,7 +0,0 @@
; $Id$
name = Islandora Book
description = Provides book interface
package = Fedora Repository
dependencies[] = fedora_repository
version = 6.1dev
core = 6.x

14
ilives/fedora_ilives.install

@ -1,14 +0,0 @@
<?php
/*
* @file fedora_ilives.install
*/
/**
* Implementation of hook_enable()
*/
function fedora_ilives_enable() {
}

749
ilives/fedora_ilives.module

@ -1,749 +0,0 @@
<?php
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
function fedora_ilives_menu() {
$items = array();
$items['fedora/ilives'] = array(
'title' => t('Book view'),
'page callback' => 'fedora_ilives_create_book_view',
'type' => MENU_CALLBACK,
'access arguments' => array('view fedora collection'),
);
$items['fedora/ilives_book_viewer'] = array(
'title' => t('Book viewer'),
'page callback' => 'fedora_ilives_book_viewer',
'type' => MENU_CALLBACK,
'access arguments' => array('view fedora collection'),
);
$items['fedora/ilives_book_search'] = array(
'title' => t('Book viewer'),
'page callback' => 'fedora_ilives_book_search',
'type' => MENU_CALLBACK,
'access arguments' => array('view fedora collection'),
);
$items['fedora/ilives_page_search'] = array(
'title' => t('Book viewer'),
'page callback' => 'fedora_ilives_page_search',
'type' => MENU_CALLBACK,
'access arguments' => array('view fedora collection'),
);
// This block defines the path and the corresponding callback function.
$items['fedora/ilives/retrieve_unapi/js'] = array(
'page callback' => 'fedora_ilives_button_retrieve_unapi_ahah', // the AHAH callback function
'access arguments' => array('add fedora datastreams'),
'type' => MENU_CALLBACK,
);
return $items;
}
//function fedora_ilives_book_search($query) {
//}
//function fedora_ilives_page_search($query) {
//}
function fedora_ilives_block($op = 'list', $delta = 0, $edit = array()) {
// The $op parameter determines what piece of information is being requested.
switch ($op) {
case 'list':
// If $op is "list", we just need to return a list of block descriptions.
// This is used to provide a list of possible blocks to the administrator,
// end users will not see these descriptions.
$blocks[0] = array(
'info' => t('Book search block'),
);
$blocks[1] = array(
'info' => t('Image rotator and tagger'),
);
$blocks[2] = array(
'info' => t('Simple book search block'),
);
return $blocks;
case 'configure':
// If $op is "configure", we need to provide the administrator with a
// configuration form. The $delta parameter tells us which block is being
// configured. In this example, we'll allow the administrator to customize
// the text of the first block.
// If $op is "configure", we need to provide the administrator with a
// configuration form. The $delta parameter tells us which block is being
// configured. In this example, we'll allow the administrator to customize
// the text of the first block.
$form = array();
switch ($delta) {
case 0:
// All we need to provide is a text field, Drupal will take care of
// the other block configuration options and the save button.
$form['fedora_ilives_book_search_block_repeat'] = array(
'#type' => 'textfield',
'#title' => t('Number of times to repeat search fields'),
'#size' => 5,
'#description' => t('The number of times you would like the search blocks to be repeated'),
'#default_value' => variable_get('fedora_ilives_book_search_block_repeat', t('3')),
);
break;
case 1:
// This is the image rotator block.
$form['fedora_ilives_image_rotator_block_query'] = array(
'#type' => 'textarea',
'#title' => t('ITQL Query'),
'#description' => t('The ITQL query to return a list of images.'),
'#default_value' => variable_get('fedora_ilives_image_rotator_tagger_block_query', 'select $object $title from <#ri>
where $object <info:fedora/fedora-system:def/relations-external#isMemberOfCollection> <info:fedora/ilives:figures>
and $object <fedora-model:state> <info:fedora/fedora-system:def/model#Active>
and $object <dc:title> $title'),
);
break;
case 2:
// All we need to provide is a text field, Drupal will take care of
// the other block configuration options and the save button.
$form['fedora_ilives_simple_book_search_block_title'] = array(
'#type' => 'textfield',
'#title' => t('Title'),
'#size' => 15,
'#description' => t('The title of the block'),
'#default_value' => variable_get('fedora_ilives_simple_book_search_block_title', t('Title')),
);
break;
}
return $form;
case 'save':
// If $op is "save", we need to save settings from the configuration form.
// Since the first block is the only one that allows configuration, we
// need to check $delta to make sure we only save it.
switch ($delta) {
case 0:
// Have Drupal save the string to the database.
variable_set('fedora_ilives_book_search_block_repeat', $edit['fedora_ilives_book_search_block_repeat']);
break;
case 1:
variable_set('fedora_ilives_image_rotator_tagger_block_query', $edit['fedora_ilives_image_rotator_block_query']);
break;
case 2:
// Have Drupal save the string to the database.
variable_set('fedora_ilives_simple_book_search_block_title', $edit['fedora_ilives_simple_book_search_block_title']);
break;
}
return;
case 'view': default:
// If $op is "view", then we need to generate the block for display
// purposes. The $delta parameter tells us which block is being requested.
switch ($delta) {
case 0:
// The subject is displayed at the top of the block. Note that it
// should be passed through t() for translation.
$block['subject'] = t('Book advanced search');
// The content of the block is typically generated by calling a custom
// function.
$block['content'] = drupal_get_form('fedora_ilives_book_search_form');
break;
case 1:
module_load_include('inc', 'fedora_ilives', 'image_rotator_tagger_block');
$block['subject'] = t('Random repository image');
$block['content'] = _fedora_image_rotator_tagger_block_content();
break;
case 2:
// The subject is displayed at the top of the block. Note that it
// should be passed through t() for translation.
$block['subject'] = t('Simple Book Search');
// The content of the block is typically generated by calling a custom
// function.
$block['content'] = drupal_get_form('fedora_ilives_simple_book_search_form');
break;
}
return $block;
}
}
function fedora_ilives_book_viewer($pid) {
global $user;
$qs = '';
if ($user->uid != 0) {
// $qs = '?uid=' . base64_encode($user->name . ':' . $user->sid);
$qs = '?uid=' . base64_encode($user->name . ':' . $user->pass);
}
$viewer_url = variable_get('fedora_base_url', '') . '/get/' . $pid . '/ilives:viewerSdef/getViewer' . $qs;
$html = '<iframe src="' . $viewer_url . '" frameborder="0" scrolling="no" style="width: 100%; height: 800px;">Errors: unable to load viewer</iframe>';
$fieldset = array(
'#title' => t('Viewer - ') . $pid,
'#collapsible' => TRUE,
'#collapsed' => FALSE,
'#value' => $html);
drupal_add_css(path_to_theme() . '/header-viewer.css', 'theme');
return theme('fieldset', $fieldset);
}
//loads an xslt for the main book page uses mods for most of the display. if there is a $query parameter
// it will execute it against the book.
function fedora_ilives_create_book_view($pid, $query = NULL) {
global $user;
module_load_include('inc', 'fedora_repository', 'ObjectHelper');
$path = drupal_get_path('module', 'Fedora_Repository');
$objectHelper = new ObjectHelper;
$xml = $objectHelper->getStream($pid, 'MODS');
$dc_xml = $objectHelper->getStream($pid, 'DC');
if (!$dc_xml) {
drupal_set_message(t('Object does not exist.'), 'error');
return '';
}
$simpleDCxml = simplexml_load_string($dc_xml);
$types = $simpleDCxml->xpath('//dc:type');
$ingested = 'false';
if (!empty($types)) {
foreach ($types as $type) {
if ($type == 'ingested') {
$ingested = 'true';
}
}
}
if (!isset($pid)) {
drupal_set_message(t('Error getting book view, no identifier specified.'));
return;
}
$proc = NULL;
try {
$proc = new XsltProcessor();
} catch (Exception $e) {
drupal_set_message(t('Error loading Book View XSLT: $e', array('!e' => $e->getMessage())));
return;
}
//inject into xsl stylesheet
$proc->setParameter('', 'userID', $user->uid);
$proc->setParameter('', 'objectsPage', base_path());
$proc->setParameter('', 'pid', $pid);
$proc->setParameter('', 'ingested', $ingested);
$xsl = new DomDocument();
$test = $xsl->load($path . '/ilives/xsl/book_view.xsl');
if (!isset($test)) {
drupal_set_message(t('Error loading search results XSLT.'));
return t('Error loading search results XSLT.');
}
$input = new DomDocument();
$didLoadOk = $input->loadXML($xml);
$output = NULL;
if (!isset($didLoadOk)) {
drupal_set_message(t('Error loading Book View XML.'));
return t('Error loading Book View XML.');
}
else {
$xsl = $proc->importStylesheet($xsl);
$newdom = $proc->transformToDoc($input);
$output .= $newdom->saveXML();
}
if (isset($query)) {
module_load_include('inc', 'fedora_repository', 'SearchClass');
$searchClass = new SearchClass();
$pageQuery = convert_query_to_page_query($query, $pid);
$output .= '<div>' . $searchClass->custom_search($pageQuery, $startPage, '/ilives/xsl/pageResults.xsl', 500) . '</div>'; //limit results to 500 pages of a book since there is no paging if we enable paging in xslt this can be changed
//return $output."<div>used this query to find this page $query and new query = $pageQuery</div>";
return $output;
}
else {
return $output;
}
}
function convert_query_to_page_query($query, $pid) {
$newQuery = substr($query, 0, strlen($query) - 23);
$pid = str_replace(':', '?', $pid);
$newQuery = $newQuery . " AND PID:$pid* AND dc.type:Text";
//$newQuery=htmlentities(urlencode($newQuery));
return $newQuery;
}
/**
* Custom form element to do our nice images.
*/
function fedora_ilives_elements() { // Change this line
$type['imagebutton'] = array(
'#input' => TRUE,
'#button_type' => 'submit',
'#executes_submit_callback' => TRUE,
'#name' => 'op',
'#process' => array('hook_imagebutton_process' => array()),
);
return $type;
}
function theme_imagebutton($element) {
return '<input style="background:url(\'\'); border:0px; width:10px; padding:0px,0px,0px,0px;" type="image" class="form-' . $element['#button_type'] . '" name="' . $element['#name'] . '" id="' . $element['#id'] . '" value="' . check_plain($element['#default_value']) . '" ' . drupal_attributes($element['#attributes']) . ' src="' . $element['#image'] . '" alt="' . $element['#title'] . '" title="' . $element['#title'] . "\" />\n";
}
/**
* Implementation of hook_theme() to register how to theme image buttons.
*/
function fedora_ilives_theme() {
return array(
'imagebutton' => array(
'arguments' => array('form' => NULL),
),
'fedora_ilives_book_search_form' => array(
'arguments' => array('form' => NULL),
),
'fedora_ilives_simple_book_search_form' => array(
'arguments' => array('form' => NULL),
)
);
}
//return array(
// 'fedora_repository_mnpl_advanced_search_form' => array(
// 'arguments' => array('form' => NULL)
// )
// );
function theme_fedora_ilives_book_search_form($form) {
module_load_include('inc', 'fedora_repository', 'SearchClass');
$advanced_search_form = new SearchClass();
$repeats = variable_get('fedora_ilives_book_search_block_repeat', t('3'));
return $advanced_search_form->theme_advanced_search_form($form, $repeats);
}
function fedora_ilives_simple_book_search_form($form) {
$form = array();
$form['search_type']['type1'] = array(
'#title' => t(''),
'#type' => 'hidden',
'#default_value' => 'tei.fullText'
);
$form['fedora_terms1'] = array(
'#size' => '24',
'#type' => 'textfield',
'#title' => t(''),
'#required' => TRUE,
'#default_value' => ''
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('search')
);
return $form;
}
function fedora_ilives_simple_book_search_form_submit($form, &$form_state) {
$type_id = $form_state['values']['type'];
$searchString = $form_state['values']['type1'] . ':' . $form_state['values']['fedora_terms1'];
$searchString = trim($searchString) . '+AND+dc.type:collection';
$form_state['redirect'] = "fedora/ilives_book_search/$searchString";
//drupal_goto("fedora/ilives_book_search/$searchString");
}
function fedora_ilives_book_search_form() {
module_load_include('inc', 'fedora_repository', 'SearchClass');
$searchClass = new SearchClass();
$repeats = variable_get('fedora_ilives_book_search_block_repeat', t('3'));
$path = drupal_get_path('module', 'Fedora_Repository') . '/ilives';
$query = NULL;
if (arg(1) == 'ilives_book_search' && arg(2) != 'dc.type:ingested') {
$length = strlen(arg(2));
if (($test = strpos(arg(2), 'dc.type:collection')) > 0) {
$length = $test - 5; //get rid of the AND
}
$query = trim(substr(arg(2), 0, $length));
}
return $searchClass->build_advanced_search_form($repeats, $path, $query);
}
function fedora_ilives_book_search_form_submit($form, &$form_state) {
$type_id = $form_state['values']['type'];
$repeat = variable_get('fedora_ilives_book_search_block_repeat', t('3'));
$searchString = $form_state['values']['type1'] . ':' . $form_state['values']['fedora_terms1'];
if ($form_state['values']['fedora_terms2'] != '') {
$searchString .= '+' . $form_state['values']['andor1'] . '+' . $form_state['values']['type2'] . ':' . $form_state['values']['fedora_terms2'];
}
if ($repeat > 2 && $repeat < 9) {
for ($i = 3; $i < $repeat + 1; $i++) {
$t = $i - 1;
if ($form_state['values']["fedora_terms$i"] != '') {
$searchString .= '+' . $form_state['values']["andor$t"] . '+' . $form_state['values']["type$i"] . ':' . $form_state['values']["fedora_terms$i"];
}
}
}
$searchString = trim($searchString) . '+AND+dc.type:collection';
$form_state['redirect'] = "fedora/ilives_book_search/$searchString";
//drupal_goto("fedora/ilives_book_search/$searchString");
}
function fedora_ilives_book_search($query, $startPage = 1) {
module_load_include('inc', 'fedora_repository', 'SearchClass');
$searchClass = new SearchClass();
return $searchClass->custom_search($query, $startPage, '/ilives/xsl/results.xsl', 10);
}
function retrieve_unapi_MODS_record($url) {
$bib_response = drupal_http_request($url);
$bib_html = $bib_response->data;
$bib_doc = new DOMDocument;
@$bib_doc->loadHTML($bib_html);
$links = $bib_doc->getElementsByTagName('link');
foreach ($links as $link) {
if ($link->getAttribute('rel') == 'unapi-server') {
$unapi_server = $link->getAttribute('href');
break;
}
}
$attrs = $bib_doc->getElementsByTagName('abbr');
foreach ($attrs as $attr) {
if ($attr->getAttribute('class') == 'unapi-id') {
$unapi_id = $attr->getAttribute('title');
break;
}
}
$mods_url = "$unapi_server?id=$unapi_id&format=mods3";
$mods_resp = drupal_http_request($mods_url);
$mods_data = $mods_resp->data;
return $mods_data;
}
/**
* AHAH callback for the 'match type' select.
* This function handles the actual replace and sets the $form and $form_state arrays.
* */
function fedora_ilives_button_retrieve_unapi_ahah() {
// this part is used to set up $form_state.
// In Drupal 7, these next 11 lines will be put in a core utility function.
// Just remember you'll need them in D6 when you do AHAH.
$form_state = array('storage' => NULL, 'submitted' => FALSE);
$form_build_id = $_POST['form_build_id'];
$form = form_get_cache($form_build_id, $form_state);
$args = $form['#parameters'];
$form_id = array_shift($args);
$form['#post'] = $_POST;
$form['#redirect'] = FALSE;
$form['#programmed'] = FALSE;
$form_state['post'] = $_POST;
drupal_process_form($form_id, $form, $form_state);
$form_state['storage']['step'] = 2;
$form = drupal_rebuild_form($form_id, $form_state, $args, $form_build_id);
// From here on, we'll add our own code.
// We just get the element of $form that needs to be refreshed, and just resubmit that
// part through the json call. In this case we want to rebuild the 'kind' <div> wrapper and the
// select box it contains
$changed_elements = $form['mods']['mods_record'];
unset($changed_elements['#prefix'], $changed_elements['suffix']); // we'll unset the div to make sure it won't be repeated!
// the actual JSON call
$javascript = drupal_add_js(NULL, NULL, 'header');
drupal_json(array(
'status' => TRUE,
'data' => theme('status_messages') . drupal_render($changed_elements), // rebuild just the part that needs to be changed
'settings' => call_user_func_array('array_merge_recursive', $javascript['setting']),
));
}
/**
* This is the handler for the 'type' box: pressing this will refresh the <div> kind wrapper.
* */
function fedora_ilives_retrieve_unapi_submit($form, &$form_state) {
unset($form_state['submit_handlers']); // unset all the submit handlers in the form
form_execute_handlers('submit', $form, $form_state); // execute submit handler
$url = $form_state['values']['unapi_url'];
$mods = retrieve_unapi_MODS_record($url);
$form_state['values']['mods']['mods_record'] = $mods;
$mods_save = $form_state['values']; // store all the submitted values in the form
$form_state['mods_save'] = $mods_save; // put the values in a new form
$form_state['rebuild'] = TRUE; // set to true to make sure the form gets rebuild
return $mods_save;
}
function fedora_ilives_form_alter(&$form, &$form_state, $form_id) {
if ($form_id == 'fedora_repository_admin') {
# Custom settings for book module.
}
elseif ($form_id == 'fedora_repository_demo_objects_form') {
if (!Fedora_Item::fedora_item_exists('ilives:bookCModel')) {
$form['install_demos']['demo_collections']['#options']['ilives:bookCModel'] = 'Book-related content models and service objects';
$form['install_demos']['ingest']['#disabled'] = FALSE;
$form['#submit'][] = 'fedora_ilives_install_demos_form_submit';
}
else {
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
$book_item = new Fedora_Item('ilives:bookCModel');
$form['existing_demos']['ilives:bookCModel'] = array(
'#prefix' => '<li>',
'#value' => l($book_item->pid, $book_item->url()),
'#suffix' => '</li>',
);
}
}
}
function fedora_ilives_install_demos_form_submit($form, &$form_state) {
if ($form_state['values']['demo_collections']['ilives:bookCModel'] == 'ilives:bookCModel') {
# The ilives:bookCModel checkbox was checked
install_book_content_model_objects();
}
}
/**
* Implementation of hook_requirements().
*
* @return
* An array describing the status of the site regarding available updates.
* If there is no update data, only one record will be returned, indicating
* that the status of core can't be determined. If data is available, there
* will be two records: one for core, and another for all of contrib
* (assuming there are any contributed modules or themes enabled on the
* site). In addition to the fields expected by hook_requirements ('value',
* 'severity', and optionally 'description'), this array will contain a
* 'reason' attribute, which is an integer constant to indicate why the
* given status is being returned (UPDATE_NOT_SECURE, UPDATE_NOT_CURRENT, or
* UPDATE_UNKNOWN). This is used for generating the appropriate e-mail
* notification messages during update_cron(), and might be useful for other
* modules that invoke update_requirements() to find out if the site is up
* to date or not.
*
* @see _update_message_text()
* @see _update_cron_notify()
*/
function fedora_ilives_requirements($phase) {
global $base_url;
if ($phase == 'runtime') {
module_load_include('inc', 'fedora_repository', 'api/fedora_utils');
$requirements['iiv-war'] = array();
$requirements['iiv-war']['title'] = t("Islandora OpenLayers image viewer web app");
if (!_fedora_ilives_viewer_available()) {
$requirements['iiv-war']['value'] = ("Not available");
$requirements['iiv-war']['severity'] = REQUIREMENT_ERROR;
$requirements['iiv-war']['description'] = t('Ensure that Fedora is running and that the <a href="@iiv-home">IIV</a> app is deployed.',
array('@iiv-home' => 'http://github.com/islandora/iiv'));
}
else {
$requirements['iiv-war']['value'] = ("Available");
$requirements['iiv-war']['severity'] = REQUIREMENT_OK;
}
}
return $requirements;
}
function _fedora_ilives_viewer_available() {
$url = parse_url(variable_get('fedora_base_url', 'http://localhost:8080/fedora'));
$fedora_host = ("{$url['scheme']}://{$url['host']}" . (!empty($url['port']) ? ":{$url['port']}/" : '/'));
$response = drupal_http_request("$fedora_host/iiv/images/loading.gif");
return empty($response->error);
}
function fedora_ilives_required_fedora_objects() {
// array( 'path-to-foxml-file', 'pid', 'dsid', 'path-to-datastream-file', int dsversion, boolean required)
$module_path = drupal_get_path('module', 'fedora_ilives');
return array(
'fedora_ilives' => array(
'module' => 'fedora_ilives',
'title' => 'Island Lives Books',
'objects' => array(
array(
'foxml_file' => "$module_path/xml/ilives_pageCModel.xml",
'pid' => 'ilives:pageCModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_bookCModel.xml",
'pid' => 'ilives:bookCModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_jp2Sdef.xml",
'pid' => 'ilives:jp2Sdef',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_viewerSdef.xml",
'pid' => 'ilives:viewerSdef',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_viewerSdep-bookCModel.xml",
'pid' => 'ilives:viewerSdep-bookCModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_viewerSdep-pageCModel.xml",
'pid' => 'ilives:viewerSdep-pageCModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_tei2htmlSdef.xml",
'pid' => 'ilives:tei2htmlSdef',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_tei2htmlSdep-pageCModel.xml",
'pid' => 'ilives:tei2htmlSdep-pageCModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_collection.xml",
'pid' => 'ilives:collection',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'foxml_file' => "$module_path/xml/ilives_CollectionModel.xml",
'pid' => 'ilives:CollectionModel',
'dsid' => NULL,
'datastream_file' => NULL,
'dsversion' => NULL,
),
array(
'pid' => 'books:collection',
'label' => 'Book Collection',
'cmodel' => 'islandora:collectionCModel',
'parent' => 'islandora:demos',
'datastreams' => array(
array(
'dsid' => 'COLLECTION_POLICY',
'datastream_file' => "$module_path/xml/book_collection_policy.xml",
),
array(
'dsid' => 'TN',
'datastream_file' => "$module_path/Crystal_Clear_mimetype_man.png",
'mimetype' => 'image/png',
),
),
),
),
),
);
}
function fedora_ilives_purge_pages_form(&$form_state, $pid, $referrer = NULL) {
global $base_url;
if (!user_access('purge objects and datastreams')) {
return NULL;
}
if ($pid == NULL) {
return NULL;
}
$form['pid'] = array(
'#type' => 'hidden',
'#value' => "$pid"
);
if (!strstr(drupal_get_destination(), urlencode('fedora/repository'))) {
$form['referrer'] = array(
'#type' => 'hidden',
'#value' => $referrer,
);
}
if (!isset($form_state['storage']['confirm'])) {
// do your normal $form definition here
$form['submit'] = array(
'#type' => 'image_button',
'#src' => drupal_get_path('module', 'fedora_repository') . '/images/purge_big.png',
'#value' => t('Purge'),
'#suffix' => 'Purge all pages associated with this book',
);
return $form;
}
else {
// ALSO do $form definition here. Your final submit handler (after user clicks Yes, I Confirm) will only see $form_state info defined here. Form you create here passed as param1 to confirm_form
return confirm_form($form, 'Confirm Purge ALL pages?', $referrer, 'Are you sure you want to delete these objects? This action cannot be undone.', 'Purge Pages', 'Cancel'); //Had better luck leaving off last param 'name'
}
return $form;
}
function fedora_ilives_purge_pages_form_submit($form, &$form_state) {
module_load_include('inc', 'fedora_repository', 'ConnectionHelper');
$pid = $form_state['values']['pid'];
if (!isset($form_state['storage']['confirm'])) {
$form_state['storage']['confirm'] = TRUE; // this will cause the form to be rebuilt, entering the confirm part of the form
$form_state['rebuild'] = TRUE; // along with this
}
else {
$query = <<<XML
select \$object \$title from <#ri>
where (\$object <dc:title> \$title
and \$object <fedora-rels-ext:isMemberOf> <info:fedora/$pid>
and \$object <fedora-model:state> <info:fedora/fedora-system:def/model#Active>)
order by \$title
XML;
// this is where you do your processing after they have pressed the confirm button
module_load_include('inc', 'fedora_repoitory', 'CollectionClass');
$collection = new CollectionClass($pid);
$contents = $collection->getRelatedItems($pid, $query);
$results_xml = simplexml_load_string($contents);
$resultsarray = array();
foreach ($results_xml->results->result as $result) {
$pid_to_delete = str_replace('info:fedora/', '', $result->object->attributes()->uri);
//parse contents
$params = array(
"pid" => $pid_to_delete,
"logMessage" => "Purged",
"force" => ""
);
try {
$soapHelper = new ConnectionHelper();
$client = $soapHelper->getSoapClient(variable_get('fedora_soap_manage_url', 'http://localhost:8080/fedora/services/management?wsdl'));
$object = $client->__soapCall('purgeObject', array($params));
unset($form_state['storage']['confirm']);
} catch (exception $e) {
if (preg_match('/org\.fcrepo\.server\.security\.xacml\.pep\.AuthzDeniedException/', $e->getMessage())) {
drupal_set_message(t('Error: Insufficient permissions to purge object.'), 'error');
}
else {
drupal_set_message(t($e->getMessage()), 'error');
}
return;
}
}
if (!empty($form_state['values']['referrer'])) {
$form_state['redirect'] = $form_state['values']['referrer'];
}
elseif (empty($collectionPid) && !empty($_SESSION['fedora_collection']) && $_SESSION['fedora_collection'] != $pid) {
$collectionPid = $_SESSION['fedora_collection'];
$form_state['redirect'] = "fedora/repository/$collectionPid/";
}
else {
$form_state['redirect'] = 'fedora/repository/';
}
}
}

110
ilives/image_rotator_tagger_block.inc

@ -1,110 +0,0 @@
<?php
/**
* @file image_rotator_tagger_block.inc
*/
function get_random_image() {
module_load_include('inc', 'fedora_repository', 'CollectionClass');
module_load_include('inc', 'fedora_repository', 'ObjectHelper');
$itqlquery = 'select $object $title from <#ri>
where $object <info:fedora/fedora-system:def/relations-external#isMemberOfCollection> <info:fedora/ilives:figures>
and $object <fedora-model:state> <info:fedora/fedora-system:def/model#Active>
and $object <dc:title> $title';
$collection = new CollectionClass('ilives:figures');
$results = $collection->getRelatedItems('ilives:figures', $itqlquery);
//drupal_set_message($results);
if (empty($results)) {
return NULL;
}
$resultsdoc = new DomDocument();
$resultsdoc->loadXML($results);
$resultslist = $resultsdoc->getElementsByTagName('result');
if ($resultslist->length == 0) {
return NULL;
}
//return htmlentities(substr($results, 0, 1000));
$randresult = $resultslist->item(rand() % $resultslist->length);
if (empty($randresult)) {
return NULL;
}
$objs = $randresult->getElementsByTagName('object');
$obj = $objs->item(0);
$pid = substr($obj->getAttribute('uri'), 12);
$titles = $randresult->getElementsByTagName('title');
$title = $titles->item(0);
return array('pid' => $pid,
//'title' => $randresult->textContent);
'title' => $title->nodeValue);
}
function _fedora_image_rotator_tagger_block_content() {
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
module_load_include('inc', 'fedora_repository', 'plugins/tagging_form');
global $base_url;
if (!empty($_POST['pid'])) {
$image_item = new Fedora_Item($_POST['pid']);
$result['pid'] = $_POST['pid'];
$result['title'] = $image_item->objectProfile->objLabel;
}
elseif (empty($_POST) && !empty($_SESSION['fedora_tagged_image']['pid'])) {
$image_item = new Fedora_Item($_SESSION['fedora_tagged_image']['pid']);
$result['pid'] = $_SESSION['fedora_tagged_image']['pid'];
$result['title'] = $image_item->objectProfile->objLabel;
unset($_SESSION['fedora_tagged_image']);
}
else {
$result = get_random_image();
$image_item = new Fedora_Item($result['pid']);
}
if (!empty($result)) {
$image = theme_image( . $base_url . '/fedora/imageapi/' . $result['pid'] . '/JPG?op=scale&height=500&width=300');
return '<p>'
. l('<img src="' . $base_url . '/fedora/imageapi/' . $result['pid'] . '/JPG?op=scale&height=500&width=300" />', 'fedora/repository/' . $result['pid'], array('html' => TRUE, 'alias' => TRUE))
//. l(t("!image", array(image => $image))
. '<p>This image is from ' . l($result['title'], 'fedora/ilives_book_viewer/' . substr($image_item->pid, 0, strrpos($image_item->pid, '-')), array('html' => TRUE, 'alias' => TRUE)) . '.'
. drupal_get_form('fedora_repository_image_tagging_form', $result['pid']) . '</p>';
}
else {
return '';
}
}
/*
function fedora_ilives_preprocess_page(&$variables) {
drupal_add_js(drupal_get_path('module', 'fedora_ilives').'/fedora_ilives_ajax.js', 'theme');
return TRUE;
} */
class ShowILivesStreamsInFieldSets {
private $pid = NULL;
function ShowILivesStreamsInFieldSets($pid) {
//drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
$this->pid = $pid;
}
function showJPG() {
module_load_include('inc', 'fedora_repository', 'plugins/tagging_form');
global $base_url;
$collection_fieldset = array(
'#collapsible' => FALSE,
'#value' => '<a href="' . $base_url . '/fedora/repository/' . $this->pid . '/JPG/"><img src="' . $base_url . '/fedora/repository/' . $this->pid . '/JPG/JPG.jpg' . '" /></a>',
);
return theme('fieldset', $collection_fieldset)
. drupal_get_form('fedora_repository_image_tagging_form', $this->pid);
}
}

67
ilives/searchTerms.xml

@ -1,67 +0,0 @@
<?xml version='1.0' encoding='utf-8'?>
<search_terms>
<!--define what fields we can query as part of the advanced search for this collection-->
<default>dc.title</default>
<number_of_results>1000</number_of_results>
<term>
<field>dc.title</field>
<value>Title</value>
</term>
<term>
<field>mods.sor</field>
<value>Author</value>
</term>
<term>
<field>mods.subject</field>
<value>Subject</value>
</term>
<!--<term>
<field>mods.publisher</field>
<value>Publisher</value>
</term>-->
<term>
<field>tei.fullText</field>
<value>Text</value>
</term>
<term>
<field>tei.persName</field>
<value>People</value>
</term>
<!--<term>
<field>tei.fullName</field>
<value>Fullname</value>
</term>-->
<!--<term>
<field>tei.settlement</field>
<value>Settlement</value>
</term>
<term>
<field>tei.region</field>
<value>Region</value>
</term>-->
<term>
<field>tei.placeName</field>
<value>Places</value>
</term>
<term>
<field>tei.orgName</field>
<value>Organization Name</value>
</term>
<!-- <term>
<field>tag</field>
<value>Tags</value>
</term>
<term>
<field>tagUser</field>
<value>Tag Creator</value>
</term>-->
</search_terms>

133
ilives/tests/fedora_ilives.test

@ -1,133 +0,0 @@
<?php
/**
* @file
* Tests the functions of the Fedora Repository module.
*/
class FedoraBookTestCase extends DrupalWebTestCase {
public static function getInfo() {
return array(
'name' => 'Fedora Book',
'description' => t('The Fedora repository book content model.'),
'group' => t('fedora repository'),
);
}
function setUp() {
parent::setUp('fedora_repository', 'fedora_ilives', 'tabs');
module_load_include('inc', 'fedora_repository', 'api/fedora_item');
// Create and login user.
$repository_user = $this->drupalCreateFedoraUser(array('add fedora datastreams',
'edit fedora meta data',
'edit tags datastream',
'ingest new fedora objects',
'purge objects and datastreams',
'view fedora collection',
'view detailed list of content'));
$this->drupalLogin($repository_user);
}
public function testBookCModel() {
// First add a book collection
$pid_list = array();
// Create a collection for ingesting book content model objects.
$ingest_form = array();
$ingest_form['models'] = 'islandora:collectionCModel/ISLANDORACM';
$this->drupalPost('fedora/ingestObject/islandora:top/Islandora%20Top-Level%20Collection', $ingest_form, 'Next');
$ingest_title = $this->randomName(32);
$ingest_form_step_2['dc:title'] = $ingest_title;
$ingest_form_step_2['dc:description'] = $this->randomName(256);
$ingest_form_step_2['files[ingest-file-location]'] = realpath(drupal_get_path('module', 'fedora_ilives') . '/xml/book_collection_policy.xml');
$this->drupalPost(NULL, $ingest_form_step_2, 'Ingest');
$this->assertPattern('/Item .* created successfully./', "Verified item created.");
$pid = $this->getIngestedPid();
$this->drupalGet("fedora/repository/$pid");
$pid_list[] = $pid;
// Now add a book into the new collection
$this->pass("Create book collection $pid below top-level collection.", 'fedora book');
$ingest_book_form = array();
$ingest_book_form['models'] = 'ilives:bookCModel/ISLANDORACM';
$this->drupalPost("fedora/ingestObject/$pid/", $ingest_book_form, 'Next');
$ingest_book_form_step_2 = array();
$ingest_book_form_step_2['mods[mods_record]'] = file_get_contents(drupal_get_path('module', 'fedora_ilives') . '/tests/test_files/mods_record.xml');
$this->outputScreenContents();
$this->drupalPost(NULL, $ingest_book_form_step_2, 'Ingest');
$this->outputScreenContents();
$book_pid = $this->getIngestedPid();
$pid_list[] = $book_pid;
if (!empty($book_pid)) {
$this->pass("Successfully ingested book object $book_pid.");
}
$this->cleanUpRepository($pid_list);
}
private function cleanUpRepository($pid_list = array()) {
$this->pass("This is the PID list to purge: " . implode(", ", $pid_list));
foreach ($pid_list as $pid) {
$this->drupalPost("fedora/repository/purgeObject/$pid", array(), 'Purge');
$this->drupalPost(NULL, array(), 'Delete');
}
}
private function getIngestedPid() {
$subject = $this->drupalGetContent();
$pattern = '/">(.*)<\/a> created successfully./';
$matches = array();
$res = preg_match($pattern, $subject, $matches);
return $matches[1];
}
private function outputScreenContents($description = '', $basename = '') {
// This is a hack to get a directory that won't be cleaned up by SimpleTest.
$file_dir = file_directory_path() . '../simpletest_output_pages';
if (!is_dir($file_dir)) {
mkdir($file_dir, 0777, TRUE);
}
$output_path = "$file_dir/$basename." . $this->randomName(10) . '.html';
$rv = file_put_contents($output_path, $this->drupalGetContent());
$this->pass("$description: Contents of result page are " . l(t('here'), $output_path));
}
protected function drupalCreateFedoraUser($permissions = array('access comments', 'access content', 'post comments', 'post comments without approval')) {
// Create a role with the given permission set.
if (!($rid = $this->drupalCreateRole($permissions))) {
return FALSE;
}
// Create a user assigned to that role.
$edit = array();
$edit['name'] = 'simpletestuser';
$edit['mail'] = $edit['name'] . '@example.com';
$edit['roles'] = array($rid => $rid);
$edit['pass'] = 'simpletestpass';
$edit['status'] = 1;
$account = user_save('', $edit);
$this->assertTrue(!empty($account->uid), t('User created with name %name and pass %pass', array('%name' => $edit['name'], '%pass' => $edit['pass'])), t('User login'));
if (empty($account->uid)) {
return FALSE;
}
// Add the raw password so that we can log in as this user.
$account->pass_raw = $edit['pass'];
return $account;
}
}

83
ilives/tests/test_files/mods_record.xml

@ -1,83 +0,0 @@
<?xml version="1.0"?>
<mods:modsCollection xmlns:mods="http://www.loc.gov/mods/v3" version="3.0">
<mods:mods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.loc.gov/mods/v3" version="3.0" xsi:schemaLocation="http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-0.xsd">
<titleInfo>
<nonSort>The </nonSort>
<title>amazing Maurice and his educated rodents</title>
</titleInfo>
<name type="personal">
<namePart>Pratchett, Terry.</namePart>
<role>
<roleTerm authority="marcrelator" type="text">creator</roleTerm>
</role>
</name>
<typeOfResource>text</typeOfResource>
<genre authority="marc">novel</genre>
<originInfo>
<place>
<placeTerm type="code" authority="marccountry">enk</placeTerm>
</place>
<place>
<placeTerm type="text">London</placeTerm>
</place>
<publisher>Corgi Books</publisher>
<dateIssued>2002</dateIssued>
<dateIssued encoding="marc">2001</dateIssued>
<issuance>monographic</issuance>
</originInfo>
<language>
<languageTerm authority="iso639-2b" type="code">eng</languageTerm>
</language>
<physicalDescription>
<form authority="marcform">print</form>
<extent>269 p. ; 22 cm.</extent>
</physicalDescription>
<abstract>A talking cat, intelligent rats, and a strange boy cooperate in a Pied Piper scam until they try to con the wrong town and are confronted by a deadly evil rat king.</abstract>
<targetAudience authority="marctarget">juvenile</targetAudience>
<note type="statement of responsibility">Terry Pratchett.</note>
<note>Carnegie Medal winner.</note>
<subject authority="lcsh">
<topic>Discworld (Imaginary place)</topic>
<topic>Fiction</topic>
</subject>
<subject authority="lcsh">
<topic>Discworld (Imaginary place)</topic>
<topic>Fiction</topic>
</subject>
<subject authority="lcsh">
<topic>Rats</topic>
<topic>Fiction</topic>
</subject>
<subject authority="lcsh">
<topic>Cats</topic>
<topic>Fiction</topic>
</subject>
<subject authority="lcsh">
<topic>Fantasy fiction</topic>
</subject>
<subject authority="lcsh">
<topic>Humorous stories</topic>
</subject>
<classification authority="lcc">PZ7.P8865 Am 2002</classification>
<relatedItem>
<titleInfo>
<title>Discworld series</title>
</titleInfo>
<name type="personal">
<namePart>Pratchett, Terry.</namePart>
</name>
</relatedItem>
<identifier type="isbn">006001234X (library binding)</identifier>
<identifier type="isbn">0385601239</identifier>
<identifier type="isbn">0552546933 (pbk.)</identifier>
<recordInfo>
<recordContentSource authority="marcorg">CaNWHRN</recordContentSource>
<recordCreationDate encoding="marc">010730</recordCreationDate>
<recordChangeDate encoding="iso8601">20020314 .0</recordChangeDate>
<languageOfCataloging>
<languageTerm authority="iso639-2b" type="code">eng</languageTerm>
</languageOfCataloging>
</recordInfo>
</mods:mods>
</mods:modsCollection>

22
ilives/xml/book_collection_policy.xml

@ -1,22 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<collection_policy xmlns="http://www.islandora.ca" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="" xsi:schemaLocation="http://www.islandora.ca http://syn.lib.umanitoba.ca/collection_policy.xsd">
<content_models>
<content_model dsid="ISLANDORACM" name="Book" namespace="islandora" pid="ilives:bookCModel"></content_model>
</content_models>
<search_terms>
<term field="dc.title">dc.title</term>
<term field="dc.creator">dc.creator</term>
<term default="true" field="dc.description">dc.description</term>
<term field="dc.date">dc.date</term>
<term field="dc.identifier">dc.identifier</term>
<term field="dc.language">dc.language</term>
<term field="dc.publisher">dc.publisher</term>
<term field="dc.rights">dc.rights</term>
<term field="dc.subject">dc.subject</term>
<term field="dc.relation">dc.relation</term>
<term field="dcterms.temporal">dcterms.temporal</term>
<term field="dcterms.spatial">dcterms.spatial</term>
<term field="fgs.DS.first.text">Full Text</term>
</search_terms>
<relationship>isMemberOfCollection</relationship>
</collection_policy>

139
ilives/xml/ilives_CollectionModel.xml

@ -1,139 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject VERSION="1.1" PID="ilives:CollectionModel"
xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="IslandLives Collection Model"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-01-23T20:43:42.518Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-09-14T14:09:41.955Z"/>
</foxml:objectProperties>
<foxml:datastream ID="AUDIT" STATE="A" CONTROL_GROUP="X" VERSIONABLE="false">
<foxml:datastreamVersion ID="AUDIT.0" LABEL="Audit Trail for this object" CREATED="2009-01-23T20:43:42.518Z" MIMETYPE="text/xml" FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID></audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-01-23T20:43:42.518Z</audit:date>
<audit:justification>Created with Admin GUI &quot;New Object&quot; command</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>RELS-EXT</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-01-23T20:45:33.190Z</audit:date>
<audit:justification></audit:justification>
</audit:record>
<audit:record ID="AUDREC3">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>DC</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-01-23T20:48:22.246Z</audit:date>
<audit:justification></audit:justification>
</audit:record>
<audit:record ID="AUDREC4">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID></audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-01-26T20:27:14.697Z</audit:date>
<audit:justification>Ingested from local file /opt/fedora/export/ilives_CollectionModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC5">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID></audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-03-21T22:35:49.622Z</audit:date>
<audit:justification>Ingested from local file /Volumes/iLives/iLivesTexts/215258_jpg/Content_Models/CollectionCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC6">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID></audit:componentID>
<audit:responsibility>admin</audit:responsibility>
<audit:date>2009-09-14T14:09:41.955Z</audit:date>
<audit:justification>Fedora Object Ingested</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream ID="RELS-EXT" STATE="A" CONTROL_GROUP="X" VERSIONABLE="true">
<foxml:datastreamVersion ID="RELS-EXT1.0" LABEL="RDF Statements about this object" CREATED="2009-01-23T20:43:44.131Z" MIMETYPE="application/rdf+xml" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0" SIZE="366">
<foxml:xmlContent>
<rdf:RDF xmlns:fedora-model="info:fedora/fedora-system:def/model#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:CollectionModel">
<fedora-model:hasModel rdf:resource="info:fedora/fedora-system:ContentModel-3.0"></fedora-model:hasModel>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion ID="RELS-EXT.1" LABEL="RDF Statements about this object" CREATED="2009-01-23T20:45:33.190Z" MIMETYPE="application/rdf+xml" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0" SIZE="457">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:CollectionModel">
<hasModel xmlns="info:fedora/fedora-system:def/model#" rdf:resource="info:fedora/fedora-system:ContentModel-3.0"></hasModel>
<hasMember xmlns="info:fedora/fedora-system:def/relations-external#" rdf:resource="ilives:lowerfreetown"></hasMember>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream ID="DS-COMPOSITE-MODEL" STATE="A" CONTROL_GROUP="X" VERSIONABLE="true">
<foxml:datastreamVersion ID="DS-COMPOSITE-MODEL1.0" LABEL="Datastream Composite Model" CREATED="2009-01-23T20:43:44.131Z" MIMETYPE="text/xml" FORMAT_URI="info:fedora/fedora-system:FedoraDSCompositeModel-1.0" SIZE="1120">
<foxml:xmlContent>
<dsCompositeModel xmlns="info:fedora/fedora-system:def/dsCompositeModel#">
<comment xmlns="info:fedora/fedora-system:def/comment#">
This DS-COMPOSITE-MODEL datastream is included as a starting point to
assist in the creation of a content model. The DS-COMPOSITE-MODEL
should define the datastreams that are required for any objects
conforming to this content model.
For more information about content models, see:
http://fedora-commons.org/confluence/x/dgBI.
For examples of completed content model objects, see the demonstration
objects included with your Fedora distribution, such as:
demo:CMImage, demo:UVA_STD_IMAGE, demo:DualResImageCollection,
demo:TEI_TO_PDFDOC, and demo:XML_TO_HTMLDOC.
For more information about the demonstration objects, see:
http://fedora-commons.org/confluence/x/AwFI.
</comment>
<dsTypeModel ID="DSID">
<form MIME="text/xml"></form>
</dsTypeModel>
</dsCompositeModel>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream ID="DC" STATE="A" CONTROL_GROUP="X" VERSIONABLE="true">
<foxml:datastreamVersion ID="DC1.0" LABEL="Dublin Core Record for this object" CREATED="2009-01-23T20:43:42.518Z" MIMETYPE="text/xml" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/" SIZE="427">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>IslandLives Collection Model</dc:title>
<dc:identifier>ilives:CollectionModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion ID="DC.1" LABEL="Dublin Core Record for this object" CREATED="2009-01-23T20:48:22.246Z" MIMETYPE="text/xml" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/" SIZE="1812">
<foxml:xmlContent>
<oai_dc:dc xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>IslandLives Collection</dc:title>
<dc:description>Made possible through a generous private donation, the IslandLives project builds on the Robertson Library’s mission to preserve and share unique material relating to Prince Edward Island and demonstrates UPEI&apos;s ongoing commitment to making PEI&apos;s cultural and published heritage available to all.
Utilizing the library’s “Prince Edward Island Collection” and the latest in digitization technology, IslandLives will start by digitizing 300 or so published community histories dating from the mid-1800’s to the present day. These transformed community histories will form the basis of a rich online repository.
IslandLives will provide a variety of search interfaces that will allow users to browse and search the content by name, community, time period, and keyword. The Island community will have a whole new way to rediscover, search and share their stories.
This project will engage and build community – recruiting interested individuals from the cultural heritage community and everyday Islanders. Project staff will travel to communities and host ‘digitization days’, introducing community members to the project and its goals, providing them with an opportunity to digitize their own content, and to contribute their content to the IslandLives collection.
</dc:description>
<dc:contributor>Robertson Library, University of Prince Edward Island</dc:contributor>
<dc:identifier>ilives:CollectionModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

524
ilives/xml/ilives_bookCModel.xml

@ -1,524 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:bookCModel" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="BookCModel"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2008-12-14T00:12:52.636Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2010-09-16T17:43:54.445Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2008-12-14T00:12:52.636Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:56:58.331Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_bookCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-05-31T19:56:44.131Z</audit:date>
<audit:justification>Ingested from source repository with pid ilives:bookCModel</audit:justification>
</audit:record>
<audit:record ID="AUDREC3">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-10T17:43:56.335Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/fedora_repository/content_models/ilives_bookCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC4">
<audit:process type="Fedora API-M"/>
<audit:action>addDatastream</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-10T19:01:39.144Z</audit:date>
<audit:justification>DatastreamsPane generated this logMessage.</audit:justification>
</audit:record>
<audit:record ID="AUDREC5">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-10T19:29:20.220Z</audit:date>
<audit:justification/>
</audit:record>
<audit:record ID="AUDREC6">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-10T19:46:24.930Z</audit:date>
<audit:justification/>
</audit:record>
<audit:record ID="AUDREC7">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-16T11:27:32.059Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/Dropbox/fedora_repository/content_models/ilives_bookCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC8">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-16T11:29:54.285Z</audit:date>
<audit:justification/>
</audit:record>
<audit:record ID="AUDREC9">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-16T18:36:16.581Z</audit:date>
<audit:justification/>
</audit:record>
<audit:record ID="AUDREC10">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-16T16:14:12.989Z</audit:date>
<audit:justification>Ingested from local file /Applications/MAMP/htdocs/f3/sites/default/modules/fedora_repository/content_models/ilives_bookCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC11">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>ISLANDORACM</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-09-16T17:43:54.445Z</audit:date>
<audit:justification/>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T19:58:26.781Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.5" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="450">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:bookCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ContentModel-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<hasService rdf:resource="info:fedora/ilives:viewerSdef" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DS-COMPOSITE-MODEL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-03-11T19:16:18.656Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSCompositeModel-1.0" ID="DS-COMPOSITE-MODEL.7"
LABEL="Datastream Composite Model" MIMETYPE="text/xml" SIZE="2378">
<foxml:xmlContent>
<dsCompositeModel xmlns="info:fedora/fedora-system:def/dsCompositeModel#">
<comment xmlns="info:fedora/fedora-system:def/comment#">
This DS-COMPOSITE-MODEL datastream is included as a starting point to
assist in the creation of a content model. The DS-COMPOSITE-MODEL
should define the datastreams that are required for any objects
conforming to this content model.
For more information about content models, see:
http://fedora-commons.org/confluence/x/dgBI.
For examples of completed content model objects, see the demonstration
objects included with your Fedora distribution, such as:
demo:CMImage, demo:UVA_STD_IMAGE, demo:DualResImageCollection,
demo:TEI_TO_PDFDOC, and demo:XML_TO_HTMLDOC.
For more information about the demonstration objects, see:
http://fedora-commons.org/confluence/x/AwFI.
</comment>
<dsTypeModel ID="ABBYY_XML" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="ABBYY_OCR" ORDERED="false">
<form MIME="text/plain"/>
</dsTypeModel>
<dsTypeModel ID="TEI" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="MARCXML" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="MODS" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="METSRights" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="StructMap" ORDERED="false">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="PDF" ORDERED="false">
<form MIME="application/pdf"/>
</dsTypeModel>
<dsTypeModel ID="Correspondence" ORDERED="false">
<form MIME="application/pdf"/>
</dsTypeModel>
<dsTypeModel ID="Permission_Letter" ORDERED="false">
<form MIME="application/pdf"/>
</dsTypeModel>
<dsTypeModel ID="CoverTN" ORDERED="false">
<form MIME="image/JPG"/>
</dsTypeModel>
</dsCompositeModel>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-02-13T17:57:45.873Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC.2" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="388">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>Book Content Model</dc:title>
<dc:identifier>ilives:bookCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="ISLANDORACM" STATE="A" VERSIONABLE="true">
<foxml:datastreamVersion CREATED="2010-06-10T19:01:39.144Z" ID="ISLANDORACM.0"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="2102">
<foxml:xmlContent>
<content_model name="standard_herb">
<mimetypes>
<type>image/tiff</type>
<type>image/tif</type>
</mimetypes>
<display_in_fieldset>
<datastream id="JP2">
<method>
<module>ilives</module>
<file>plugins/herbarium.inc</file>
<class_name>Herbarium</class_name>
<method_name>showFieldSets</method_name>
</method>
</datastream>
<datastream id="TN"/>
<datastream id="DC"/>
</display_in_fieldset>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<methods>
<method>
<module>ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>ingestBook</method_name>
<datastream_id>MODS</datastream_id>
</method>
</methods>
</rule>
</ingest_rules>
<ingest_form dsid="MODS" page="2">
<form_builder_method>
<module>ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildDrupalForm</method_name>
<form_handler>handleIngestForm</form_handler>
</form_builder_method>
</ingest_form>
<edit_metadata>
<build_form_method dsid="MODS">
<module>ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildEditMetadataForm</method_name>
</build_form_method>
<submit_form_method dsid="MODS">
<module>ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>handleEditMetadataForm</method_name>
</submit_form_method>
</edit_metadata>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion CREATED="2010-06-10T19:29:20.220Z" ID="ISLANDORACM.1"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="2137">
<foxml:xmlContent>
<content_model name="standard_herb">
<mimetypes>
<type>image/tiff</type>
<type>image/tif</type>
</mimetypes>
<display_in_fieldset>
<datastream id="JP2">
<method>
<module>fedora_ilives</module>
<file>plugins/herbarium.inc</file>
<class_name>Herbarium</class_name>
<method_name>showFieldSets</method_name>
</method>
</datastream>
<datastream id="TN"/>
<datastream id="DC"/>
</display_in_fieldset>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<methods>
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>ingestBook</method_name>
<datastream_id>MODS</datastream_id>
</method>
</methods>
</rule>
</ingest_rules>
<ingest_form dsid="MODS" page="2">
<form_builder_method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildDrupalForm</method_name>
<form_handler>handleIngestForm</form_handler>
</form_builder_method>
</ingest_form>
<edit_metadata>
<build_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildEditMetadataForm</method_name>
</build_form_method>
<submit_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>handleEditMetadataForm</method_name>
</submit_form_method>
</edit_metadata>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion CREATED="2010-06-10T19:46:24.930Z" ID="ISLANDORACM.2"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="2093">
<foxml:xmlContent>
<content_model name="Book">
<mimetypes>
<type>image/tiff</type>
</mimetypes>
<display_in_fieldset>
<datastream id="JP2">
<method>
<module>fedora_ilives</module>
<file>plugins/herbarium.inc</file>
<class_name>Herbarium</class_name>
<method_name>showFieldSets</method_name>
</method>
</datastream>
<datastream id="TN"/>
<datastream id="DC"/>
</display_in_fieldset>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<methods>
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>ingestBook</method_name>
<datastream_id>MODS</datastream_id>
</method>
</methods>
</rule>
</ingest_rules>
<ingest_form dsid="MODS" page="2">
<form_builder_method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildDrupalForm</method_name>
<form_handler>handleIngestForm</form_handler>
</form_builder_method>
</ingest_form>
<edit_metadata>
<build_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildEditMetadataForm</method_name>
</build_form_method>
<submit_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>handleEditMetadataForm</method_name>
</submit_form_method>
</edit_metadata>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion CREATED="2010-06-16T11:29:54.285Z" ID="ISLANDORACM.3"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="2132">
<foxml:xmlContent>
<content_model name="Book">
<mimetypes>
<type>image/tiff</type>
</mimetypes>
<display_in_fieldset>
<datastream id="JP2">
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>showFieldSets</method_name>
</method>
</datastream>
<datastream id="TN"/>
<datastream id="MODS"/>
<datastream id="DC"/>
</display_in_fieldset>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<methods>
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>ingestBook</method_name>
<datastream_id>MODS</datastream_id>
</method>
</methods>
</rule>
</ingest_rules>
<ingest_form dsid="MODS" page="2">
<form_builder_method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildDrupalForm</method_name>
<form_handler>handleIngestForm</form_handler>
</form_builder_method>
</ingest_form>
<edit_metadata>
<build_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildEditMetadataForm</method_name>
</build_form_method>
<submit_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>handleEditMetadataForm</method_name>
</submit_form_method>
</edit_metadata>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion CREATED="2010-06-16T18:36:16.581Z" ID="ISLANDORACM.4"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="2083">
<foxml:xmlContent>
<content_model name="Book">
<mimetypes>
<type>text/xml</type>
</mimetypes>
<display_in_fieldset>
<datastream id="MODS">
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>showFieldSets</method_name>
</method>
</datastream>
<datastream id="TN"/>
<datastream id="DC"/>
</display_in_fieldset>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<methods>
<method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>ingestBook</method_name>
<datastream_id>MODS</datastream_id>
</method>
</methods>
</rule>
</ingest_rules>
<ingest_form dsid="MODS" page="2">
<form_builder_method>
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildDrupalForm</method_name>
<form_handler>handleIngestForm</form_handler>
</form_builder_method>
</ingest_form>
<edit_metadata>
<build_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>buildEditMetadataForm</method_name>
</build_form_method>
<submit_form_method dsid="MODS">
<module>fedora_ilives</module>
<file>book.inc</file>
<class_name>IslandoraBook</class_name>
<method_name>handleEditMetadataForm</method_name>
</submit_form_method>
</edit_metadata>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion CREATED="2010-09-16T17:43:54.445Z" ID="ISLANDORACM.5"
LABEL="Islandora content model information" MIMETYPE="text/xml" SIZE="1285">
<foxml:xmlContent>
<content_model name="Book" xmlns="http://www.islandora.ca" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.islandora.ca http://localhost/islandoracm.xsd">
<mimetypes>
<type>text/xml</type>
</mimetypes>
<ingest_rules>
<rule>
<applies_to>text/xml</applies_to>
<ingest_methods>
<ingest_method class="IslandoraBook" dsid="MODS" file="book.inc" method="ingestBook"
modified_files_ext="" module="fedora_ilives"/>
</ingest_methods>
</rule>
</ingest_rules>
<datastreams>
<datastream dsid="MODS">
<display_method class="IslandoraBook" file="book.inc" method="showFieldSets" module="fedora_ilives"/>
</datastream>
<datastream dsid="TN"/>
<datastream dsid="DC"/>
</datastreams>
<ingest_form dsid="MODS" page="2">
<form_builder_method class="IslandoraBook" file="book.inc" handler="handleIngestForm"
method="buildDrupalForm" module="fedora_ilives"/>
<form_elements/>
</ingest_form>
<edit_metadata_method class="IslandoraBook" dsid="MODS" file="book.inc" handler="handleEditMetadataForm"
method="buildEditMetadataForm" module="fedora_ilives"/>
</content_model>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

56
ilives/xml/ilives_collection.xml

@ -1,56 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject VERSION="1.1" PID="ilives:collection"
xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="IslandLives Collection"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-14T19:32:21.132Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-05-14T19:35:11.912Z"/>
</foxml:objectProperties>
<foxml:datastream ID="AUDIT" STATE="A" CONTROL_GROUP="X" VERSIONABLE="false">
<foxml:datastreamVersion ID="AUDIT.0" LABEL="Audit Trail for this object" CREATED="2009-05-14T19:32:21.132Z" MIMETYPE="text/xml" FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID></audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-05-14T19:32:21.132Z</audit:date>
<audit:justification>Created with Admin GUI &quot;New Object&quot; command</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>DC</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-05-14T19:35:11.912Z</audit:date>
<audit:justification></audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream ID="DC" STATE="A" CONTROL_GROUP="X" VERSIONABLE="true">
<foxml:datastreamVersion ID="DC1.0" LABEL="Dublin Core Record for this object" CREATED="2009-05-14T19:32:21.132Z" MIMETYPE="text/xml" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/" SIZE="392">
<foxml:xmlContent>
<oai_dc:dc xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>IslandLives Collection</dc:title>
<dc:identifier>ilives:collection</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
<foxml:datastreamVersion ID="DC.1" LABEL="Dublin Core Record for this object" CREATED="2009-05-14T19:35:11.912Z" MIMETYPE="text/xml" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/" SIZE="783">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>IslandLives Collection</dc:title>
<dc:description>Made possible through a generous private donation, IslandLives contains community and church histories and it builds on the Robertson Library&apos;s mission to preserve and share unique material relating to Prince Edward Island and demonstrates UPEI&quot;s ongoing commitment to making PEI&quot;s cultural and published heritage available to all. Welcome.</dc:description>
<dc:identifier>ilives:collection</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

20
ilives/xml/ilives_figuresCModel.xml

@ -1,20 +0,0 @@
<content_model name="standard_jpeg">
<mimetypes>
<type>image/jpeg</type>
</mimetypes>
<display_in_fieldset>
<datastream id="JPG">
<method>
<module>fedora_ilives</module>
<file>image_rotator_tagger_block.inc</file>
<class_name>ShowILivesStreamsInFieldSets</class_name>
<method_name>showJPG</method_name>
</method>
</datastream>
<datastream id="JPG">
<allowed_mime_type>image/jpeg</allowed_mime_type>
</datastream>
</display_in_fieldset>
<ingest_rules></ingest_rules>
</content_model>

81
ilives/xml/ilives_jp2Sdef.xml

@ -1,81 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:jp2Sdef" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:jp2Sdef"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-18T15:07:42.398Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2010-06-01T01:40:47.337Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:56:59.840Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_jp2Sdef.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>admin</audit:responsibility>
<audit:date>2010-05-25T13:17:14.106Z</audit:date>
<audit:justification>Fedora Object Ingested</audit:justification>
</audit:record>
<audit:record ID="AUDREC3">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-01T01:40:47.337Z</audit:date>
<audit:justification>Ingested from local file /Users/al/fedora_repository/content_models/ilives_jp2Sdef.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.487Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT1.0" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="363">
<foxml:xmlContent>
<rdf:RDF xmlns:fedora-model="info:fedora/fedora-system:def/model#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:jp2Sdef">
<fedora-model:hasModel rdf:resource="info:fedora/fedora-system:ServiceDefinition-3.0"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="381">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:jp2Sdef</dc:title>
<dc:identifier>ilives:jp2Sdef</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T20:08:16.294Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDefMethodMap-1.0" ID="METHODMAP.3" LABEL="Abstract Method Map"
MIMETYPE="text/xml" SIZE="245">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="getMetadata"/>
<fmm:Method operationName="getRegion"/>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

179
ilives/xml/ilives_jp2Sdep-pageCModel.xml

@ -1,179 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:jp2Sdep-pageCModel" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:jp2Sdep-pageCModel"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-21T03:24:05.906Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2010-06-01T00:48:39.302Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:57:00.246Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_jp2Sdep-pageCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-01T00:46:19.239Z</audit:date>
<audit:justification>Ingested from local file /Users/al/Desktop/ilives_jp2Sdep-pageCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC3">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>RELS-EXT</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2010-06-01T00:48:39.302Z</audit:date>
<audit:justification/>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="true">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="403">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:jp2Sdep-pageCModel</dc:title>
<dc:identifier>ilives:jp2Sdep-pageCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:26:21.830Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDepMethodMap-1.1" ID="METHODMAP.1" LABEL="Deployment Method Map"
MIMETYPE="text/xml" SIZE="2498">
<foxml:xmlContent>
<fmm:MethodMap bDefPID="djatoka:bDef" name="MethodMap - djatoka Service Methods" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="getMetadata" wsdlMsgName="getMetadataRequest" wsdlMsgOutput="response">
<fmm:DefaultInputParm defaultValue="$PID" label="fedora object pid" parmName="PID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="JP2" label="content model" parmName="DSID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="info:lanl-repo/svc/getMetadata" parmName="svc_id" passBy="VALUE" required="true"/>
<fmm:UserInputParm defaultValue="" parmName="uid" passBy="VALUE" required="false"/>
<fmm:MethodReturnType wsdlMsgName="response" wsdlMsgTOMIME="application/json"/>
</fmm:Method>
<fmm:Method operationName="getRegion" wsdlMsgName="getRegionRequest" wsdlMsgOutput="response">
<fmm:DefaultInputParm defaultValue="$PID" label="fedora object pid" parmName="PID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="JP2" label="content model" parmName="DSID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="info:lanl-repo/svc/getRegion" parmName="svc_id" passBy="VALUE" required="true"/>
<fmm:UserInputParm defaultValue="" parmName="uid" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="" parmName="region" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="0" parmName="rotate" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="-1" parmName="level" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="" parmName="scale" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="" parmName="clayers" passBy="VALUE" required="false"/>
<fmm:UserInputParm defaultValue="image/jpeg" parmName="format" passBy="VALUE" required="false"/>
<fmm:MethodReturnType wsdlMsgName="response" wsdlMsgTOMIME="image/jpeg"/>
</fmm:Method>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DSINPUTSPEC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:26:44.151Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSInputSpec-1.1" ID="DSINPUTSPEC.1"
LABEL="Datastream Input Specification" MIMETYPE="text/xml" SIZE="401">
<foxml:xmlContent>
<fbs:DSInputSpec label="jp2SdepInputSpec" xmlns:fbs="http://fedora.comm.nsdlib.org/service/bindspec">
<fbs:DSInput DSMax="1" DSMin="1" DSOrdinality="false" wsdlMsgPartName="DC">
<fbs:DSInputLabel>DC</fbs:DSInputLabel>
<fbs:DSMIME>text/xml</fbs:DSMIME>
<fbs:DSInputInstruction/>
</fbs:DSInput>
</fbs:DSInputSpec>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="WSDL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:27:46.103Z" FORMAT_URI="http://schemas.xmlsoap.org/wsdl/"
ID="WSDL.1" LABEL="WSDL Bindings" MIMETYPE="text/xml" SIZE="3258">
<foxml:xmlContent>
<wsdl:definitions name="Fedora Local Djatoka Service" targetNamespace="jp2SDep"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap"
xmlns:soapenc="http://schemas.xmlsoap.org/wsdl/soap/encoding" xmlns:this="djatoka"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:message name="getMetadataRequest">
<wsdl:part name="PID" type="xsd:string"/>
<wsdl:part name="DSID" type="xsd:string"/>
<wsdl:part name="svc_id" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="getRegionRequest">
<wsdl:part name="PID" type="xsd:string"/>
<wsdl:part name="DSID" type="xsd:string"/>
<wsdl:part name="svc_id" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="response">
<wsdl:part name="exhibit" type="xsd:base64Binary"/>
</wsdl:message>
<wsdl:portType name="FedoraDjatokaPortType">
<wsdl:operation name="getMetadata">
<wsdl:input message="this:getMetadataRequest"/>
<wsdl:output message="this:response"/>
</wsdl:operation>
<wsdl:operation name="getRegion">
<wsdl:input message="this:getRegionRequest"/>
<wsdl:output message="this:response"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:service name="FedoraDjatoka">
<wsdl:port binding="this:FedoraDjatoka_http" name="FedoraDjatoka_port">
<http:address location="http://local.fedora.server/"/>
</wsdl:port>
</wsdl:service>
<wsdl:binding name="FedoraDjatoka_http" type="this:FedoraDjatokaPortType">
<http:binding verb="GET"/>
<wsdl:operation name="getMetadata">
<http:operation location="adore-djatoka/resolver?url_ver=Z39.88-2004&amp;rft_id=http://local.fedora.server/fedora/get/(PID)/(DSID)&amp;svc_id=(svc_id)"/>
<wsdl:input>
<http:urlReplacement/>
</wsdl:input>
<wsdl:output>
<mime:content type="application/json"/>
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="getRegion">
<http:operation location="adore-djatoka/resolver?url_ver=Z39.88-2004&amp;rft_id=http://local.fedora.server/fedora/get/(PID)/(DSID)&amp;svc_id=(svc_id)&amp;svc_val_fmt=info:ofi/fmt:kev:mtx:jpeg2000&amp;svc.format=(format)&amp;svc.level=(level)&amp;svc.rotate=(rotate)&amp;svc.region=(region)&amp;svc.scale=(scale)&amp;svc.clayers=(clayers)"/>
<wsdl:input>
<http:urlReplacement/>
</wsdl:input>
<wsdl:output>
<mime:content type="image/jpeg"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
</wsdl:definitions>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2010-06-01T00:48:39.302Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.2" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="688">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:jp2Sdep-pageCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ServiceDeployment-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<isDeploymentOf rdf:resource="info:fedora/ilives:jp2Sdef" xmlns="info:fedora/fedora-system:def/model#"/>
<isContractorOf rdf:resource="info:fedora/ilives:pageCModel" xmlns="info:fedora/fedora-system:def/model#"/>
<isContractorOf rdf:resource="info:fedora/newspapers:pageCModel" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

101
ilives/xml/ilives_pageCModel.xml

@ -1,101 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:pageCModel" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="Page Content Model"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-02-11T19:36:02.739Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-11-12T14:57:00.652Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-02-11T19:36:02.739Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:57:00.652Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_pageCModel.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:21:13.054Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.3" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="705">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:pageCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ContentModel-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<hasService rdf:resource="info:fedora/ilives:viewerSdef" xmlns="info:fedora/fedora-system:def/model#"/>
<hasService rdf:resource="info:fedora/ilives:jp2Sdef" xmlns="info:fedora/fedora-system:def/model#"/>
<hasService rdf:resource="info:fedora/ilives:tei2htmlSdef" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DS-COMPOSITE-MODEL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-02-11T19:56:48.895Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSCompositeModel-1.0" ID="DS-COMPOSITE-MODEL.2"
LABEL="Datastream Composite Model" MIMETYPE="text/xml" SIZE="1738">
<foxml:xmlContent>
<dsCompositeModel xmlns="info:fedora/fedora-system:def/dsCompositeModel#">
<comment xmlns="info:fedora/fedora-system:def/comment#">
This DS-COMPOSITE-MODEL datastream is included as a starting point to
assist in the creation of a content model. The DS-COMPOSITE-MODEL
should define the datastreams that are required for any objects
conforming to this content model.
For more information about content models, see:
http://fedora-commons.org/confluence/x/dgBI.
For examples of completed content model objects, see the demonstration
objects included with your Fedora distribution, such as:
demo:CMImage, demo:UVA_STD_IMAGE, demo:DualResImageCollection,
demo:TEI_TO_PDFDOC, and demo:XML_TO_HTMLDOC.
For more information about the demonstration objects, see:
http://fedora-commons.org/confluence/x/AwFI.
</comment>
<dsTypeModel ID="DSID">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="MIX">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="MODS">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="PAGE_OCR">
<form MIME="text/plain"/>
</dsTypeModel>
<dsTypeModel ID="PAGE_TEI">
<form MIME="text/xml"/>
</dsTypeModel>
<dsTypeModel ID="JPG">
<form MIME="image/JPG"/>
</dsTypeModel>
<dsTypeModel ID="wordsXY">
<form MIME="text/xml"/>
</dsTypeModel>
</dsCompositeModel>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-02-11T19:36:02.739Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="388">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>Page Content Model</dc:title>
<dc:identifier>ilives:pageCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

64
ilives/xml/ilives_tei2htmlSdef.xml

@ -1,64 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:tei2htmlSdef" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:tei2htmlSdef"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-18T15:07:42.398Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-11-12T14:57:01.057Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:57:01.057Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_tei2htmlSdef.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.487Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT1.0" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="368">
<foxml:xmlContent>
<rdf:RDF xmlns:fedora-model="info:fedora/fedora-system:def/model#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:tei2htmlSdef">
<fedora-model:hasModel rdf:resource="info:fedora/fedora-system:ServiceDefinition-3.0"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="391">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:tei2htmlSdef</dc:title>
<dc:identifier>ilives:tei2htmlSdef</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T20:08:16.294Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDefMethodMap-1.0" ID="METHODMAP.3" LABEL="Abstract Method Map"
MIMETYPE="text/xml" SIZE="180">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="tei2html"/>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

233
ilives/xml/ilives_tei2htmlSdep-pageCModel.xml

@ -1,233 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:tei2htmlSdep-pageCModel" VERSION="1.1"
xmlns:foxml="info:fedora/fedora-system:def/foxml#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:tei2htmlSdep-pageCModel"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-21T03:24:05.906Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-12-11T19:22:11.096Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T14:57:01.366Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_tei2htmlSdep-pageCModel.xml</audit:justification>
</audit:record>
<audit:record ID="AUDREC2">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>XSL</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-12-11T19:09:52.417Z</audit:date>
<audit:justification/>
</audit:record>
<audit:record ID="AUDREC3">
<audit:process type="Fedora API-M"/>
<audit:action>modifyDatastreamByValue</audit:action>
<audit:componentID>XSL</audit:componentID>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-12-11T19:22:11.096Z</audit:date>
<audit:justification/>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:25:04.961Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.1" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="614">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:tei2htmlSdep-pageCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ServiceDeployment-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<isDeploymentOf rdf:resource="info:fedora/ilives:tei2htmlSdef" xmlns="info:fedora/fedora-system:def/model#"/>
<isContractorOf rdf:resource="info:fedora/ilives:pageCModel" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="true">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="413">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:tei2htmlSdep-pageCModel</dc:title>
<dc:identifier>ilives:tei2htmlSdep-pageCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DSINPUTSPEC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-09-17T02:47:11.226Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSInputSpec-1.1" ID="DSINPUTSPEC.3"
LABEL="Datastream Input Specification" MIMETYPE="text/xml" SIZE="718">
<foxml:xmlContent>
<fbs:DSInputSpec label="tei2htmlSdepInputSpec" xmlns:fbs="http://fedora.comm.nsdlib.org/service/bindspec">
<fbs:DSInput DSMax="1" DSMin="1" DSOrdinality="false" wsdlMsgPartName="TEI">
<fbs:DSInputLabel>TEI</fbs:DSInputLabel>
<fbs:DSMIME>text/xml</fbs:DSMIME>
<fbs:DSInputInstruction/>
</fbs:DSInput>
<fbs:DSInput DSMax="1" DSMin="1" DSOrdinality="false" pid="ilives:tei2htmlSdep-pageCModel" wsdlMsgPartName="XSL">
<fbs:DSInputLabel>XSL</fbs:DSInputLabel>
<fbs:DSMIME>text/xml</fbs:DSMIME>
<fbs:DSInputInstruction/>
</fbs:DSInput>
</fbs:DSInputSpec>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="WSDL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-09-17T02:47:56.422Z" FORMAT_URI="http://schemas.xmlsoap.org/wsdl/"
ID="WSDL.3" LABEL="WSDL Bindings" MIMETYPE="text/xml" SIZE="1938">
<foxml:xmlContent>
<wsdl:definitions name="tei2htmlSdep" targetNamespace="tei2htmlSdep"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap"
xmlns:soapenc="http://schemas.xmlsoap.org/wsdl/soap/encoding" xmlns:this="tei2htmlSdep"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:message name="tei2htmlRequestMsg">
<wsdl:part name="TEI" type="xsd:string"/>
<wsdl:part name="XSL" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="response">
<wsdl:part name="exhibit" type="xsd:base64Binary"/>
</wsdl:message>
<wsdl:portType name="tei2html_portType">
<wsdl:operation name="tei2html">
<wsdl:input message="this:tei2htmlRequestMsg"/>
<wsdl:output message="this:response"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:service name="tei2html_service">
<wsdl:port binding="this:tei2html_binding" name="tei2html_port">
<http:address location="http://local.fedora.server/saxon/"/>
</wsdl:port>
</wsdl:service>
<wsdl:binding name="tei2html_binding" type="this:tei2html_portType">
<http:binding verb="GET"/>
<wsdl:operation name="tei2html">
<http:operation location="SaxonServlet?source=(TEI)&amp;style=(XSL)&amp;clear-stylesheet-cache=yes"/>
<wsdl:input>
<http:urlReplacement/>
</wsdl:input>
<wsdl:output>
<mime:content type="text/html"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
</wsdl:definitions>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-09-17T02:51:06.102Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDepMethodMap-1.1" ID="METHODMAP.6" LABEL="Deployment Method Map"
MIMETYPE="text/xml" SIZE="695">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="tei2html" wsdlMsgName="tei2htmlRequestMsg" wsdlMsgOutput="response">
<fmm:DatastreamInputParm parmName="TEI" passBy="URL_REF" required="true"/>
<fmm:DatastreamInputParm parmName="XSL" passBy="URL_REF" required="true"/>
<fmm:UserInputParm defaultValue="" parmName="uid" passBy="VALUE" required="false"/>
<fmm:MethodReturnType wsdlMsgName="response" wsdlMsgTOMIME="text/html"/>
</fmm:Method>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="XSL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-12-11T19:22:11.096Z" ID="XSL.2"
LABEL="XSL stylesheet for tei2html conversion" MIMETYPE="text/xml" SIZE="2902">
<foxml:xmlContent>
<xsl:stylesheet exclude-result-prefixes="tei" version="2.0" xmlns:tei="http://www.tei-c.org/ns/1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output doctype-public="-//W3C//DTD HTML 4.01 Strict//EN"
doctype-system="http://www.w3.org/TR/html4/strict.dtd" indent="yes" method="html" omit-xml-declaration="yes"/>
<xsl:template match="tei:TEI">
<html>
<head>
<title>
<xsl:value-of select="normalize-space(tei:teiHeader/tei:fileDesc/tei:titleStmt/tei:title)"/>
</title>
</head>
<body>
<xsl:apply-templates/>
</body>
</html>
</xsl:template>
<xsl:template match="tei:body">
<div class="tei">
<xsl:apply-templates/>
</div>
</xsl:template>
<xsl:template match="tei:p">
<p>
<xsl:apply-templates/>
</p>
</xsl:template>
<xsl:template match="tei:date">
<span class="date">
<xsl:value-of select="normalize-space(.)"/>
</span>
</xsl:template>
<xsl:template match="tei:persName">
<xsl:choose>
<xsl:when test="(.//tei:surname) and (.//tei:forename)">
<span class="persName">
<a>
<xsl:attribute name="class">search persName</xsl:attribute>
<xsl:attribute name="target">_blank</xsl:attribute>
<xsl:attribute
name="href">http://islandlives.net/fedora/ilives_book_search/tei.persNameTERM:%22
<xsl:value-of
select=".//tei:surname"/>+
<xsl:value-of select=".//tei:forename"/>%22+AND+dc.type:collection
</xsl:attribute>
<xsl:apply-templates select="*|node()"/>
</a>
</span>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="*|node()"/>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="tei:placeName">
<a>
<xsl:attribute name="class">search placeName</xsl:attribute>
<xsl:attribute name="target">_blank</xsl:attribute>
<xsl:attribute
name="href">http://islandlives.net/fedora/ilives_book_search/tei.placeNameTERM:%22
<xsl:value-of select="normalize-space(.)"/>%22+AND+dc.type:collection
</xsl:attribute>
<xsl:value-of select="normalize-space(.)"/>
</a>
</xsl:template>
<xsl:template match="tei:orgName">
<a>
<xsl:attribute name="class">search orgName</xsl:attribute>
<xsl:attribute name="target">_blank</xsl:attribute>
<xsl:attribute
name="href">http://islandlives.net/fedora/ilives_book_search/tei.orgNameTERM:%22
<xsl:value-of select="normalize-space(.)"/>%22+AND+dc.type:collection
</xsl:attribute>
<xsl:value-of select="normalize-space(.)"/>
</a>
</xsl:template>
<xsl:template match="tei:teiHeader"/>
</xsl:stylesheet>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

64
ilives/xml/ilives_viewerSdef.xml

@ -1,64 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:viewerSdef" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:viewerSdef"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-18T15:07:42.398Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-11-12T17:09:29.912Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T17:09:29.912Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_viewerSdef.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.487Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT1.0" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="366">
<foxml:xmlContent>
<rdf:RDF xmlns:fedora-model="info:fedora/fedora-system:def/model#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:viewerSdef">
<fedora-model:hasModel rdf:resource="info:fedora/fedora-system:ServiceDefinition-3.0"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T15:07:42.398Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="387">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:viewerSdef</dc:title>
<dc:identifier>ilives:viewerSdef</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T20:08:16.294Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDefMethodMap-1.0" ID="METHODMAP.3" LABEL="Abstract Method Map"
MIMETYPE="text/xml" SIZE="181">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="getViewer"/>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

133
ilives/xml/ilives_viewerSdep-bookCModel.xml

@ -1,133 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:viewerSdep-bookCModel" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:viewerSdep-bookCModel"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-18T19:50:00.488Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-11-12T17:09:41.797Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T19:50:00.488Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-12T17:09:41.797Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_viewerSdep-bookCModel.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="true">
<foxml:datastreamVersion CREATED="2009-05-18T19:50:00.488Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="409">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:viewerSdep-bookCModel</dc:title>
<dc:identifier>ilives:viewerSdep-bookCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T19:50:37.927Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.1" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="610">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:viewerSdep-bookCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ServiceDeployment-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<isDeploymentOf rdf:resource="info:fedora/ilives:viewerSdef" xmlns="info:fedora/fedora-system:def/model#"/>
<isContractorOf rdf:resource="info:fedora/ilives:bookCModel" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DSINPUTSPEC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-18T19:52:55.042Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSInputSpec-1.1" ID="DSINPUTSPEC.1"
LABEL="Datastream Input Specification" MIMETYPE="text/xml" SIZE="404">
<foxml:xmlContent>
<fbs:DSInputSpec label="viewerSdepInputSpec" xmlns:fbs="http://fedora.comm.nsdlib.org/service/bindspec">
<fbs:DSInput DSMax="1" DSMin="1" DSOrdinality="false" wsdlMsgPartName="DC">
<fbs:DSInputLabel>DC</fbs:DSInputLabel>
<fbs:DSMIME>text/xml</fbs:DSMIME>
<fbs:DSInputInstruction/>
</fbs:DSInput>
</fbs:DSInputSpec>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-19T13:34:53.687Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDepMethodMap-1.1" ID="METHODMAP.2" LABEL="Deployment Method Map"
MIMETYPE="text/xml" SIZE="955">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="getViewer" wsdlMsgName="getViewerRequestMsg" wsdlMsgOutput="getViewerResponseMsg">
<fmm:DefaultInputParm defaultValue="$PID" label="fedora object pid" parmName="PID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="ilives:bookCModel" label="content model" parmName="CMODEL"
passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="JP2" label="content model" parmName="DSID" passBy="VALUE" required="true"/>
<fmm:UserInputParm defaultValue="" parmName="uid" passBy="VALUE" required="false"/>
<fmm:MethodReturnType wsdlMsgName="getViewerResponseMsg" wsdlMsgTOMIME="text/html"/>
</fmm:Method>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="WSDL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-19T13:34:20.768Z" FORMAT_URI="http://schemas.xmlsoap.org/wsdl/"
ID="WSDL.4" LABEL="WSDL Bindings" MIMETYPE="text/xml" SIZE="2073">
<foxml:xmlContent>
<wsdl:definitions name="viewerSdep" targetNamespace="viewerSdep"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap"
xmlns:soapenc="http://schemas.xmlsoap.org/wsdl/soap/encoding" xmlns:this="viewerSdep"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:message name="getViewerRequestMsg">
<wsdl:part name="PID" type="xsd:string"/>
<wsdl:part name="CMODEL" type="xsd:string"/>
<wsdl:part name="DSID" type="xsd:string"/>
<wsdl:part name="uid" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="getViewerResponseMsg">
<wsdl:part name="RESPONSE" type="xsd:string"/>
</wsdl:message>
<wsdl:portType name="viewer_portType">
<wsdl:operation name="getViewer">
<wsdl:input message="this:getViewerRequestMsg"/>
<wsdl:output message="this:getViewerResponseMsg"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:service name="viewer_service">
<wsdl:port binding="this:viewer_binding" name="viewer_port">
<http:address location="http://local.fedora.server/iiv/viewer.jsp"/>
</wsdl:port>
</wsdl:service>
<wsdl:binding name="viewer_binding" type="this:viewer_portType">
<http:binding verb="GET"/>
<wsdl:operation name="getViewer">
<http:operation location="?pid=(PID)&amp;cmodel=(CMODEL)&amp;dsid=(DSID)&amp;uid=(uid)"/>
<wsdl:input>
<http:urlReplacement/>
</wsdl:input>
<wsdl:output>
<mime:content type="text/html"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
</wsdl:definitions>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

133
ilives/xml/ilives_viewerSdep-pageCModel.xml

@ -1,133 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<foxml:digitalObject PID="ilives:viewerSdep-pageCModel" VERSION="1.1" xmlns:foxml="info:fedora/fedora-system:def/foxml#"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="info:fedora/fedora-system:def/foxml# http://www.fedora.info/definitions/1/0/foxml1-1.xsd">
<foxml:objectProperties>
<foxml:property NAME="info:fedora/fedora-system:def/model#state" VALUE="Active"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#label" VALUE="ilives:viewerSdep-pageCModel"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#ownerId" VALUE="fedoraAdmin"/>
<foxml:property NAME="info:fedora/fedora-system:def/model#createdDate" VALUE="2009-05-21T03:24:05.906Z"/>
<foxml:property NAME="info:fedora/fedora-system:def/view#lastModifiedDate" VALUE="2009-11-24T14:52:27.296Z"/>
</foxml:objectProperties>
<foxml:datastream CONTROL_GROUP="X" ID="AUDIT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z"
FORMAT_URI="info:fedora/fedora-system:format/xml.fedora.audit" ID="AUDIT.0" LABEL="Audit Trail for this object" MIMETYPE="text/xml">
<foxml:xmlContent>
<audit:auditTrail xmlns:audit="info:fedora/fedora-system:def/audit#">
<audit:record ID="AUDREC1">
<audit:process type="Fedora API-M"/>
<audit:action>ingest</audit:action>
<audit:componentID/>
<audit:responsibility>fedoraAdmin</audit:responsibility>
<audit:date>2009-11-24T14:52:27.296Z</audit:date>
<audit:justification>Ingested from local file /Users/aoneill/dev/iiv/iiv/etc/fedora-objects/ilives_viewerSdep-pageCModel.xml</audit:justification>
</audit:record>
</audit:auditTrail>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="RELS-EXT" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:25:04.961Z" FORMAT_URI="info:fedora/fedora-system:FedoraRELSExt-1.0"
ID="RELS-EXT.1" LABEL="RDF Statements about this object" MIMETYPE="application/rdf+xml" SIZE="610">
<foxml:xmlContent>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about="info:fedora/ilives:viewerSdep-pageCModel">
<hasModel rdf:resource="info:fedora/fedora-system:ServiceDeployment-3.0" xmlns="info:fedora/fedora-system:def/model#"/>
<isDeploymentOf rdf:resource="info:fedora/ilives:viewerSdef" xmlns="info:fedora/fedora-system:def/model#"/>
<isContractorOf rdf:resource="info:fedora/ilives:pageCModel" xmlns="info:fedora/fedora-system:def/model#"/>
</rdf:Description>
</rdf:RDF>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DC" STATE="A" VERSIONABLE="true">
<foxml:datastreamVersion CREATED="2009-05-21T03:24:05.906Z" FORMAT_URI="http://www.openarchives.org/OAI/2.0/oai_dc/"
ID="DC1.0" LABEL="Dublin Core Record for this object" MIMETYPE="text/xml" SIZE="409">
<foxml:xmlContent>
<oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<dc:title>ilives:viewerSdep-pageCModel</dc:title>
<dc:identifier>ilives:viewerSdep-pageCModel</dc:identifier>
</oai_dc:dc>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="METHODMAP" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:26:21.830Z"
FORMAT_URI="info:fedora/fedora-system:FedoraSDepMethodMap-1.1" ID="METHODMAP.1" LABEL="Deployment Method Map"
MIMETYPE="text/xml" SIZE="955">
<foxml:xmlContent>
<fmm:MethodMap name="methodmap" xmlns:fmm="http://fedora.comm.nsdlib.org/service/methodmap">
<fmm:Method operationName="getViewer" wsdlMsgName="getViewerRequestMsg" wsdlMsgOutput="getViewerResponseMsg">
<fmm:DefaultInputParm defaultValue="$PID" label="fedora object pid" parmName="PID" passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="ilives:pageCModel" label="content model" parmName="CMODEL"
passBy="VALUE" required="true"/>
<fmm:DefaultInputParm defaultValue="JP2" label="content model" parmName="DSID" passBy="VALUE" required="true"/>
<fmm:UserInputParm defaultValue="" parmName="uid" passBy="VALUE" required="false"/>
<fmm:MethodReturnType wsdlMsgName="getViewerResponseMsg" wsdlMsgTOMIME="text/html"/>
</fmm:Method>
</fmm:MethodMap>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="DSINPUTSPEC" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:26:44.151Z"
FORMAT_URI="info:fedora/fedora-system:FedoraDSInputSpec-1.1" ID="DSINPUTSPEC.1"
LABEL="Datastream Input Specification" MIMETYPE="text/xml" SIZE="404">
<foxml:xmlContent>
<fbs:DSInputSpec label="viewerSdepInputSpec" xmlns:fbs="http://fedora.comm.nsdlib.org/service/bindspec">
<fbs:DSInput DSMax="1" DSMin="1" DSOrdinality="false" wsdlMsgPartName="DC">
<fbs:DSInputLabel>DC</fbs:DSInputLabel>
<fbs:DSMIME>text/xml</fbs:DSMIME>
<fbs:DSInputInstruction/>
</fbs:DSInput>
</fbs:DSInputSpec>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
<foxml:datastream CONTROL_GROUP="X" ID="WSDL" STATE="A" VERSIONABLE="false">
<foxml:datastreamVersion CREATED="2009-05-21T03:27:46.103Z" FORMAT_URI="http://schemas.xmlsoap.org/wsdl/"
ID="WSDL.1" LABEL="WSDL Bindings" MIMETYPE="text/xml" SIZE="2079">
<foxml:xmlContent>
<wsdl:definitions name="viewerSdep" targetNamespace="viewerSdep"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap"
xmlns:soapenc="http://schemas.xmlsoap.org/wsdl/soap/encoding" xmlns:this="viewerSdep"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:message name="getViewerRequestMsg">
<wsdl:part name="PID" type="xsd:string"/>
<wsdl:part name="CMODEL" type="xsd:string"/>
<wsdl:part name="DSID" type="xsd:string"/>
<wsdl:part name="uid" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="getViewerResponseMsg">
<wsdl:part name="RESPONSE" type="xsd:string"/>
</wsdl:message>
<wsdl:portType name="viewer_portType">
<wsdl:operation name="getViewer">
<wsdl:input message="this:getViewerRequestMsg"/>
<wsdl:output message="this:getViewerResponseMsg"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:service name="viewer_service">
<wsdl:port binding="this:viewer_binding" name="viewer_port">
<http:address location="http://local.fedora.server/iiv/page_viewer.jsp"/>
</wsdl:port>
</wsdl:service>
<wsdl:binding name="viewer_binding" type="this:viewer_portType">
<http:binding verb="GET"/>
<wsdl:operation name="getViewer">
<http:operation location="?pid=(PID)&amp;cmodel=(CMODEL)&amp;dsid=(DSID)&amp;uid=(uid)"/>
<wsdl:input>
<http:urlReplacement/>
</wsdl:input>
<wsdl:output>
<mime:content type="text/xhtml"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
</wsdl:definitions>
</foxml:xmlContent>
</foxml:datastreamVersion>
</foxml:datastream>
</foxml:digitalObject>

412
ilives/xsl/MODS3-22simpleDC.xsl

@ -1,412 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:mods="http://www.loc.gov/mods/v3" exclude-result-prefixes="mods"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:srw_dc="info:srw/schema/1/dc-schema"
xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<!--
This stylesheet transforms MODS version 3.2 records and collections of records to simple Dublin Core (DC) records,
based on the Library of Congress' MODS to simple DC mapping <http://www.loc.gov/standards/mods/mods-dcsimple.html>
The stylesheet will transform a collection of MODS 3.2 records into simple Dublin Core (DC)
as expressed by the SRU DC schema <http://www.loc.gov/standards/sru/dc-schema.xsd>
The stylesheet will transform a single MODS 3.2 record into simple Dublin Core (DC)
as expressed by the OAI DC schema <http://www.openarchives.org/OAI/2.0/oai_dc.xsd>
Because MODS is more granular than DC, transforming a given MODS element or subelement to a DC element frequently results in less precise tagging,
and local customizations of the stylesheet may be necessary to achieve desired results.
This stylesheet makes the following decisions in its interpretation of the MODS to simple DC mapping:
When the roleTerm value associated with a name is creator, then name maps to dc:creator
When there is no roleTerm value associated with name, or the roleTerm value associated with name is a value other than creator, then name maps to dc:contributor
Start and end dates are presented as span dates in dc:date and in dc:coverage
When the first subelement in a subject wrapper is topic, subject subelements are strung together in dc:subject with hyphens separating them
Some subject subelements, i.e., geographic, temporal, hierarchicalGeographic, and cartographics, are also parsed into dc:coverage
The subject subelement geographicCode is dropped in the transform
Revision 1.1 2007-05-18 <tmee@loc.gov>
Added modsCollection conversion to DC SRU
Updated introductory documentation
Version 1.0 2007-05-04 Tracy Meehleib <tmee@loc.gov>
-->
<xsl:output method="xml" indent="yes"/>
<xsl:template match="/">
<xsl:choose>
<xsl:when test="//mods:modsCollection">
<srw_dc:dcCollection xsi:schemaLocation="info:srw/schema/1/dc-schema http://www.loc.gov/standards/sru/dc-schema.xsd">
<xsl:apply-templates/>
<xsl:for-each select="mods:modsCollection/mods:mods">
<srw_dc:dc xsi:schemaLocation="info:srw/schema/1/dc-schema http://www.loc.gov/standards/sru/dc-schema.xsd">
<xsl:apply-templates/>
</srw_dc:dc>
</xsl:for-each>
</srw_dc:dcCollection>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="mods:mods">
<oai_dc:dc xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
<xsl:apply-templates/>
</oai_dc:dc>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="mods:titleInfo">
<dc:title>
<xsl:value-of select="mods:nonSort"/>
<xsl:if test="mods:nonSort">
<xsl:text> </xsl:text>
</xsl:if>
<xsl:value-of select="mods:title"/>
<xsl:if test="mods:subTitle">
<xsl:text>: </xsl:text>
<xsl:value-of select="mods:subTitle"/>
</xsl:if>
<xsl:if test="mods:partNumber">
<xsl:text>. </xsl:text>
<xsl:value-of select="mods:partNumber"/>
</xsl:if>
<xsl:if test="mods:partName">
<xsl:text>. </xsl:text>
<xsl:value-of select="mods:partName"/>
</xsl:if>
</dc:title>
</xsl:template>
<xsl:template match="mods:name">
<xsl:choose>
<xsl:when
test="mods:role/mods:roleTerm[@type='text']='creator' or mods:role/mods:roleTerm[@type='code']='cre' ">
<dc:creator>
<xsl:call-template name="name"/>
</dc:creator>
</xsl:when>
<xsl:otherwise>
<dc:contributor>
<xsl:call-template name="name"/>
</dc:contributor>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="mods:classification">
<dc:subject>
<xsl:value-of select="."/>
</dc:subject>
</xsl:template>
<xsl:template match="mods:subject[mods:topic | mods:name | mods:occupation | mods:geographic | mods:hierarchicalGeographic | mods:cartographics | mods:temporal] ">
<dc:subject>
<xsl:for-each select="mods:topic">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:for-each>
<xsl:for-each select="mods:occupation">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:for-each>
<xsl:for-each select="mods:name">
<xsl:call-template name="name"/>
</xsl:for-each>
</dc:subject>
<xsl:for-each select="mods:titleInfo/mods:title">
<dc:subject>
<xsl:value-of select="mods:titleInfo/mods:title"/>
</dc:subject>
</xsl:for-each>
<xsl:for-each select="mods:geographic">
<dc:coverage>
<xsl:value-of select="."/>
</dc:coverage>
</xsl:for-each>
<xsl:for-each select="mods:hierarchicalGeographic">
<dc:coverage>
<xsl:for-each
select="mods:continent|mods:country|mods:provence|mods:region|mods:state|mods:territory|mods:county|mods:city|mods:island|mods:area">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:for-each>
</dc:coverage>
</xsl:for-each>
<xsl:for-each select="mods:cartographics/*">
<dc:coverage>
<xsl:value-of select="."/>
</dc:coverage>
</xsl:for-each>
<xsl:if test="mods:temporal">
<dc:coverage>
<xsl:for-each select="mods:temporal">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">-</xsl:if>
</xsl:for-each>
</dc:coverage>
</xsl:if>
<xsl:if test="*[1][local-name()='topic'] and *[local-name()!='topic']">
<dc:subject>
<xsl:for-each select="*[local-name()!='cartographics' and local-name()!='geographicCode' and local-name()!='hierarchicalGeographic'] ">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:for-each>
</dc:subject>
</xsl:if>
</xsl:template>
<xsl:template match="mods:abstract | mods:tableOfContents | mods:note">
<dc:description>
<xsl:value-of select="."/>
</dc:description>
</xsl:template>
<xsl:template match="mods:originInfo">
<xsl:apply-templates select="*[@point='start']"/>
<xsl:for-each
select="mods:dateIssued[@point!='start' and @point!='end'] |mods:dateCreated[@point!='start' and @point!='end'] | mods:dateCaptured[@point!='start' and @point!='end'] | mods:dateOther[@point!='start' and @point!='end']">
<dc:date>
<xsl:value-of select="."/>
</dc:date>
</xsl:for-each>
<xsl:for-each select="mods:publisher">
<dc:publisher>
<xsl:value-of select="."/>
</dc:publisher>
</xsl:for-each>
</xsl:template>
<xsl:template match="mods:dateIssued | mods:dateCreated | mods:dateCaptured">
<dc:date>
<xsl:choose>
<xsl:when test="@point='start'">
<xsl:value-of select="."/>
<xsl:text> - </xsl:text>
</xsl:when>
<xsl:when test="@point='end'">
<xsl:value-of select="."/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="."/>
</xsl:otherwise>
</xsl:choose>
</dc:date>
</xsl:template>
<xsl:template match="mods:genre">
<xsl:choose>
<xsl:when test="@authority='dct'">
<dc:type>
<xsl:value-of select="."/>
</dc:type>
<xsl:for-each select="mods:typeOfResource">
<dc:type>
<xsl:value-of select="."/>
</dc:type>
</xsl:for-each>
</xsl:when>
<xsl:otherwise>
<dc:type>
<xsl:value-of select="."/>
</dc:type>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="mods:typeOfResource">
<xsl:if test="@collection='yes'">
<dc:type>Collection</dc:type>
</xsl:if>
<xsl:if test=". ='software' and ../mods:genre='database'">
<dc:type>DataSet</dc:type>
</xsl:if>
<xsl:if test=".='software' and ../mods:genre='online system or service'">
<dc:type>Service</dc:type>
</xsl:if>
<xsl:if test=".='software'">
<dc:type>Software</dc:type>
</xsl:if>
<xsl:if test=".='cartographic material'">
<dc:type>Image</dc:type>
</xsl:if>
<xsl:if test=".='multimedia'">
<dc:type>InteractiveResource</dc:type>
</xsl:if>
<xsl:if test=".='moving image'">
<dc:type>MovingImage</dc:type>
</xsl:if>
<xsl:if test=".='three-dimensional object'">
<dc:type>PhysicalObject</dc:type>
</xsl:if>
<xsl:if test="starts-with(.,'sound recording')">
<dc:type>Sound</dc:type>
</xsl:if>
<xsl:if test=".='still image'">
<dc:type>StillImage</dc:type>
</xsl:if>
<xsl:if test=". ='text'">
<dc:type>Text</dc:type>
</xsl:if>
<xsl:if test=".='notated music'">
<dc:type>Text</dc:type>
</xsl:if>
</xsl:template>
<xsl:template match="mods:physicalDescription">
<xsl:if test="mods:extent">
<dc:format>
<xsl:value-of select="mods:extent"/>
</dc:format>
</xsl:if>
<xsl:if test="mods:form">
<dc:format>
<xsl:value-of select="mods:form"/>
</dc:format>
</xsl:if>
<xsl:if test="mods:internetMediaType">
<dc:format>
<xsl:value-of select="mods:internetMediaType"/>
</dc:format>
</xsl:if>
</xsl:template>
<xsl:template match="mods:mimeType">
<dc:format>
<xsl:value-of select="."/>
</dc:format>
</xsl:template>
<xsl:template match="mods:identifier">
<xsl:variable name="type" select="translate(@type,'ABCDEFGHIJKLMNOPQRSTUVWXYZ','abcdefghijklmnopqrstuvwxyz')"/>
<xsl:choose>
<xsl:when test="contains ('isbn issn uri doi lccn uri', $type)">
<dc:identifier>
<xsl:value-of select="$type"/>: 
<xsl:value-of select="."/>
</dc:identifier>
</xsl:when>
<xsl:otherwise>
<dc:identifier>
<xsl:value-of select="."/>
</dc:identifier>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="mods:location">
<dc:identifier>
<xsl:for-each select="mods:url">
<xsl:value-of select="."/>
</xsl:for-each>
</dc:identifier>
</xsl:template>
<xsl:template match="mods:language">
<dc:language>
<xsl:value-of select="normalize-space(.)"/>
</dc:language>
</xsl:template>
<xsl:template match="mods:relatedItem[mods:titleInfo | mods:name | mods:identifier | mods:location]">
<xsl:choose>
<xsl:when test="@type='original'">
<dc:source>
<xsl:for-each
select="mods:titleInfo/mods:title | mods:identifier | mods:location/mods:url">
<xsl:if test="normalize-space(.)!= ''">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:if>
</xsl:for-each>
</dc:source>
</xsl:when>
<xsl:when test="@type='series'"/>
<xsl:otherwise>
<dc:relation>
<xsl:for-each
select="mods:titleInfo/mods:title | mods:identifier | mods:location/mods:url">
<xsl:if test="normalize-space(.)!= ''">
<xsl:value-of select="."/>
<xsl:if test="position()!=last()">--</xsl:if>
</xsl:if>
</xsl:for-each>
</dc:relation>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="mods:accessCondition">
<dc:rights>
<xsl:value-of select="."/>
</dc:rights>
</xsl:template>
<xsl:template name="name">
<xsl:variable name="name">
<xsl:for-each select="mods:namePart[not(@type)]">
<xsl:value-of select="."/>
<xsl:text> </xsl:text>
</xsl:for-each>
<xsl:value-of select="mods:namePart[@type='family']"/>
<xsl:if test="mods:namePart[@type='given']">
<xsl:text>, </xsl:text>
<xsl:value-of select="mods:namePart[@type='given']"/>
</xsl:if>
<xsl:if test="mods:namePart[@type='date']">
<xsl:text>, </xsl:text>
<xsl:value-of select="mods:namePart[@type='date']"/>
<xsl:text/>
</xsl:if>
<xsl:if test="mods:displayForm">
<xsl:text> (</xsl:text>
<xsl:value-of select="mods:displayForm"/>
<xsl:text>) </xsl:text>
</xsl:if>
<xsl:for-each select="mods:role[mods:roleTerm[@type='text']!='creator']">
<xsl:text> (</xsl:text>
<xsl:value-of select="normalize-space(.)"/>
<xsl:text>) </xsl:text>
</xsl:for-each>
</xsl:variable>
<xsl:value-of select="normalize-space($name)"/>
</xsl:template>
<xsl:template match="mods:dateIssued[@point='start'] | mods:dateCreated[@point='start'] | mods:dateCaptured[@point='start'] | mods:dateOther[@point='start'] ">
<xsl:variable name="dateName" select="local-name()"/>
<dc:date>
<xsl:value-of select="."/>-
<xsl:value-of select="../*[local-name()=$dateName][@point='end']"/>
</dc:date>
</xsl:template>
<xsl:template match="mods:temporal[@point='start'] ">
<xsl:value-of select="."/>-
<xsl:value-of select="../mods:temporal[@point='end']"/>
</xsl:template>
<xsl:template match="mods:temporal[@point!='start' and @point!='end'] ">
<xsl:value-of select="."/>
</xsl:template>
<!-- suppress all else:-->
<xsl:template match="*"/>
</xsl:stylesheet>

174
ilives/xsl/book_view.xsl

@ -1,174 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:mods="http://www.loc.gov/mods/v3">
<xsl:variable name="OBJECTSPAGE">
<xsl:value-of select="$objectsPage"/>
</xsl:variable>
<xsl:variable name="PID">
<xsl:value-of select="$pid"/>
</xsl:variable>
<xsl:variable name="RECORDID">
<xsl:value-of select='substring-after($PID,":")'/>
</xsl:variable>
<xsl:variable name="USER" select="$userID"/>
<xsl:variable name="INGESTED" select="$ingested"/>
<xsl:template match="/">
<h1 >
<xsl:value-of select="//mods:titleInfo/mods:nonSort"/>
<xsl:text> </xsl:text>
<xsl:value-of select="//mods:titleInfo/mods:title"/>
<xsl:for-each select="//mods:titleInfo/mods:subTitle">
:
<xsl:value-of select="."/>
</xsl:for-each>
</h1>
<xsl:for-each select="//mods:titleInfo[@type='alternative']/mods.title">
<h3>
<!-- <xsl:value-of select="substring-before(text(),'/')"/>-->
<xsl:value-of select="."/>
<xsl:text> </xsl:text>
</h3>
</xsl:for-each>
<table cellpadding="3" cellspacing="2" valign="top" >
<tr>
<td valign="top">
<img>
<xsl:attribute name="src">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/
<xsl:copy-of select="$PID"/>/TN
</xsl:attribute>
</img>
</td>
<td >
<div style="align:left">
<table cellpadding="3" cellspacing="2" width="90%" >
<tr>
<td align="right" valign="top">
<b>By Statement: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:note[@type='statement of responsibility']"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Place of Publication: </b>
</td >
<td valign="top">
<xsl:value-of select="//mods:placeTerm[@type='text']"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Publisher: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:publisher"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Date: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:dateIssued"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Language: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:languageTerm"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Pagination: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:extent"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>ISBN 10: </b>
</td>
<td valign="top">
<xsl:value-of select="//mods:identifier[@type='isbn']"/>
</td>
</tr>
<tr>
<td align="right" valign="top">
<b>Subjects: </b>
</td>
<td valign="top">
<xsl:for-each select="//mods:subject">
<xsl:for-each select="*">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_search/mods.subject:"
<xsl:value-of select="normalize-space(.)"/>"%20AND%20dc.type:collection%20AND%20dc.type:ingested
</xsl:attribute>
<xsl:value-of select="."/>
</a>
<xsl:text> </xsl:text>
</xsl:for-each>
<br />
</xsl:for-each>
</td>
</tr>
</table>
</div>
</td>
<td valign="top">
<xsl:if test="$INGESTED = 'true'">
<div>
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_viewer/
<xsl:value-of select="$PID"/>
</xsl:attribute>Read
</a>
</div>
</xsl:if>
<div>
<a>
<xsl:attribute name="href">http://islandpines.roblib.upei.ca/opac/en-CA/skin/roblib/xml/rdetail.xml?r=
<xsl:value-of select="$RECORDID"/>
</xsl:attribute>
Checkout
</a>
</div>
<xsl:if test="$INGESTED = 'true'">
<div>
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/
<xsl:value-of select="$PID"/>/PDF/
<xsl:value-of select="$PID"/>.pdf
</xsl:attribute>Download
</a>
</div>
</xsl:if>
<xsl:if test="($USER > 0) and ($INGESTED = 'true')">
<div>
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>teieditor/
<xsl:value-of select="$PID"/>
</xsl:attribute>Edit
</a>
</div>
</xsl:if>
</td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>

45
ilives/xsl/book_view.xsl.bak

@ -1,45 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:mods="http://www.loc.gov/mods/v3">
<xsl:variable name="OBJECTSPAGE">
<xsl:value-of select="$objectsPage"/>
</xsl:variable>
<xsl:variable name="PID">
<xsl:value-of select="$pid"/>
</xsl:variable>
<xsl:template match="/">
<h1 ><xsl:value-of select="//mods:titleInfo/mods:nonSort"/><xsl:text> </xsl:text><xsl:value-of select="//mods:titleInfo/mods:title"/> <xsl:for-each select="//mods:titleInfo/mods:subTitle">
: <xsl:value-of select="."/></xsl:for-each></h1>
<xsl:for-each select="//mods:titleInfo[@type='alternative']/mods.title"><h3>
<!-- <xsl:value-of select="substring-before(text(),'/')"/>-->
<xsl:value-of select="."/><xsl:text> </xsl:text> </h3>
</xsl:for-each>
<table cellpadding="3" cellspacing="2" ><tr><td >
<img>
<xsl:attribute name="src"><xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/<xsl:copy-of select="$PID"/>/TN
</xsl:attribute>
</img>
</td><td ><div style="align:left"><table cellpadding="3" cellspacing="2" width="90%" >
<tr><td align="right" valign="top"><b>By Statement: </b></td><td valign="top"><xsl:value-of select="//mods:note[@type='statement of responsibility']"/></td></tr>
<tr><td align="right" valign="top"><b>Place of Publication: </b></td ><td valign="top"><xsl:value-of select="//mods:placeTerm[@type='text']"/></td></tr>
<tr><td align="right" valign="top"><b>Publisher: </b></td><td valign="top"><xsl:value-of select="//mods:publisher"/></td></tr>
<tr><td align="right" valign="top"><b>Date: </b></td><td valign="top"><xsl:value-of select="//mods:dateIssued"/></td></tr>
<tr><td align="right" valign="top"><b>Language: </b></td><td valign="top"><xsl:value-of select="//mods:languageTerm"/></td></tr>
<tr><td align="right" valign="top"><b>Pagination: </b></td><td valign="top"><xsl:value-of select="//mods:extent"/></td></tr>
<tr><td align="right" valign="top"><b>ISBN 10: </b></td><td valign="top"><xsl:value-of select="//mods:identifier[@type='isbn']"/></td></tr>
<tr><td align="right" valign="top"><b>Subjects: </b></td><td valign="top"><xsl:for-each select="//mods:subject">
<xsl:for-each select="*">
<a><xsl:attribute name="href"><xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/mnpl_advanced_search/mods.subject:"<xsl:value-of select="."/>"
</xsl:attribute>
<xsl:value-of select="."/></a><xsl:text> </xsl:text></xsl:for-each><br /></xsl:for-each>
</td></tr>
</table></div></td></tr></table>
<div><a><xsl:attribute name="href"><xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_viewer/<xsl:value-of select="$PID"/></xsl:attribute>Read</a>
</div>
</xsl:template>
</xsl:stylesheet>

44
ilives/xsl/book_view.xsl2009-05-26

@ -1,44 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:mods="http://www.loc.gov/mods/v3">
<xsl:variable name="OBJECTSPAGE">
<xsl:value-of select="$objectsPage"/>
</xsl:variable>
<xsl:variable name="PID">
<xsl:value-of select="$pid"/>
</xsl:variable>
<xsl:template match="/">
<h1 ><xsl:value-of select="//mods:titleInfo/mods:nonSort"/><xsl:text> </xsl:text><xsl:value-of select="//mods:titleInfo/mods:title"/> <xsl:for-each select="//mods:titleInfo/mods:subTitle">
: <xsl:value-of select="."/></xsl:for-each></h1>
<xsl:for-each select="//mods:titleInfo[@type='alternative']/mods.title"><h3>
<!-- <xsl:value-of select="substring-before(text(),'/')"/>-->
<xsl:value-of select="."/><xsl:text> </xsl:text> </h3>
</xsl:for-each>
<table cellpadding="3" cellspacing="2" ><tr><td >
<img>
<xsl:attribute name="src"><xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/<xsl:copy-of select="$PID"/>/TN
</xsl:attribute>
</img>
</td><td ><div style="align:left"><table cellpadding="3" cellspacing="2" width="90%" >
<tr><td align="right" valign="top"><b>By Statement: </b></td><td valign="top"><xsl:value-of select="//mods:note[@type='statement of responsibility']"/></td></tr>
<tr><td align="right" valign="top"><b>Place of Publication: </b></td ><td valign="top"><xsl:value-of select="//mods:placeTerm[@type='text']"/></td></tr>
<tr><td align="right" valign="top"><b>Publisher: </b></td><td valign="top"><xsl:value-of select="//mods:publisher"/></td></tr>
<tr><td align="right" valign="top"><b>Date: </b></td><td valign="top"><xsl:value-of select="//mods:dateIssued"/></td></tr>
<tr><td align="right" valign="top"><b>Language: </b></td><td valign="top"><xsl:value-of select="//mods:languageTerm"/></td></tr>
<tr><td align="right" valign="top"><b>Pagination: </b></td><td valign="top"><xsl:value-of select="//mods:extent"/></td></tr>
<tr><td align="right" valign="top"><b>ISBN 10: </b></td><td valign="top"><xsl:value-of select="//mods:identifier[@type='isbn']"/></td></tr>
<tr><td align="right" valign="top"><b>Subjects: </b></td><td valign="top"><xsl:for-each select="//mods:subject">
<xsl:for-each select="*">
<a><xsl:attribute name="href"><xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/mnpl_advanced_search/mods.subject:"<xsl:value-of select="."/>"
</xsl:attribute>
<xsl:value-of select="."/></a><xsl:text> </xsl:text></xsl:for-each><br /></xsl:for-each>
</td></tr>
</table></div></td></tr></table>
</xsl:template>
</xsl:stylesheet>

165
ilives/xsl/pageResults.xsl

@ -1,165 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" >
<xsl:variable name="OBJECTSPAGE">
<xsl:value-of select="$objectsPage"/>
</xsl:variable>
<!--<xsl:variable name="ALLOWEDNAMESPACES" select="$allowedPidNameSpaces"/>-->
<xsl:variable name="cellsPerRow" select="6"/>
<xsl:variable name="USER" select="$userID"/>
<!--<xsl:variable name="count" select="count(//objects)"/>-->
<!--<xsl:variable name="PATHTOMAKEIMAGE">
<xsl:value-of select="$pathToMakeImage"/>
</xsl:variable>-->
<xsl:template match="gfindObjects">
<xsl:variable name="INDEXNAME" select="@indexName"/>
<xsl:variable name="PREQUERY" select="substring-before(@query,':')"/>
<!--<xsl:variable name="QUERY" select="substring-after(@query,':')"/>-->
<xsl:variable name="QUERY" select="@query"/>
<xsl:variable name="HITPAGESTART" select="@hitPageStart"/>
<xsl:variable name="HITPAGESIZE" select="@hitPageSize"/>
<xsl:variable name="HITTOTAL" select="@hitTotal"/>
<xsl:variable name="TOKEN">
<xsl:value-of select="$searchToken"/>
</xsl:variable>
<xsl:variable name="HITPAGEEND">
<xsl:choose>
<xsl:when test="$HITPAGESTART + $HITPAGESIZE - 1 > $HITTOTAL">
<xsl:value-of select="$HITTOTAL"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$HITPAGESTART + $HITPAGESIZE - 1"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="HITPAGENO" select="ceiling($HITPAGESTART div $HITPAGESIZE)"/>
<xsl:variable name="HITPAGENOLAST" select="ceiling($HITTOTAL div $HITPAGESIZE)"/>
<xsl:variable name="HITPAGESTARTT" select="(($HITPAGENO - 1) * $HITPAGESIZE + 1)"/>
<xsl:choose>
<xsl:when test="$HITTOTAL > 0">
Total Hits =
<strong>
<xsl:value-of select="@hitTotal"/>,
</strong>
<!-- Number of Hits/page = <xsl:value-of select="@hitPageSize"/>-->
<br />We have repeated your search within this book and found results on the following pages.
<!-- Current page = <xsl:value-of select="@hitPageStart"/>-->
<br/>
<xsl:apply-templates select="objects">
<xsl:with-param name="end" select="$HITTOTAL"/>
</xsl:apply-templates>
</xsl:when>
<!--<xsl:otherwise>
<div class="box">
<h2>We have repeated your search within this book and have not found any results.</h2>
</div>
</xsl:otherwise>-->
</xsl:choose>
</xsl:template>
<xsl:template match="objects">
<xsl:param name="end"/>
<div class="search-results">
<table>
<xsl:for-each select="object[position() mod $cellsPerRow = 1 and position()>=0 and position() &lt;=$end]">
<xsl:sort select="field[@name='PID']/text()" order='ascending'/>
<tr>
<xsl:apply-templates select=". | following-sibling::object[position() &lt; $cellsPerRow]">
<xsl:sort select="field[@name='PID']/text()" order='ascending'/>
</xsl:apply-templates>
</tr>
</xsl:for-each>
</table>
</div>
</xsl:template>
<xsl:template match="object">
<xsl:variable name="PIDVALUE">
<xsl:choose>
<xsl:when test="@PID">
<xsl:value-of select="@PID"/>
</xsl:when>
<xsl:when test="field[@name='PID' and @snippet='yes']">
<xsl:value-of select="field[@name='PID']/span/text()"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="field[@name='PID']/text()"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:call-template name="showResult">
<xsl:with-param name="PIDVALUE" select="$PIDVALUE"/>
</xsl:call-template>
</xsl:template>
<xsl:template name="showResult">
<xsl:param name="PIDVALUE"/>
<xsl:variable name="DCTITLE">
<xsl:value-of select="field[@name='dc.title']/node()"/>
</xsl:variable>
<!-- <xsl:variable name="CLEANTITLE">
<xsl:value-of select="php:functionString('fedora_repository_urlencode_string', $DCTITLE)"/>
</xsl:variable>-->
<xsl:variable name="recordNo">
<xsl:value-of select="position()"/>
</xsl:variable>
<td valign="top" width="16%">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_viewer/
<xsl:copy-of select="$PIDVALUE"/>
</xsl:attribute>
<img>
<xsl:attribute name="alt">Thumbnail
<xsl:copy-of select="$PIDVALUE"/>
</xsl:attribute>
<xsl:attribute name="src">
<!--http://islandlives.ca:8080/adore-djatoka/resolver?url_ver=Z39.88-2004&amp;rft_id=http://islandlives.ca/fedora/repository/<xsl:copy-of select="$PIDVALUE"/>/JP2/jp2.jp2&amp;svc_id=info:lanl-repo/svc/getRegion&amp;svc_val_fmt=info:ofi/fmt:kev:mtx:jpeg2000&amp;svc.format=image/jpeg&amp;svc.level=0&amp;svc.rotate=0&amp;svc.region=0,0,100,100</xsl:attribute>
-->
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/
<xsl:copy-of select="$PIDVALUE"/>/TN
</xsl:attribute>
</img>
</a>
<br />
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_viewer/
<xsl:value-of select="$PIDVALUE"/>
</xsl:attribute>
<xsl:value-of select="substring-before($DCTITLE, '-')"/>
<br />
</a>
</td >
<xsl:if test="(position() = last()) and (position() &lt; $cellsPerRow)">
<xsl:call-template name="FillerCells">
<xsl:with-param name="cellCount" select="$cellsPerRow - position()"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
<xsl:template name="FillerCells">
<xsl:param name="cellCount"/>
<td>&#160;</td>
<xsl:if test="$cellCount > 1">
<xsl:call-template name="FillerCells">
<xsl:with-param name="cellCount" select="$cellCount - 1"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
</xsl:stylesheet>

395
ilives/xsl/results.xsl

@ -1,395 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:php="http://php.net/xsl" exclude-result-prefixes="php">
<xsl:variable name="OBJECTSPAGE">
<xsl:value-of select="$objectsPage"/>
</xsl:variable>
<xsl:variable name="ALLOWEDNAMESPACES" select="$allowedPidNameSpaces"/>
<xsl:variable name="FULLQUERY" select="$fullQuery"/>
<!--<xsl:variable name="PATHTOMAKEIMAGE">
<xsl:value-of select="$pathToMakeImage"/>
</xsl:variable>-->
<xsl:template match="gfindObjects">
<xsl:variable name="INDEXNAME" select="@indexName"/>
<xsl:variable name="PREQUERY" select="substring-before(@query,':')"/>
<xsl:variable name="QUERY" select="substring-after(@query,':')"/>
<xsl:variable name="HITPAGESTART" select="@hitPageStart"/>
<xsl:variable name="HITPAGESIZE" select="@hitPageSize"/>
<xsl:variable name="HITTOTAL" select="@hitTotal"/>
<xsl:variable name="SEARCHURL">
<xsl:value-of select="$searchUrl"/>
</xsl:variable>
<xsl:variable name="TOKEN">
<xsl:value-of select="$searchToken"/>
</xsl:variable>
<xsl:variable name="HITPAGEEND">
<xsl:choose>
<xsl:when test="$HITPAGESTART + $HITPAGESIZE - 1 > $HITTOTAL">
<xsl:value-of select="$HITTOTAL"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$HITPAGESTART + $HITPAGESIZE - 1"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="HITPAGENO" select="ceiling($HITPAGESTART div $HITPAGESIZE)"/>
<xsl:variable name="HITPAGENOLAST" select="ceiling($HITTOTAL div $HITPAGESIZE)"/>
<xsl:variable name="HITPAGESTARTT" select="(($HITPAGENO - 1) * $HITPAGESIZE + 1)"/>
<xsl:choose>
<xsl:when test="$HITTOTAL > 0">
Total Hits =
<strong>
<xsl:value-of select="$HITTOTAL"/>,
</strong>
Number of Hits/page =
<xsl:value-of select="$HITPAGESIZE"/>
<!-- <br />You may not have sufficient privileges to view any or all of the items found. The objects you have rights to view will be shown below.-->
<!--Current page = <xsl:value-of select="@hitPageStart"/>-->
<br/>
<!--<form action="/drupal-5.1/?q=search/fedora_collections" method="post" id="search-form" class="search-form">-->
<br/>
<xsl:if test="$HITTOTAL > $HITPAGESIZE">
<div class="item-list">
<ul class="pager">
<xsl:if test="$HITPAGENO > 1">
<li class="pager-previous">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_search/
<xsl:value-of select="$FULLQUERY"/>/
<xsl:value-of select="$HITPAGESTARTT - $HITPAGESIZE"/>
</xsl:attribute>
&lt; Previous
</a>
</li>
</xsl:if>
<xsl:text> </xsl:text>
<xsl:if test="$HITPAGENO &lt; $HITPAGENOLAST">
<li class="pager-next">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_search/
<xsl:value-of select="$FULLQUERY"/>/
<xsl:value-of select="$HITPAGESTARTT+$HITPAGESIZE"/>
</xsl:attribute>
Next >
</a>
</li>
</xsl:if>
</ul>
</div>
</xsl:if>
<style type="text/css">
span.highlight
{
background-color:yellow
}
span.searchtitle
{
font-weight: bold
}
</style>
<xsl:apply-templates select="objects"/>
<xsl:if test="$HITTOTAL > $HITPAGESIZE">
<div class="item-list">
<ul class="pager">
<xsl:if test="$HITPAGENO > 1">
<li class="pager-previous">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_search/
<xsl:value-of select="$FULLQUERY"/>/
<xsl:value-of select="$HITPAGESTARTT - $HITPAGESIZE"/>
</xsl:attribute>
&lt; Previous
</a>
</li>
</xsl:if>
<xsl:text> </xsl:text>
<xsl:if test="$HITPAGENO &lt; $HITPAGENOLAST">
<li class="pager-next">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives_book_search/
<xsl:value-of select="$FULLQUERY"/>/
<xsl:value-of select="$HITPAGESTARTT+$HITPAGESIZE"/>
</xsl:attribute>
Next >
</a>
</li>
</xsl:if>
</ul>
</div>
</xsl:if>
</xsl:when>
<xsl:otherwise>
<div class="box">
<h2>Your search yielded no results</h2>
<div class="content">
<ul>
<li>Check if your spelling is correct.</li>
<li>Remove quotes around phrases to match each word individually:
<em>"blue smurf"</em> will match less than
<em>blue smurf</em>.
</li>
<li>Consider loosening your query with
<em>OR</em>:
<em>blue smurf</em> will match less than
<em>blue OR smurf</em>.
</li>
</ul>
</div>
</div>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template match="objects">
<table cellpadding="3" cellspacing="3" width="100%">
<div class="search-results">
<tr>
<td colspan="2">
</td>
</tr>
<xsl:for-each select="object">
<xsl:variable name="PIDVALUE">
<xsl:choose>
<xsl:when test="@PID">
<xsl:value-of select="@PID"/>
</xsl:when>
<xsl:when test="field[@name='PID' and @snippet='yes']">
<xsl:value-of select="field[@name='PID']/span/text()"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="field[@name='PID']/text()"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:call-template name="splitBySpace">
<xsl:with-param name="PIDVALUE" select="$PIDVALUE"></xsl:with-param>
<xsl:with-param name="str" select="$ALLOWEDNAMESPACES"/>
</xsl:call-template>
</xsl:for-each>
</div>
</table>
</xsl:template>
<xsl:template name="splitBySpace">
<xsl:param name="str"/>
<xsl:param name="PIDVALUE"/>
<xsl:choose>
<xsl:when test="contains($str,' ')">
<!--'DO SOMETHING WITH THE VALUE IN
{substring-before($str,' ')}-->
<xsl:variable name="testString" select="substring-before($str,' ')"/>
<xsl:if test="starts-with($PIDVALUE,$testString)">
<xsl:call-template name="showResult">
<xsl:with-param name="PIDVALUE" select="$PIDVALUE"/>
</xsl:call-template>
</xsl:if>
<!--<xsl:value-of select="substring-before($str,' ')"/>-->
<xsl:call-template name="splitBySpace">
<xsl:with-param name="str"
select="substring-after($str,' ')"/>
<xsl:with-param name="PIDVALUE"
select="$PIDVALUE"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<!--<xsl:if test="substring-before($str, ':') = substring-before($PIDVALUE, ':')">
<xsl:call-template name="showResult">
<xsl:with-param name="PIDVALUE" select="$PIDVALUE"/>
</xsl:call-template>
</xsl:if>-->
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="showResult">
<xsl:param name="PIDVALUE"/>
<xsl:variable name="DCTITLE">
<xsl:value-of select="field[@name='dc.title']/node()"/>
</xsl:variable>
<xsl:variable name="CLEANTITLE">
<xsl:value-of select="php:functionString('fedora_repository_urlencode_string', $DCTITLE)"/>
</xsl:variable>
<tr>
<td valign="top">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives/
<xsl:copy-of select="$PIDVALUE"/>/
<xsl:value-of select="$FULLQUERY"/>
</xsl:attribute>
<!--<xsl:attribute name="href"><xsl:copy-of select="$OBJECTSPAGE"/><![CDATA[&pid=]]><xsl:value-of select="$PIDVALUE"/><![CDATA[&collection=object]]>
</xsl:attribute>-->
<img>
<xsl:attribute name="src">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/repository/
<xsl:copy-of select="$PIDVALUE"/>/TN
</xsl:attribute>
<xsl:attribute name="height">100</xsl:attribute>
</img>
</a>
</td >
<td valign="top">
<span class="searchtitle">
<a>
<xsl:attribute name="href">
<xsl:copy-of select="$OBJECTSPAGE"/>fedora/ilives/
<xsl:value-of select="$PIDVALUE"/>/
<xsl:value-of select="$FULLQUERY"/>
</xsl:attribute>
<xsl:for-each select="field[@name='mods.title']">
<!-- <xsl:value-of select="substring-before(text(),'/')"/>-->
<xsl:value-of select="node()"/>
<xsl:text> </xsl:text>
</xsl:for-each>
<xsl:for-each select="field[@name='mods.subTitle']">
<span class="searchsubtitle">
<xsl:text> : </xsl:text>
<xsl:value-of select="node()"/>
</span>
</xsl:for-each>
</a>
</span>
<xsl:for-each select="field[@name='mods.sor']">
<span class="searchcreator">
<xsl:text> / </xsl:text>
<xsl:value-of select="node()"/>
</span>
</xsl:for-each>
<xsl:for-each select="field[@name='mods.place_of_publication']">
<span class="searchpop">
<xsl:text> </xsl:text>
<xsl:value-of select="node()"/>
</span>
</xsl:for-each>
<xsl:for-each select="field[@name='mods.publisher']">
<span class="searchpop">
<xsl:text> : </xsl:text>
<xsl:value-of select="node()"/>
</span>
</xsl:for-each>
<xsl:for-each select="field[@name='mods.dateIssued']">
<span class="searchdateIssued">
<xsl:text>, </xsl:text>
<xsl:value-of select="node()"/>.
</span>
</xsl:for-each>
<xsl:for-each select="field[@name='mods.edition']">
<span class="searchedition">
<xsl:text> </xsl:text>
<xsl:value-of select="node()"/>
</span>
</xsl:for-each>
</td>
</tr>
<!--
<xsl:for-each select="field">
<xsl:choose>
<xsl:when test="(@name='dc.titledsm.OBJ')">
<tr>
<td valign="top">
<span class="searchtitle">
Text Stream
</span>
</td>
<td>
<span class="text">
<xsl:copy-of select="node()"/>
</span>
</td>
</tr>
</xsl:when>
<xsl:when test="(@name='dc.title')">
</xsl:when>
<xsl:otherwise>
<tr>
<td valign="top">
<span class="searchtitle">
<xsl:value-of select="@name"/>
</span>
</td>
<td>
<span class="text">
<xsl:copy-of select="node()"/>
</span>
</td>
</tr>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
-->
</xsl:template>
</xsl:stylesheet>
Loading…
Cancel
Save