[MOBY-guts] biomoby commit

Paul Gordon gordonp at dev.open-bio.org
Fri Dec 7 20:29:52 UTC 2007


gordonp
Fri Dec  7 15:29:51 EST 2007
Update of /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util
In directory dev.open-bio.org:/tmp/cvs-serv2374/src/main/ca/ucalgary/seahawk/util

Modified Files:
	HTMLUtils.java 
Log Message:
Made binary data encapsulation registry-aware
moby-live/Java/src/main/ca/ucalgary/seahawk/util HTMLUtils.java,1.5,1.6
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/HTMLUtils.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/HTMLUtils.java	2007/12/06 18:07:16	1.5
+++ /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/HTMLUtils.java	2007/12/07 20:29:51	1.6
@@ -1,5 +1,6 @@
 package ca.ucalgary.seahawk.util;
 
+import org.biomoby.registry.meta.Registry;
 import org.biomoby.shared.*;
 import org.biomoby.shared.data.*;
 import org.biomoby.shared.parser.MobyTags;
@@ -16,7 +17,11 @@
     public final static String ACCEPTABLE_IMAGE_DATATYPE = "WebFormatImage"; //from the ontology, should eventually be configurable
 
     public static String encapsulateBinaryData(URL sourceMobyData, String html) throws Exception{
-	MobyContentInstance dataPackage = MobyDataUtils.fromXMLDocument(sourceMobyData);
+	return encapsulateBinaryData(sourceMobyData, html, null);
+    }
+
+    public static String encapsulateBinaryData(URL sourceMobyData, String html, Registry registry) throws Exception{
+	MobyContentInstance dataPackage = MobyDataUtils.fromXMLDocument(sourceMobyData, registry);
 	// Look for binary data and replace it with an image ref (if its an image
 	// displayable in our viewer), or simply "(binary data)".
 	for(MobyDataJob job: dataPackage.values()){




More information about the MOBY-guts mailing list