[MOBY-guts] biomoby commit
Paul Gordon
gordonp at dev.open-bio.org
Wed Aug 1 18:14:34 UTC 2007
gordonp
Wed Aug 1 14:14:33 EDT 2007
Update of /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/services
In directory dev.open-bio.org:/tmp/cvs-serv13008/src/main/ca/ucalgary/seahawk/services
Modified Files:
TextClient.java
Log Message:
Switched colon to hyphen prefix separator for denoting collection creating templates in the XSLT
moby-live/Java/src/main/ca/ucalgary/seahawk/services TextClient.java,1.4,1.5
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/services/TextClient.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/services/TextClient.java 2007/06/08 14:04:27 1.4
+++ /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/services/TextClient.java 2007/08/01 18:14:33 1.5
@@ -65,7 +65,7 @@
}
// Lines look something like below
- // <xsl:template match="moby:GenericSequence | GenericSequence" name="Collection:GenericSequence#1" mode="seq">
+ // <xsl:template match="moby:GenericSequence | GenericSequence" name="Collection-GenericSequence#1" mode="seq">
NodeList templates = xsltDOMRoot.getElementsByTagNameNS(XSLT_NS, "template");
for(int i = 0; i < templates.getLength(); i++){
Element template = (Element) templates.item(i);
@@ -85,7 +85,7 @@
continue;
}
- if(templateNameParts[0].startsWith("Collection:")){
+ if(templateNameParts[0].startsWith("Collection-")){
if(templateNameParts[0].length() == 11){
throw new Exception("The name for one of the templates (" + templateName +
") did not specify a Moby data type after the Collection prefix");
@@ -129,14 +129,14 @@
if(typeTemplates.containsKey(type.getName())){
for(String templateName: typeTemplates.get(type.getName())){
if(textType.equals(templateMode.get(templateName))){
- // Input Moby type amd output text type match: does set-ness?
+ // Input Moby type and output text type match: does set-ness?
if(dataTemplate instanceof MobyPrimaryDataSet){
- if(templateName.startsWith("Collection:")){
+ if(templateName.startsWith("Collection-")){
return true;
}
}
else{
- if(!templateName.startsWith("Collection:")){
+ if(!templateName.startsWith("Collection-")){
return true;
}
}
@@ -172,13 +172,13 @@
if(targetTextType.equals(templateMode.get(templateName))){
// Input Moby type and output text type match, we'll try the template here
if(mobyData instanceof MobyPrimaryDataSet){
- if(templateName.startsWith("Collection:")){
+ if(templateName.startsWith("Collection-")){
candidateTypes.add(type);
break;
}
}
else{
- if(!templateName.startsWith("Collection:")){
+ if(!templateName.startsWith("Collection-")){
candidateTypes.add(type);
break;
}
More information about the MOBY-guts
mailing list