Changeset 15670 for other-projects
- Timestamp:
- 2008-05-23T13:31:52+12:00 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
other-projects/trunk/gs3-webservices-democlient/src/GS3Fedora/org/greenstone/fedora/services/FedoraGS3Connection.java
r15437 r15670 1378 1378 // for each letter of the alphabet: 1379 1379 Element classifier = createClassifierElement(doc, "TitleByLetter", 1380 classifierNum++, "titles (by letter)", "Browse titles by letter");1380 classifierNum++, "titles by letter", "Browse titles by letter"); 1381 1381 // now add this <classifier> to the <classifierList> 1382 1382 classifierList.appendChild(classifier); … … 1722 1722 int num = 1; 1723 1723 for(char ch = 'A'; ch <= 'Z'; ch++, num++) { 1724 // Retrieve the document structure for each subClassifierID: 1725 // all the documents that begin with its letter. 1726 // remove the starting CL 1727 String letter = String.valueOf(ch); 1728 try{ 1729 String[] docPIDs = this.browseTitlesByLetter( 1730 collectionName, letter); 1731 if(docPIDs.length == 0) { 1732 continue; // skip letters that don't have any kids 1733 } 1734 1724 1735 // <classifierNode nodeID="CL3.1"> 1725 1736 Element subClassifier = doc.createElement( 1726 1737 GSXML.CLASS_NODE_ELEM); 1727 1738 attribute = doc.createAttribute(GSXML.NODE_ID_ATT); 1728 1739 attribute.setValue(classifierID+"."+num); 1729 1740 subClassifier.setAttributeNode(attribute); 1730 1741 classifierNode.appendChild(subClassifier); 1731 // now we are going to retrieve the document structure for 1732 // this subClassifierID: all the documents that begin with 1733 // its letter. 1734 // remove the starting CL 1735 String letter = String.valueOf(ch); 1736 try{ 1737 String[] docPIDs = this.browseTitlesByLetter( 1738 collectionName, letter); 1739 // append the <docNodes> for the docPIDs found as children 1740 // of subclassifier 1741 getStructureElement(subClassifier, docPIDs, DESCENDANTS); 1742 //CHILDREN); // for testing 1743 } catch(Exception e) { 1744 ex = new FedoraGS3RunException(e); 1745 ex.setSpecifics("requested portion of TOC file or " 1746 + "trouble with fielded search "); 1747 } 1742 1743 // append the <docNodes> for the docPIDs found as children 1744 // of subclassifier 1745 getStructureElement(subClassifier, docPIDs, DESCENDANTS); 1746 //CHILDREN); // for testing 1747 } catch(Exception e) { 1748 ex = new FedoraGS3RunException(e); 1749 ex.setSpecifics("requested portion of TOC file or " 1750 + "trouble with fielded search "); 1751 } 1748 1752 } 1749 1753 break;
Note:
See TracChangeset
for help on using the changeset viewer.