[MOBY-guts] biomoby commit

Paul Gordon gordonp at dev.open-bio.org
Fri Oct 27 20:00:35 UTC 2006


gordonp
Fri Oct 27 16:00:35 EDT 2006
Update of /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util
In directory dev.open-bio.org:/tmp/cvs-serv23670/src/main/ca/ucalgary/seahawk/util

Modified Files:
	MobyUtils.java 
Log Message:
Improvements to popup-menu hierarchy when there are many, many service options
moby-live/Java/src/main/ca/ucalgary/seahawk/util MobyUtils.java,1.2,1.3
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MobyUtils.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MobyUtils.java	2006/10/26 00:35:19	1.2
+++ /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MobyUtils.java	2006/10/27 20:00:35	1.3
@@ -5,12 +5,13 @@
 
 import org.biomoby.shared.data.*;
 import org.biomoby.shared.MobyDataType;
+import org.biomoby.shared.MobyNamespace;
 
 import java.util.Vector;
 import javax.swing.JLabel;
 
 public class MobyUtils{
-    public static final int MAX_OBJ_NAME_LEN = 18;
+    public static final int MAX_OBJ_NAME_LEN = 12;
 
     private static MobyContentGUI mobyContentGUI = null;
     private static MobyServicesGUI mobyServicesGUI = null;
@@ -29,13 +30,15 @@
 	}
 	
 	// Can always use the data as a string
-	objects.add(new MobyDataString(objectName, data));
+	MobyDataString strObject = new MobyDataString(objectName, data);
+	strObject.setPrimaryNamespace(new MobyNamespace("seahawk"));
+	objects.add(strObject);
 
 	// If it's a single word, give keyword options
 	if(data.trim().matches("^[A-Za-z0-9_-]{3,}$")){
 	    objects.add(new MobyDataComposite("Global_Keyword",
 					      "dummy_name", 
-					      "seahawk_namespace", 
+					      "seahawk", 
 					      data.trim()));
         }
 
@@ -113,19 +116,19 @@
 	if(Sequence.isDNA(sequenceData)){
 	    sequence = new MobyDataComposite("DNASequence", 
 					     "dummy_name", 
-					     "seahawk_namespace", 
+					     "seahawk", 
 					     id);
 	}
 	else if(Sequence.isRNA(sequenceData)){
 	    sequence = new MobyDataComposite("RNASequence", 
 					     "dummy_name", 
-					     "seahawk_namespace", 
+					     "seahawk", 
 					     id);
 	}
 	else if(Sequence.isProtein(sequenceData)){
 	    sequence = new MobyDataComposite("AminoAcidSequence", 
 					     "dummy_name", 
-					     "seahawk_namespace", 
+					     "seahawk", 
 					     id);
 	}
 	// Not a recognized type of sequence




More information about the MOBY-guts mailing list