created Nov 10, 2005 *
This class encapsulates the vocabulary needed to interact with the myGrid ontology. */ @@ -73,6 +74,14 @@ public static final Resource operation; public static final Resource organisation; public static final Resource parameter; + + // unit test predicates + public static final Property hasUnitTest; + public static final Resource unitTest; + public static final Property exampleInput; + public static final Property validOutputXML; + public static final Property validXPath; + public static final Property validREGEX; static { @@ -133,5 +142,13 @@ simpleParameter = m_model.createResource(getURI() + "simpleParameter"); collectionParameter = m_model.createResource(getURI() + "collectionParameter"); secondaryParameter = m_model.createResource(getURI() + "secondaryParameter"); + + //unit test predicates + hasUnitTest = m_model.createProperty(getURI() + "hasUnitTest"); + unitTest = m_model.createResource(getURI() + "unitTest"); + exampleInput = m_model.createProperty(getURI() + "exampleInput"); + validOutputXML = m_model.createProperty(getURI() + "validOutputXML"); + validREGEX = m_model.createProperty(getURI() + "validREGEX"); + validXPath = m_model.createProperty(getURI() + "validXPath"); } } From kawas at dev.open-bio.org Tue Oct 21 12:38:45 2008 From: kawas at dev.open-bio.org (Eddie Kawas) Date: Tue, 21 Oct 2008 12:38:45 -0400 Subject: [MOBY-guts] biomoby commit Message-ID: <200810211638.m9LGcjjL021469@dev.open-bio.org> kawas Tue Oct 21 12:38:44 EDT 2008 Update of /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared In directory dev.open-bio.org:/tmp/cvs-serv21434/src/main/org/biomoby/shared Modified Files: MobyService.java Log Message: committing additions to the class that augment MobyService with unit testing code moby-live/Java/src/main/org/biomoby/shared MobyService.java,1.24,1.25 =================================================================== RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/MobyService.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/MobyService.java 2008/03/02 12:45:26 1.24 +++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/MobyService.java 2008/10/21 16:38:44 1.25 @@ -52,6 +52,8 @@ protected String id = null; protected String lsid = null; protected MobyServiceType serviceType; + // moby unit test object + protected MobyUnitTest unitTest = null; public static final int UNCHECKED = 0; public static final int DEAD= 1; @@ -144,6 +146,8 @@ clone.setSignatureURL(getSignatureURL()); clone.setPathToRDF(getPathToRDF()); clone.setRDF(getRDF()); + clone.setUnitTest(getUnitTest()); + clone.serviceStatus = serviceStatus; clone.statusChecks = statusChecks; for(MobyPrimaryData primary: getPrimaryInputs()){ @@ -265,6 +269,24 @@ } /** + * + * @return the MobyUnitTest object associated with this service + */ + public MobyUnitTest getUnitTest() { + return unitTest; + } + + /** + * + * @param unitTest + * the MobyUnitTest object to associate with this service + */ + public void setUnitTest(MobyUnitTest unitTest) { + if (unitTest != null) + this.unitTest = unitTest; + } + + /** * Return a URL where this service is being served from. It is a * URL where the clients of this service are going when they want * to use it.
@@ -482,6 +504,13 @@ buf.append ("Signature URL: " + signatureURL + "\n"); buf.append ("Path to RDF: " + pathToRDF + "\n"); if (id != null) buf.append ("ID: " + id + "\n"); + + // print unitTest information for this service + if (unitTest != null) { + buf.append(unitTest.toString()); + } else { + buf.append("Unit Test: None available\n"); + } buf.append ("Primary inputs:\n"); for (Enumeration en = primaryInputs.elements(); en.hasMoreElements(); ) From kawas at dev.open-bio.org Tue Oct 21 12:41:23 2008 From: kawas at dev.open-bio.org (Eddie Kawas) Date: Tue, 21 Oct 2008 12:41:23 -0400 Subject: [MOBY-guts] biomoby commit Message-ID: <200810211641.m9LGfNGx021546@dev.open-bio.org> kawas Tue Oct 21 12:41:22 EDT 2008 Update of /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/extended In directory dev.open-bio.org:/tmp/cvs-serv21511/src/main/org/biomoby/shared/extended Modified Files: ServiceInstanceParser.java Log Message: committing additions to the class that augment this class with the ability to parse and set unit testing data for a service moby-live/Java/src/main/org/biomoby/shared/extended ServiceInstanceParser.java,1.24,1.25 =================================================================== RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/extended/ServiceInstanceParser.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/extended/ServiceInstanceParser.java 2008/02/28 17:00:12 1.24 +++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/shared/extended/ServiceInstanceParser.java 2008/10/21 16:41:22 1.25 @@ -18,6 +18,7 @@ import org.biomoby.shared.MobySecondaryData; import org.biomoby.shared.MobyService; import org.biomoby.shared.MobyServiceType; +import org.biomoby.shared.MobyUnitTest; import org.biomoby.shared.Utils; import com.hp.hpl.jena.rdf.model.Model; @@ -35,7 +36,10 @@ /** * - * @author Eddie created Oct 18, 2005 This class parses the RDF document that + * @author Eddie Kawas + * @author Wendy Alexander + * + * created Oct 18, 2005 This class parses the RDF document that * describes the service instance ontology. *
* An example of how to use this class is below: @@ -247,6 +251,21 @@ } } } + + // get/set the unit test information for the service + if (hoResource.hasProperty(FetaVocabulary.hasUnitTest)) { + Resource utResource = hoResource.getProperty(FetaVocabulary.hasUnitTest).getResource(); + MobyUnitTest mut = new MobyUnitTest(); + if (utResource.hasProperty(FetaVocabulary.exampleInput)) + mut.setExampleInput(utResource.getProperty(FetaVocabulary.exampleInput).getObject().toString()); + if (utResource.hasProperty(FetaVocabulary.validOutputXML)) + mut.setValidOutputXML(utResource.getProperty(FetaVocabulary.validOutputXML).getObject().toString()); + if (utResource.hasProperty(FetaVocabulary.validXPath)) + mut.setValidXPath(utResource.getProperty(FetaVocabulary.validXPath).getObject().toString()); + if (utResource.hasProperty(FetaVocabulary.validREGEX)) + mut.setValidREGEX(utResource.getProperty(FetaVocabulary.validREGEX).getObject().toString()); + service.setUnitTest(mut); + } } From senger at dev.open-bio.org Thu Oct 23 20:36:27 2008 From: senger at dev.open-bio.org (Martin Senger) Date: Thu, 23 Oct 2008 20:36:27 -0400 Subject: [MOBY-guts] biomoby commit Message-ID: <200810240036.m9O0aRtu030851@dev.open-bio.org> senger Thu Oct 23 20:36:27 EDT 2008 Update of /home/repository/moby/moby-live/Java/docs In directory dev.open-bio.org:/tmp/cvs-serv30832/docs Modified Files: index.html Added Files: LICENSE Log Message: added licensing into the documentation moby-live/Java/docs LICENSE,NONE,1.1 index.html,1.33,1.34 =================================================================== RCS file: /home/repository/moby/moby-live/Java/docs/index.html,v retrieving revision 1.33 retrieving revision 1.34 diff -u -r1.33 -r1.34 --- /home/repository/moby/moby-live/Java/docs/index.html 2008/05/21 19:18:22 1.33 +++ /home/repository/moby/moby-live/Java/docs/index.html 2008/10/24 00:36:27 1.34 @@ -73,6 +73,12 @@
+
@@ -225,7 +231,7 @@