[MOBY-guts] biomoby commit
senger@ebi.ac.uk
senger at pub.open-bio.org
Tue Nov 25 13:18:10 UTC 2003
senger
Tue Nov 25 08:18:10 EST 2003
Update of /home/repository/moby/moby-live/Java/src/Clients
In directory pub.open-bio.org:/tmp/cvs-serv19385/src/Clients
Modified Files:
MobyCmdLineClient.java MobyGraphs.java
Log Message:
added buglist for graphs; code cleaning
moby-live/Java/src/Clients MobyCmdLineClient.java,1.2,1.3 MobyGraphs.java,1.2,1.3
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/Clients/MobyCmdLineClient.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- /home/repository/moby/moby-live/Java/src/Clients/MobyCmdLineClient.java 2003/11/24 18:45:25 1.2
+++ /home/repository/moby/moby-live/Java/src/Clients/MobyCmdLineClient.java 2003/11/25 13:18:10 1.3
@@ -175,7 +175,7 @@
if ((param = cmd.getParam ("-ot")) != null ) {
decorationLn ("Service type '" + param + "' is-a:");
decorationLn ("------------");
- System.out.println (StringUtils.join (worker.getServiceTypeRelationships (param),
+ System.out.println (StringUtils.join (worker.getServiceTypeRelationships (param, true),
"\n"));
}
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/Clients/MobyGraphs.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- /home/repository/moby/moby-live/Java/src/Clients/MobyGraphs.java 2003/11/08 00:27:24 1.2
+++ /home/repository/moby/moby-live/Java/src/Clients/MobyGraphs.java 2003/11/25 13:18:10 1.3
@@ -106,6 +106,38 @@
}
//
+ // create a graph with service types
+ //
+ if (cmd.hasOption ("-t")) {
+
+ // get all services types
+ v.clear();
+ decorationLn ("Asking for all service types...");
+ Map types = worker.getServiceTypes();
+ for (Iterator it = types.entrySet().iterator(); it.hasNext(); ) {
+ Map.Entry entry = (Map.Entry)it.next();
+ String typeName = (String)entry.getKey();
+ decorationLn ("Processing service type " + typeName + "...");
+ MobyServiceType serviceType = new MobyServiceType (typeName);
+ serviceType.setDescription ((String)entry.getKey());
+ serviceType.setParentNames (worker.getServiceTypeRelationships (typeName, false));
+ v.addElement (serviceType);
+ }
+ decorationLn ("");
+ MobyServiceType[] serviceTypes = new MobyServiceType [v.size()];
+ v.copyInto (serviceTypes);
+ decorationLn ("Creating a graph of the service types...");
+ String graph = Graphviz.createServiceTypesGraph (serviceTypes, props);
+ param = cmd.getParam ("-ft");
+ if (param == null)
+ param = cmd.getParam ("-f");
+ if (param == null)
+ System.out.println (graph);
+ else
+ createFile (param, graph);
+ }
+
+ //
// create a graph with services
//
if (cmd.hasOption ("-s")) {
More information about the MOBY-guts
mailing list