[MOBY-guts] biomoby commit

Gary Schlitz gss at pub.open-bio.org
Tue Mar 30 22:24:28 UTC 2004


gss
Tue Mar 30 17:24:28 EST 2004
Update of /home/repository/moby/moby-live/S-MOBY/ref-impl/example-providers/acmepubs.com/src/com/acmepubs/servlets
In directory pub.open-bio.org:/tmp/cvs-serv27965/src/com/acmepubs/servlets

Modified Files:
	CitationSearchServlet.java 
Log Message:
Minor incremental changes

moby-live/S-MOBY/ref-impl/example-providers/acmepubs.com/src/com/acmepubs/servlets CitationSearchServlet.java,1.4,1.5
===================================================================
RCS file: /home/repository/moby/moby-live/S-MOBY/ref-impl/example-providers/acmepubs.com/src/com/acmepubs/servlets/CitationSearchServlet.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- /home/repository/moby/moby-live/S-MOBY/ref-impl/example-providers/acmepubs.com/src/com/acmepubs/servlets/CitationSearchServlet.java	2004/03/29 19:35:51	1.4
+++ /home/repository/moby/moby-live/S-MOBY/ref-impl/example-providers/acmepubs.com/src/com/acmepubs/servlets/CitationSearchServlet.java	2004/03/30 22:24:28	1.5
@@ -9,6 +9,7 @@
 import org.smoby.tools.common.graph.MOBYGraph;
 import org.smoby.tools.server.servlet.AbstractMobyServlet;
 
+import com.acmepubs.db.CitationDB;
 import com.acmepubs.vocabulary.AcmePubs;
 import com.hp.hpl.jena.rdf.model.*;
 
@@ -53,29 +54,26 @@
         if (it.hasNext())
         {
         	Statement s = it.nextStatement();
-        	String geneID = s.getString();
-        	String pubDate = getPubDate(geneID);
-        	if (pubDate != null)
-        	{
-        		StmtIterator it2 = model.listStatements(
-        			(Resource) graph.getMapsToStmt().getObject(),
-					AcmePubs.pubDate,
-					(RDFNode) null);
-        		
-        		if (it2.hasNext())
-        		{
-        			Statement s2 = it2.nextStatement();
-        			
-        		}
-        	}
+        	try
+			{
+        		String geneSymbol = s.getString();
+        		List pubDates = CitationDB.getCitations(geneSymbol);
+	        	if (pubDates != null)
+	        	{
+	        		StmtIterator it2 = model.listStatements(
+	        			(Resource) graph.getMapsToStmt().getObject(),
+						AcmePubs.pubDate,
+						(RDFNode) null);
+	        		
+	        		if (it2.hasNext())
+	        		{
+	        			Statement s2 = it2.nextStatement();
+	        		}
+	        	}
+			} catch (Throwable t) {}
         }
     }
     
-    private String getPubDate(String geneID)
-	{
-    	return "";
-    }
-    
     /**
      * Return the last modification date of the description graph file
      */




More information about the MOBY-guts mailing list