Changeset 14640
- Timestamp:
- 2007-10-10T17:41:52+13:00 (17 years ago)
- Location:
- greenstone3/trunk/src/java/org/greenstone/gsdl3/collection
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
greenstone3/trunk/src/java/org/greenstone/gsdl3/collection/Collection.java
r14208 r14640 57 57 /** time when this collection was built */ 58 58 protected long lastmodified = 0; 59 59 60 60 /** An element containing the serviceRackList element of buildConfig.xml, used to determine whether it contains 61 61 * the OAIPMH serviceRack … … 98 98 return false; 99 99 } 100 101 // get the collection type attribute 102 Element search = (Element) GSXML.getChildByTagName(coll_config_xml, GSXML.SEARCH_ELEM); 103 if(search!=null) { 104 col_type = search.getAttribute(GSXML.TYPE_ATT); 105 } 106 100 107 // process the metadata and display items 101 108 findAndLoadInfo(coll_config_xml, build_config_xml); … … 182 189 protected boolean findAndLoadInfo(Element coll_config_xml, 183 190 Element build_config_xml){ 184 191 185 192 // metadata 186 193 Element meta_list = (Element)GSXML.getChildByTagName(coll_config_xml, GSXML.METADATA_ELEM+GSXML.LIST_MODIFIER); -
greenstone3/trunk/src/java/org/greenstone/gsdl3/collection/ServiceCluster.java
r14223 r14640 60 60 /** The name of the cluster - for a collection, this is the collection name*/ 61 61 protected String cluster_name = null; 62 /** collection type : mg or mgpp */ 63 protected String col_type = ""; 62 64 63 65 /** a reference to the message router */ … … 109 111 this.cluster_name = name; 110 112 this.description.setAttribute(GSXML.NAME_ATT, name); 111 } 113 } 112 114 113 115 public void setMessageRouter(MessageRouter m) { … … 170 172 171 173 public boolean configure(Element service_cluster_info) { 172 174 173 175 // get the metadata - for now just add it to the list 174 176 Element meta_list = (Element) GSXML.getChildByTagName(service_cluster_info, GSXML.METADATA_ELEM+GSXML.LIST_MODIFIER); … … 468 470 // create the collection element 469 471 Element description = (Element)this.description.cloneNode(false); 472 // set collection type : mg or mgpp 473 description.setAttribute(GSXML.TYPE_ATT, col_type); 474 470 475 response.appendChild(description); 471 476 // check the param list 472 477 Element param_list = (Element) GSXML.getChildByTagName(request, GSXML.PARAM_ELEM+GSXML.LIST_MODIFIER); 473 if (param_list == null) { 474 addAllDisplayInfo(description, lang); 478 if (param_list == null) { 479 addAllDisplayInfo(description, lang); 475 480 description.appendChild(this.service_list); 476 481 description.appendChild(this.metadata_list); … … 481 486 // go through the param list and see what components are wanted 482 487 NodeList params = param_list.getElementsByTagName(GSXML.PARAM_ELEM); 483 for (int i=0; i<params.getLength(); i++) { 484 485 Element param = (Element)params.item(i); 488 for (int i=0; i<params.getLength(); i++) { 489 490 Element param = (Element)params.item(i); 486 491 // Identify the structure information desired 487 492 if (param.getAttribute(GSXML.NAME_ATT).equals(GSXML.SUBSET_PARAM)) {
Note:
See TracChangeset
for help on using the changeset viewer.