[MOBY-guts] biomoby commit

Eddie Kawas kawas at pub.open-bio.org
Mon Dec 20 17:13:34 UTC 2004


kawas
Mon Dec 20 12:13:34 EST 2004
Update of /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool
In directory pub.open-bio.org:/tmp/cvs-serv13136/org/biomoby/client/gui/serviceInstanceCreationTool

Modified Files:
	TreeListener.java ServiceInstancePanelFactory.java 
	NamespaceTree.java ServiceTypeTree.java 
Log Message:
Added/Modified documentation

moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool TreeListener.java,1.1,1.2 ServiceInstancePanelFactory.java,1.4,1.5 NamespaceTree.java,1.1,1.2 ServiceTypeTree.java,1.1,1.2
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/TreeListener.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/TreeListener.java	2004/09/27 21:29:15	1.1
+++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/TreeListener.java	2004/12/20 17:13:34	1.2
@@ -36,7 +36,7 @@
 	 * POST: the tree listener is initialized.
 	 * </p>
 	 * 
-	 * @param tool
+	 * @param tool - the ServiceCreationTool that registered this listener.
 	 */
 	public TreeListener(ServiceCreationTool tool) {
 		this.tool = tool;

===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceInstancePanelFactory.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceInstancePanelFactory.java	2004/12/18 19:00:55	1.4
+++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceInstancePanelFactory.java	2004/12/20 17:13:34	1.5
@@ -92,9 +92,6 @@
 			}
 		};
 		worker.start();
