[MOBY-guts] biomoby commit

Paul Gordon gordonp at dev.open-bio.org
Tue May 4 16:14:59 UTC 2010


gordonp
Tue May  4 12:14:59 EDT 2010
Update of /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util
In directory dev.open-bio.org:/tmp/cvs-serv5536/src/main/ca/ucalgary/seahawk/util

Modified Files:
	DataUtils.java 
Log Message:
Added createServiceInputFileForPeers() method used by MobyContentPane
moby-live/Java/src/main/ca/ucalgary/seahawk/util DataUtils.java,1.7,1.8
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/DataUtils.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/DataUtils.java	2010/04/26 16:25:36	1.7
+++ /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/DataUtils.java	2010/05/04 16:14:59	1.8
@@ -1024,6 +1024,24 @@
     }
 
     /**
+     * Create a temp file that populates the MobyContentInstance from the sample data
+     * for all missing fields in peerJobs.  This is used to populate a bunch of jobs
+     * at once, iterating over some list of values popped into the peerJobs payload.
+     * Used after service wrapping demo to call new service fopr all demo input peers.
+     */
+    public static URL createServiceInputFileForPeers(MobyContentInstance peerJobs, MobyDataJob sampleJob) throws Exception{
+	for(MobyDataJob peerJob: peerJobs.values()){
+	    for(String paramName: sampleJob.keySet()){
+		if(!peerJob.containsKey(paramName)){
+		    peerJob.put(paramName, sampleJob.get(paramName));
+		}
+	    }
+	}
+	
+	return saveInputData(peerJobs);
+    }
+
+    /**
      * We need to enumerate the possible peer-sets for the selected data item.  Is the user interested in
      * items in the same namespace/data type, or same article name?
      */




More information about the MOBY-guts mailing list