Changeset 25977
- Timestamp:
- 2012-07-19T14:28:07+12:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/src/java/org/greenstone/gsdl3/service/AbstractBrowse.java
r25689 r25977 20 20 21 21 // Greenstone classes 22 import java.util.ArrayList; 23 24 import org.apache.log4j.Logger; 25 import org.greenstone.gsdl3.util.GSPath; 22 26 import org.greenstone.gsdl3.util.GSXML; 23 import org.greenstone.gsdl3.util.GSPath;24 27 import org.greenstone.gsdl3.util.MacroResolver; 25 28 import org.greenstone.gsdl3.util.OID; 26 27 // XML classes28 29 import org.w3c.dom.Document; 29 30 import org.w3c.dom.Element; 30 31 import org.w3c.dom.Node; 31 32 import org.w3c.dom.NodeList; 32 33 // General Java classes34 import java.util.ArrayList;35 36 import org.apache.log4j.*;37 33 38 34 /** … … 95 91 macro_resolver.addMacros(replacement_elem); 96 92 } 97 98 93 } 99 94 … … 139 134 { 140 135 Element cl = (Element) classifiers.item(i); 136 141 137 Element new_cl = (Element) this.doc.importNode(cl, false); // just import this node, not the children 142 138 … … 146 142 if (format != null) 147 143 { 148 149 144 //copy all the children 150 145 NodeList elems = format.getChildNodes(); … … 270 265 static boolean extractExtraClassifierInfo(Element info, Element extra_info) 271 266 { 272 273 267 if (extra_info == null) 274 268 { … … 319 313 Element e = (Element) display_names.item(j); 320 314 cl.appendChild(owner.importNode(e, true)); 321 322 315 } 323 316 } … … 325 318 // get the format element if any 326 319 Element format = (Element) GSXML.getChildByTagName(node_extra, GSXML.FORMAT_ELEM); 327 if (format == null)328 { // try a generic one that applies to all classifiers329 format = (Element) GSXML.getChildByTagName(extra_info, GSXML.FORMAT_ELEM);330 }331 320 if (format != null) 332 321 { // append to index info
Note:
See TracChangeset
for help on using the changeset viewer.