-		// before doing anything, load the service tree in a
-		// separate thread to increase performance
-		// also download the object tree for use
 		final TreeLoaderThread workerTree = new TreeLoaderThread() {
 			public Object construct() {
 				mobyTree = new MobyTree(false,
@@ -106,10 +103,6 @@
 			}
 		};
 		workerTree.start();
-
-		//		before doing anything, load the service tree in a
-		// separate thread to increase performance
-		// also download the object tree for use
 		final TreeLoaderThread workerNamespace = new TreeLoaderThread() {
 			public Object construct() {
 				namespaceTree = new NamespaceTree(false,
@@ -123,6 +116,12 @@
 		workerNamespace.start();
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>The starting panel for the applet is returned.<p>
+	 * @return - the starting panel for the applet is returned.
+	 */
 	public JPanel createStartingPanel() {
 
 		/* all tabs go to the center of this panel */
@@ -372,6 +371,12 @@
 		return pan;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>The add inputs/outputs panel is created for the applet.<p>
+	 * @return - a JPanel representing the input/output chooser for the applet.
+	 */
 	public JPanel createChoosingPanel() {
 		/* all tabs go to the center of this panel */
 		JPanel pan = null;
@@ -447,6 +452,14 @@
 		return pan;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>Top and bottom are valid JPanels.<p>
+	 * <b>POST:</b>a JSplitPane is created with top placed at the top of the panel and bottom placed at the bottom<p>
+	 * @param top - a JPanel that will be the top component of the split pane.
+	 * @param bottom - a JPanel that will be the bottom component of the split pane.
+	 * @return - a JSplitPane with the top and bottom components initialized to top and bottom.
+	 */
 	public JSplitPane createSplitePane(JPanel top, JPanel bottom) {
 		JSplitPane vpane = new JSplitPane(JSplitPane.VERTICAL_SPLIT, top,
 				bottom);
@@ -455,6 +468,11 @@
 		return vpane;
 	}
 
+	/** 
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>A JPanel containing the service type tree is returned.<p>
+	 * @return - a JPanel containing the service type tree.
+	 */
 	public JPanel createServiceTypeChooserPanel() {
 		JPanel panel = null;
 		panel = initPanel(panel, "<html><B>Choose the Service Type</B></html>",
@@ -489,6 +507,14 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>dataTypeName is found in the mobycentral object ontology.<p>
+	 * <b>POST:</b>A JPanel containing the information of the recently chosen datatype, along with a namespace tree so that user can choose appropriate namespaces for their input/output.<p>
+	 * @param dataTypeName - a string name of a valid object in the moby object ontology.
+	 * @param isInput - if isInput is true, then datatype is a primary input. Otherwise the datatype is an output.
+	 * @return - a JPanel containing information on the datatype, as well as other widgets that aid in the supplementing of the input/output object.
+	 */
 	public JPanel createSimplePrimaryPanel(String dataTypeName, boolean isInput) {
 		JPanel panel = null;
 		panel = initPanel(panel, "<html><b>"
@@ -609,6 +635,15 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>datatype name is found in the moby object ontology.<p>
+	 * <b>POST:</b>a JPanel is returned that allows the user to add more information on the object contained in their collection<p>
+	 * @param dataTypeName - a valid object name found in the moby object ontology.
+	 * @param isInput - if true, then collection (and object contained in collection) is an input, otherwise the collection is an output.
+	 * @param collectionName - the name of the collection.
+	 * @return - a JPanel with widgets that allow for the user to supplement the information on the collection.
+	 */
 	public JPanel createCollectionPrimaryPanel(String dataTypeName,
 			boolean isInput, String collectionName) {
 		JPanel panel = null;
@@ -764,6 +799,12 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>a JPanel containing an object tree that allows for object additions to the users current collection is returned<p>
+	 * @return - JPanel with an object tree allowing for the addition of the selected object to the users collection.
+	 */
 	public JPanel createObjectTreePanelForAddingToCollections() {
 		JPanel panel = null;
 		panel = initPanel(
@@ -850,6 +891,12 @@
 		return p;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>An empty JPanel is returned.<p>
+	 * @return - a JPanel with nothing contained within.
+	 */
 	public JPanel createEmptyPanel() {
 		JPanel p = null;
 		p = initPanel(p, "empty", -1);
@@ -857,6 +904,12 @@
 		return p;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None<p>
+	 * <b>POST:</b>A JPanel containing information about the users service is shown.<p>
+	 * @return - JPanel with information on the users service.
+	 */
 	public JPanel createServiceViewPanel() {
 		JPanel panel = null;
 		panel = initPanel(panel, "<html><b>Service View</b></html>", -1);
@@ -884,6 +937,12 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>An object is selected in the object tree.<p>
+	 * <b>POST:</b>Information about the selected object is returned.<p>
+	 * @return - JPanel with information on the selected moby object.
+	 */
 	public JPanel createObjectViewPanel() {
 		String name = objectTreeListener.getSelectedNode();
 		JPanel panel = null;
@@ -913,6 +972,12 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>JPanel with information and widgets that allow the user to supplement their collection is returned.<p>
+	 * @return - JPanel with information fields and widgets that allow the user to supplement their collection.
+	 */
 	public JPanel createObjectViewPanelForCollection() {
 		String name = objectTreeListener.getSelectedNode();
 		JPanel panel = null;
@@ -942,6 +1007,12 @@
 		return panel;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>JPanel displaying a tree of the moby object ontology is returned that aids in the addition of objects to the service.<p>
+	 * @return JPanel containing a tree representation of the moby object ontology.
+	 */
 	public JPanel createObjectTreePanel() {
 		JPanel panel = null;
 		panel = initPanel(panel, "<html><B>Choose an Object</B></html>", -1);
@@ -980,72 +1051,81 @@
 	}
 
 	/**
-	 * @return
+	 * @return true if a radio button is selected, false otherwise.
 	 */
 	public boolean isRADIO_SELECTED() {
 		return RADIO_SELECTED;
 	}
 
 	/**
-	 * @param b
+	 * @param b - set whether or not the radio button is selected.
 	 */
 	public void setRADIO_SELECTED(boolean b) {
 		RADIO_SELECTED = b;
 	}
 
 	/**
-	 * @return
+	 * @return - return the service type tree.
 	 */
 	public ServiceTypeTree getTree() {
 		return tree;
 	}
 
 	/**
-	 * @param tree
+	 * @param tree - the tree to set the service type tree to.
 	 */
 	public void setTree(ServiceTypeTree tree) {
 		this.tree = tree;
 	}
 
 	/**
-	 * @return
+	 * @return - the TreeListener registered to this tool
 	 */
 	public TreeListener getMouseTreeListener() {
 		return mtl;
 	}
 
 	/**
-	 * @return
+	 * @return - the moby tree registered to this tool.
 	 */
 	public MobyTree getMobyTree() {
 		return mobyTree;
 	}
 
 	/**
-	 * @return
+	 * @return - the namespace tree.
 	 */
 	public NamespaceTree getNamespaceTree() {
 		return namespaceTree;
 	}
 
 	/**
-	 * @return
+	 * @return - the listener associated with the namespace tree registered with this tool.
 	 */
 	public NamespaceListener getNamespaceListener() {
 		return ntl;
 	}
 
 	/**
-	 * @return
+	 * @return - DefaultListModel for the namespace dropdown list.
 	 */
 	public DefaultListModel getNamespaceDropdownListModel() {
 		return model;
 	}
 
+	/**
+	 * @return - the size of the namespace dropdown list.
+	 */
 	public int getNamespaceDropdownListSize() {
 		return namespaceDropdownList.getModel().getSize();
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>JPanel with widgets required to add secondary input to the service instance is returned.<p>
+	 * @return - JPanel with various widgets that allow for the addition of secondary inputs to the service instance.
+	 */
 	public JPanel createSecondaryPanel() {
 		JPanel panel = null;
 		panel = initPanel(panel, "<html><b>Secondary Input Entry", -1);
@@ -1138,6 +1218,9 @@
 		return panel;
 	}
 
+	/**
+	 * @return - an Enumeration of secondary data valid inputs
+	 */
 	public Enumeration getSecondaryInputEnumeration() {
 		Vector vec = new Vector();
 		StringTokenizer st = new StringTokenizer(InputOutputFocusListener
@@ -1153,14 +1236,26 @@
 		return vec.elements();
 	}
 
+	/**
+	 * @return - the secondary input datatype - Can be INTEGER, STRING, DATETIME or FLOAT
+	 */
 	public static String getSecondaryDataType() {
 		return ServiceInstancePanelFactory.datatype;
 	}
 
+	/**
+	 * @param datatype - the secondary input datatype - INTEGER, STRING, DATETIME, or FLOAT
+	 */
 	public static void setSecondaryDataType(String datatype) {
 		ServiceInstancePanelFactory.datatype = datatype;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>JPanel that displays the service instance is returned.<p>
+	 * @return - JPanel that initiates submission of the service instance.
+	 */
 	public JPanel createSubmissionPanel() {
 		JPanel panel = null;
 		panel = initPanel(
@@ -1200,12 +1295,18 @@
 	}
 
 	/**
-	 * @return
+	 * @return - the submit JButton.
 	 */
 	public JButton getSubmit() {
 		return submit;
 	}
 
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>JPanel with various widgets for editing the details of the service instance is returned.<p>
+	 * @return - JPanel is returned that aids in the editing of the service instance details.
+	 */
 	public JPanel createDetailEditingPanel() {
 
 		/* all tabs go to the center of this panel */
@@ -1438,7 +1539,7 @@
 	}
 
 	/**
-	 * @return
+	 * @return - the edit JButton
 	 */
 	public JButton getEdit() {
 		return edit;

===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/NamespaceTree.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/NamespaceTree.java	2004/09/27 21:29:15	1.1
+++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/NamespaceTree.java	2004/12/20 17:13:34	1.2
@@ -40,9 +40,9 @@
 	private String rdf = "";
 	/**
 	 * PRE: None<p>
-	 * POST: A moby tree is constructed with the root node labeled as 'Service'<p>
+	 * POST: A moby tree is constructed with the root node labeled as 'Namespace'<p>
 	 * and the material for the tree taken from the RDF located at 
-	 * @link http://biomoby.org/RESOURCES/MOBY-S/Service
+	 * @link http://biomoby.org/RESOURCES/MOBY-S/Namespace
 	 * @param canEdit, if true, then the nodes are editable, else they are not.
 	 */
 	public NamespaceTree(boolean canEdit, String rdf) {
@@ -84,7 +84,7 @@
 
 	/**
 	 * PRE: None.<p>
-	 * POST: The MobyTree object contains an empty tree with a single node labeled 'Object'
+	 * POST: The MobyTree Namespace contains an empty tree with a single node labeled 'Namespace'
 	 * @return - none.
 	 *
 	 */
@@ -294,6 +294,12 @@
 		return tree;
 	}
 	
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>THe Namespace tree is refreshed.<p>
+	 *
+	 */
 	public void reload() {
 		hashmap = new Construct(rdf).createHomes();
 		makeObjectTree();

===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceTypeTree.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceTypeTree.java	2004/09/27 21:29:15	1.1
+++ /home/repository/moby/moby-live/Java/src/main/org/biomoby/client/gui/serviceInstanceCreationTool/ServiceTypeTree.java	2004/12/20 17:13:34	1.2
@@ -298,6 +298,12 @@
 		return tree;
 	}
 	
+	/**
+	 *  
+	 * <b>PRE:</b>None.<p>
+	 * <b>POST:</b>The Service Type tree for this tool is refreshed.<p>
+	 *
+	 */
 	public void reload() {
 		hashmap = new Construct(rdf).createHomes();
 		makeObjectTree();




More information about the MOBY-guts mailing list