Author: rodche
Date: 2011-10-26 14:44:32 -0700 (Wed, 26 Oct 2011)
New Revision: 27312
Removed:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathPlugIn2.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/TreeDemo.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathResponseFormat.java
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPath2Factory.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathNetworkImportTask.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathId.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathIdTaskFactory.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/DownloadDetails.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/GuiUtils.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/SearchDetailsPanel.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathCytoscapeWebService.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathWebService.java
Log:
Re-factoring...
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPath2Factory.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPath2Factory.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPath2Factory.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -21,7 +21,6 @@
import org.cytoscape.cpathsquared.internal.view.SearchBoxPanel;
import org.cytoscape.cpathsquared.internal.view.SearchDetailsPanel;
import org.cytoscape.cpathsquared.internal.view.SearchHitsPanel;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.io.read.CyNetworkReaderManager;
import org.cytoscape.model.CyNetwork;
@@ -35,6 +34,7 @@
import org.cytoscape.work.TaskManager;
import org.cytoscape.work.undo.UndoSupport;
+import cpath.service.OutputFormat;
import cpath.service.jaxb.SearchHit;
// TODO: This is a "God" object. Probably shouldn't exist, but it's better
than having to
@@ -78,8 +78,10 @@
}
public ExecuteGetRecordByCPathIdTaskFactory
createExecuteGetRecordByCPathIdTaskFactory(
- CPathWebService webApi, String[] ids,
CPathResponseFormat format, String title) {
- return new ExecuteGetRecordByCPathIdTaskFactory(webApi, ids,
format, title, this, bpContainer, mapperFactory, networkListener,
mappingManager);
+ CPathWebService webApi, String[] ids, OutputFormat
format, String title)
+ {
+ return new ExecuteGetRecordByCPathIdTaskFactory(webApi, ids,
format, title,
+ this, bpContainer, mapperFactory, networkListener,
mappingManager);
}
public SearchBoxPanel createSearchBoxPanel(CPathWebService webApi) {
@@ -160,7 +162,7 @@
return undoSupport;
}
- public CPathNetworkImportTask createCPathNetworkImportTask(String
query, CPathWebService client, CPathResponseFormat format) {
+ public CPathNetworkImportTask createCPathNetworkImportTask(String
query, CPathWebService client, OutputFormat format) {
return new CPathNetworkImportTask(query, client, format, this);
}
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathNetworkImportTask.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathNetworkImportTask.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathNetworkImportTask.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -2,20 +2,21 @@
import
org.cytoscape.cpathsquared.internal.task.ExecuteGetRecordByCPathIdTaskFactory;
import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.work.Task;
import org.cytoscape.work.TaskIterator;
import org.cytoscape.work.TaskMonitor;
+import cpath.service.OutputFormat;
+
public class CPathNetworkImportTask implements Task {
private final String query;
private final CPathWebService client;
- private final CPathResponseFormat format;
+ private final OutputFormat format;
private final CPath2Factory factory;
- public CPathNetworkImportTask(String query, CPathWebService client,
CPathResponseFormat format, CPath2Factory factory) {
+ public CPathNetworkImportTask(String query, CPathWebService client,
OutputFormat format, CPath2Factory factory) {
this.query = query;
this.client = client;
this.format = format;
@@ -30,15 +31,9 @@
ids[i] = idStrs[i].trim();
}
-// ModuleProperties properties = this.getProps();
-// Tunable tunable = properties.get(RESPONSE_FORMAT);
-// CPathResponseFormat format = CPathResponseFormat.BINARY_SIF;
-// if (tunable != null) {
-// format = CPathResponseFormat.getResponseFormat((String)
tunable.getValue());
-// }
-
// Create the task
- ExecuteGetRecordByCPathIdTaskFactory taskFactory =
factory.createExecuteGetRecordByCPathIdTaskFactory(client, ids, format,
CPathProperties.serverName);
+ ExecuteGetRecordByCPathIdTaskFactory taskFactory = factory
+ .createExecuteGetRecordByCPathIdTaskFactory(client, ids,
format, CPathProperties.serverName);
TaskIterator iterator = taskFactory.getTaskIterator();
while (iterator.hasNext()) {
Task task = iterator.next();
Deleted:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathPlugIn2.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathPlugIn2.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathPlugIn2.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -1,140 +0,0 @@
-// $Id: CPathPlugIn2.java,v 1.8 2007/04/27 19:18:48 grossb Exp $
-//------------------------------------------------------------------------------
-/** Copyright (c) 2007 Memorial Sloan-Kettering Cancer Center.
- **
- ** Code written by: Ethan Cerami, Benjamin Gross
- ** Authors: Ethan Cerami, Gary Bader, Chris Sander, Benjamin Gross
- **
- ** This library is free software; you can redistribute it and/or modify it
- ** under the terms of the GNU Lesser General Public License as published
- ** by the Free Software Foundation; either version 2.1 of the License, or
- ** any later version.
- **
- ** This library is distributed in the hope that it will be useful, but
- ** WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF
- ** MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. The software and
- ** documentation provided hereunder is on an "as is" basis, and
- ** Memorial Sloan-Kettering Cancer Center
- ** has no obligations to provide maintenance, support,
- ** updates, enhancements or modifications. In no event shall
- ** Memorial Sloan-Kettering Cancer Center
- ** be liable to any party for direct, indirect, special,
- ** incidental or consequential damages, including lost profits, arising
- ** out of the use of this software and its documentation, even if
- ** Memorial Sloan-Kettering Cancer Center
- ** has been advised of the possibility of such damage. See
- ** the GNU Lesser General Public License for more details.
- **
- ** You should have received a copy of the GNU Lesser General Public License
- ** along with this library; if not, write to the Free Software Foundation,
- ** Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
- **/
-package org.cytoscape.cpathsquared.internal;
-
-// imports
-
-import java.awt.Font;
-import java.awt.GridBagConstraints;
-import java.awt.GridBagLayout;
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.io.IOException;
-
-import javax.swing.ButtonGroup;
-import javax.swing.JPanel;
-import javax.swing.JRadioButton;
-import javax.swing.JScrollPane;
-import javax.swing.JTextArea;
-import javax.swing.border.EmptyBorder;
-import javax.swing.border.TitledBorder;
-
-import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
-
-/**
- * The cPath plugin class. It gets called by Cytoscape's plugin manager
- * to install inself. The main job of this guy is to instantiate our http
server.
- *
- * @author Benjamin Gross.
- */
-public class CPathPlugIn2 {
-
- /**
- * Constructor.
- */
- public CPathPlugIn2(CPath2Factory factory) throws IOException {
- }
-
- public static JScrollPane createConfigPanel() {
- JPanel configPanel = new JPanel();
- configPanel.setBorder(new TitledBorder("Retrieval Options"));
- configPanel.setLayout(new GridBagLayout());
- GridBagConstraints c = new GridBagConstraints();
- final JRadioButton button1 = new JRadioButton("Full Model");
-
- JTextArea textArea1 = new JTextArea();
- textArea1.setLineWrap(true);
- textArea1.setWrapStyleWord(true);
- textArea1.setEditable(false);
- textArea1.setOpaque(false);
- Font font = textArea1.getFont();
- Font smallerFont = new Font(font.getFamily(), font.getStyle(),
font.getSize() - 2);
- textArea1.setFont(smallerFont);
- textArea1.setText("Retrieve the full model, as stored in the original
BioPAX "
- + "representation. In this representation, nodes within a
network can "
- + "refer to physical entities and interactions.");
- textArea1.setBorder(new EmptyBorder(5, 20, 0, 0));
-
- JTextArea textArea2 = new JTextArea(3, 20);
- textArea2.setLineWrap(true);
- textArea2.setWrapStyleWord(true);
- textArea2.setEditable(false);
- textArea2.setOpaque(false);
- textArea2.setFont(smallerFont);
- textArea2.setText("Retrieve a simplified binary network, as inferred
from the original "
- + "BioPAX representation. In this representation, nodes
within a network refer "
- + "to physical entities only, and edges refer to inferred
interactions.");
- textArea2.setBorder(new EmptyBorder(5, 20, 0, 0));
-
-
- final JRadioButton button2 = new JRadioButton("Simplified Binary
Model");
- button2.setSelected(true);
- ButtonGroup group = new ButtonGroup();
- group.add(button1);
- group.add(button2);
-
- c.fill = GridBagConstraints.HORIZONTAL;
- c.weightx = 1.0;
-
- c.gridx = 0;
- c.gridy = 0;
- configPanel.add(button2, c);
-
- c.gridy = 1;
- configPanel.add(textArea2, c);
-
- c.gridy = 2;
- configPanel.add(button1, c);
-
- c.gridy = 3;
- configPanel.add(textArea1, c);
-
- // Add invisible filler to take up all remaining space
- c.gridy = 4;
- c.weighty = 1.0;
- JPanel panel = new JPanel();
- configPanel.add(panel, c);
-
- button1.addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent actionEvent) {
- CPathProperties.downloadMode =
CPathProperties.DOWNLOAD_FULL_BIOPAX;
- }
- });
- button2.addActionListener(new ActionListener() {
- public void actionPerformed(ActionEvent actionEvent) {
- CPathProperties.downloadMode =
CPathProperties.DOWNLOAD_REDUCED_BINARY_SIF;
- }
- });
- JScrollPane scrollPane = new JScrollPane(configPanel);
- return scrollPane;
- }
-}
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathId.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathId.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathId.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -6,35 +6,29 @@
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
-import java.util.HashSet;
import java.util.List;
import java.util.Map;
-import java.util.Set;
-import javax.swing.JOptionPane;
import javax.swing.SwingUtilities;
import org.biopax.paxtools.io.SimpleIOHandler;
import org.biopax.paxtools.model.BioPAXElement;
import org.biopax.paxtools.model.Model;
+import org.biopax.paxtools.model.level3.Complex;
+import org.biopax.paxtools.model.level3.EntityReference;
import org.biopax.paxtools.model.level3.PhysicalEntity;
import org.cytoscape.biopax.BioPaxContainer;
import org.cytoscape.biopax.MapBioPaxToCytoscape;
import org.cytoscape.biopax.MapBioPaxToCytoscapeFactory;
import org.cytoscape.biopax.NetworkListener;
-import org.cytoscape.biopax.util.BioPaxUtil;
-import org.cytoscape.biopax.util.BioPaxVisualStyleUtil;
import org.cytoscape.cpathsquared.internal.CPath2Factory;
import org.cytoscape.cpathsquared.internal.util.AttributeUtil;
import org.cytoscape.cpathsquared.internal.util.BinarySifVisualStyleUtil;
-import org.cytoscape.cpathsquared.internal.util.SelectUtil;
import org.cytoscape.cpathsquared.internal.webservice.CPathException;
import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.cpathsquared.internal.webservice.EmptySetException;
import org.cytoscape.io.read.CyNetworkReader;
-import org.cytoscape.model.CyEdge;
import org.cytoscape.model.CyNetwork;
import org.cytoscape.model.CyNode;
import org.cytoscape.model.CyRow;
@@ -51,6 +45,8 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
+import cpath.service.OutputFormat;
+
/**
* Controller for Executing a Get Record(s) by CPath ID(s) command.
*
@@ -61,8 +57,7 @@
private String ids[];
private String networkTitle;
private boolean haltFlag = false;
- private CyNetwork mergedNetwork;
- private CPathResponseFormat format;
+ private OutputFormat format;
private final static String CPATH_SERVER_NAME_ATTRIBUTE =
"CPATH_SERVER_NAME";
private final static String CPATH_SERVER_DETAILS_URL =
"CPATH_SERVER_DETAILS_URL";
private Logger logger =
LoggerFactory.getLogger(ExecuteGetRecordByCPathId.class);
@@ -86,7 +81,7 @@
* @param bpContainer
* @param application
*/
- public ExecuteGetRecordByCPathId(CPathWebService webApi, String[] ids,
CPathResponseFormat format,
+ public ExecuteGetRecordByCPathId(CPathWebService webApi, String[] ids,
OutputFormat format,
String networkTitle, CPath2Factory cPathFactory,
BioPaxContainer bpContainer,
MapBioPaxToCytoscapeFactory mapperFactory,
NetworkListener networkListener, VisualMappingManager mappingManager) {
this.webApi = webApi;
@@ -101,39 +96,6 @@
}
/**
- * Constructor.
- *
- * @param webApi
- * cPath Web API.
- * @param ids
- * Array of cPath IDs.
- * @param format
- * CPathResponseFormat Object.
- * @param networkTitle
- * Tentative Network Title.
- * @param mergedNetwork
- * Network to merge into.
- * @param mapperFactory
- * @param mapBioPaxToCytoscape
- * @param viewManager
- * @param application
- */
- public ExecuteGetRecordByCPathId(CPathWebService webApi, String[] ids,
CPathResponseFormat format,
- String networkTitle, CyNetwork mergedNetwork,
CPath2Factory cPathFactory, BioPaxContainer bpContainer,
- MapBioPaxToCytoscapeFactory mapperFactory,
NetworkListener networkListener, VisualMappingManager mappingManager) {
- this.webApi = webApi;
- this.ids = ids;
- this.format = format;
- this.networkTitle = networkTitle;
- this.mergedNetwork = mergedNetwork;
- this.cPathFactory = cPathFactory;
- this.bpContainer = bpContainer;
- this.mapperFactory = mapperFactory;
- this.networkListener = networkListener;
- this.mappingManager = mappingManager;
- }
-
- /**
* Our implementation of Task.abort()
*/
public void cancel() {
@@ -170,7 +132,7 @@
String tmpDir = System.getProperty("java.io.tmpdir");
// Branch based on download mode setting.
File tmpFile;
- if (format == CPathResponseFormat.BIOPAX) {
+ if (format == OutputFormat.BIOPAX) {
tmpFile = File.createTempFile("temp", ".xml",
new File(tmpDir));
} else {
tmpFile = File.createTempFile("temp", ".sif",
new File(tmpDir));
@@ -209,30 +171,13 @@
cPathFactory.getCyNetworkViewManager().addNetworkView(view);
// Branch, based on download mode.
- if (format == CPathResponseFormat.BINARY_SIF) {
+ //TODO add EXTENDED_BINARY_SIF
+ if (format == OutputFormat.BINARY_SIF) {
postProcessingBinarySif(view, taskMonitor);
} else {
postProcessingBioPAX(view, taskMonitor);
}
- // Fire appropriate network event.
- // TODO: Port this?
- // if (mergedNetwork == null) {
- // // Fire a Network Loaded Event
- // Object[] ret_val = new Object[2];
- // ret_val[0] = cyNetwork;
- // ret_val[1] = networkTitle;
- //
Cytoscape.firePropertyChange(Cytoscape.NETWORK_LOADED, null,
- // ret_val);
- // } else {
- // // Fire a Network Modified Event; causes Quick Find
to Re-Index.
- // Object[] ret_val = new Object[2];
- // ret_val[0] = mergedNetwork;
- // ret_val[1] = networkTitle;
- //
Cytoscape.firePropertyChange(Cytoscape.NETWORK_MODIFIED, null,
- // ret_val);
- // }
-
// Add Links Back to cPath Instance
addLinksToCPathInstance(cyNetwork);
@@ -300,44 +245,26 @@
getNodeDetails(cyNetwork, taskMonitor);
if (haltFlag == false) {
- if (mergedNetwork != null) {
- mergeNetworks(cyNetwork, taskMonitor);
- } else {
- // } else if (cyNetwork.getNodeCount() <
- //
Integer.parseInt(CytoscapeInit.getProperties()
- // .getProperty("viewThreshold"))) {
- if (taskMonitor != null) {
- taskMonitor.setStatusMessage("Creating
Network View...");
- taskMonitor.setProgress(0);
- }
+ if (taskMonitor != null) {
+ taskMonitor.setStatusMessage("Creating Network
View...");
+ taskMonitor.setProgress(0);
+ }
- // Set up the right layout algorithm.
- // LayoutUtil layoutAlgorithm = new
LayoutUtil();
+ VisualStyle visualStyle = cPathFactory
+
.getBinarySifVisualStyleUtil().getVisualStyle();
+ mappingManager.setVisualStyle(visualStyle, view);
+ networkListener.registerNetwork(view);
- // Now, create the view.
- // Use local create view option, so that we
don't mess up the
- // visual style.
- // final CyNetworkView view = createNetworkView
- // (cyNetwork,
cyNetwork.getCyRow().get(CyNetwork.NAME,
- // String.class), layoutAlgorithm, null);
-
- VisualStyle visualStyle =
cPathFactory.getBinarySifVisualStyleUtil().getVisualStyle();
- mappingManager.setVisualStyle(visualStyle,
view);
- networkListener.registerNetwork(view);
-
- SwingUtilities.invokeLater(new Runnable() {
- public void run() {
- //
CytoscapeWrapper.activateBioPaxPlugInTab(bpContainer);
- bpContainer.showLegend();
- // view.fitContent();
- String
networkTitleWithUnderscores = networkTitle.replaceAll(": ", "");
- networkTitleWithUnderscores =
networkTitleWithUnderscores.replaceAll(" ", "_");
- CyNetworkNaming naming =
cPathFactory.getCyNetworkNaming();
- networkTitleWithUnderscores =
naming.getSuggestedNetworkTitle(networkTitleWithUnderscores);
- AttributeUtil.set(cyNetwork,
CyNetwork.NAME, networkTitleWithUnderscores, String.class);
- }
- });
- }
+ SwingUtilities.invokeLater(new Runnable() {
+ public void run() {
+ bpContainer.showLegend();
+ String networkTitleWithUnderscores =
networkTitle.replaceAll(": ", "");
+ networkTitleWithUnderscores =
networkTitleWithUnderscores.replaceAll(" ", "_");
+ CyNetworkNaming naming =
cPathFactory.getCyNetworkNaming();
+ networkTitleWithUnderscores =
naming.getSuggestedNetworkTitle(networkTitleWithUnderscores);
+ AttributeUtil.set(cyNetwork,
CyNetwork.NAME, networkTitleWithUnderscores, String.class);
+ }
+ });
} else {
// If we have requested a halt, and we have a network,
destroy it.
// if (cyNetwork != null) {
@@ -346,120 +273,19 @@
}
}
- /**
- * Execute Post-Processing on BioPAX Network.
- *
- * @param cyNetwork
- * Cytoscape Network Object.
- */
+
+ //TODO may be remove this method
private void postProcessingBioPAX(final CyNetworkView view, TaskMonitor
taskMonitor) {
final CyNetwork cyNetwork = view.getModel();
-
if (haltFlag == false) {
- if (mergedNetwork != null) {
- mergeNetworks(cyNetwork, taskMonitor);
- } else {
- // } else if (cyNetwork.getNodeCount() <
- //
Integer.parseInt(CytoscapeInit.getProperties()
- // .getProperty("viewThreshold"))) {
- if (taskMonitor != null) {
- taskMonitor.setStatusMessage("Creating
Network View...");
- taskMonitor.setProgress(0);
- }
-
- // Set up the right visual style
- // VisualStyle visualStyle =
- // BioPaxVisualStyleUtil.getBioPaxVisualStyle();
-
- // Set up the right layout algorithm.
- // LayoutUtil layoutAlgorithm = new
LayoutUtil();
-
- // Now, create the view.
- // Use local create view option, so that we
don't mess up the
- // visual style.
- // CyNetworkView view =
createNetworkView(cyNetwork,
- // cyNetwork.getCyRow().get(CyNetwork.NAME,
String.class),
- // layoutAlgorithm, null);
-
- // Now apply the visual style;
- // Doing this as a separate step ensures that
the visual style
- // appears
- // in the visual style drop-down menu.
- // view.applyVizmapper(visualStyle);
+ if (taskMonitor != null) {
+ taskMonitor.setStatusMessage("Creating Network
View...");
+ taskMonitor.setProgress(0);
}
} else {
- // If we have requested a halt, and we have a network,
destroy it.
- // TODO: Review: Network hasn't been added to manager
at this point
- // so we don't need to do the following, right?
- // if (cyNetwork != null) {
- // Cytoscape.destroyNetwork(cyNetwork);
- // }
}
}
- private void mergeNetworks(CyNetwork cyNetwork, TaskMonitor
taskMonitor) {
- // TODO: Do we need to clone nodes/edges when merging?
- taskMonitor.setStatusMessage("Merging Network...");
- Map<String, CyNode> nodes = new HashMap<String, CyNode>();
- for (CyNode node : cyNetwork.getNodeList()) {
- CyNode newNode = mergedNetwork.addNode();
- AttributeUtil.copyAttributes(node, newNode);
- String name = node.getCyRow().get(CyNode.NAME,
String.class);
- nodes.put(name, newNode);
- }
- Set<CyEdge> edges = new HashSet<CyEdge>();
- for (CyEdge edge : cyNetwork.getEdgeList()) {
- String sourceName =
edge.getSource().getCyRow().get(CyNode.NAME, String.class);
- String targetName =
edge.getTarget().getCyRow().get(CyNode.NAME, String.class);
- CyNode source = nodes.get(sourceName);
- CyNode target = nodes.get(targetName);
- CyEdge newEdge = mergedNetwork.addEdge(source, target,
true);
- AttributeUtil.copyAttributes(edge, newEdge);
- edges.add(newEdge);
- }
-
- // // Select this view
- // final CyNetworkView networkView =
- // viewManager.getNetworkView((mergedNetwork.getSUID());
- // Cytoscape.setCurrentNetwork(mergedNetwork.getIdentifier());
- //
Cytoscape.setCurrentNetworkView(mergedNetwork.getIdentifier());
-
- // final BioPaxContainer bpContainer =
BioPaxContainer.getInstance();
- SwingUtilities.invokeLater(new Runnable() {
- public void run() {
- //
CytoscapeWrapper.activateBioPaxPlugInTab(bpContainer);
- bpContainer.showLegend();
- // VisualMappingManager vizmapper =
- // Cytoscape.getVisualMappingManager();
- // vizmapper.applyAppearances();
- }
- });
-
- // Select only the new nodes
- SelectUtil.unselectAllNodes(mergedNetwork);
- SelectUtil.unselectAllEdges(mergedNetwork);
- SelectUtil.setSelectedNodeState(nodes.values(), true);
- SelectUtil.setSelectedEdgeState(edges, true);
-
- // Delete the temp network.
- // Cytoscape.destroyNetwork(cyNetwork);
-
- // Apply Layout
- Object[] options = { "Yes", "No" };
- int n =
JOptionPane.showOptionDialog(cPathFactory.getCySwingApplication().getJFrame(),
- "Would you like to layout the modified
network?", "Adjust Layout?", JOptionPane.YES_NO_CANCEL_OPTION,
- JOptionPane.QUESTION_MESSAGE, null, options,
options[0]);
- if (n == 0) {
- // SwingUtilities.invokeLater(new Runnable() {
- // public void run() {
- // LayoutUtil layoutAlgorithm = new LayoutUtil();
- // networkView.applyLayout(layoutAlgorithm);
- // networkView.fitContent();
- // }
- // });
- }
- }
-
/**
* Gets Details for Each Node from Web Service API.
*/
@@ -472,7 +298,7 @@
if (batchList.size() == 0) {
logger.info("Skipping node details. Already have all
the details new need.");
}
- MapBioPaxToCytoscape mapBioPaxToCytoscape =
mapperFactory.getInstance(cyNetwork, taskMonitor);
+ MapBioPaxToCytoscape mapBioPaxToCytoscape =
mapperFactory.getInstance(null, taskMonitor);
for (int i = 0; i < batchList.size(); i++) {
if (haltFlag == true) {
break;
@@ -488,22 +314,24 @@
ids[j] = name;
}
try {
- final String xml = webApi.getRecordsByIds(ids,
CPathResponseFormat.BIOPAX, new NullTaskMonitor());
+ final String xml = webApi.getRecordsByIds(ids,
OutputFormat.BIOPAX, new NullTaskMonitor());
Model model = new
SimpleIOHandler().convertFromOWL(new ByteArrayInputStream(xml.getBytes()));
-
-// new PC2/CPath2 API only supports L3 -
-// // to L3
-// if(BioPAXLevel.L2.equals(model.getLevel())) {
-// model = new OneTwoThree().filter(model);
-// }
-
- for (BioPAXElement pe :
model.getObjects(PhysicalEntity.class)) {
- String id =
BioPaxUtil.getLocalPartRdfId(pe);
- if (id != null) {
- //id = id.replaceAll("CPATH-",
"");
-
mapBioPaxToCytoscape.mapNodeAttribute(pe, model, cyNetwork, nodes.get(id));
+
+ //map biopax properties to Cy attributes for
SIF nodes
+ for (BioPAXElement e : model.getObjects()) {
+ if(e instanceof EntityReference || e
instanceof Complex
+ ||
e.getModelInterface().equals(PhysicalEntity.class))
+ {
+ CyNode node =
nodes.get(e.getRDFId());
+ if(node != null)
+
mapBioPaxToCytoscape.createAttributesFromProperties(e, node, cyNetwork);
+ // - this will also update the
'name' attribute (to a biol. label)
+ else {
+ logger.debug("Oops: no
node for " + e.getRDFId());
+ }
}
}
+
double percentComplete = i / (double)
batchList.size();
if (taskMonitor != null) {
taskMonitor.setProgress(percentComplete);
@@ -523,7 +351,7 @@
int counter = 0;
for (CyNode node : cyNetwork.getNodeList()) {
CyRow row = node.getCyRow();
- String label =
row.get(BioPaxVisualStyleUtil.BIOPAX_NODE_LABEL, String.class);
+ String label = row.get(CyNode.NAME, String.class);
// If we already have details on this node, skip it.
if (label == null) {
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathIdTaskFactory.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathIdTaskFactory.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecuteGetRecordByCPathIdTaskFactory.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -4,17 +4,18 @@
import org.cytoscape.biopax.MapBioPaxToCytoscapeFactory;
import org.cytoscape.biopax.NetworkListener;
import org.cytoscape.cpathsquared.internal.CPath2Factory;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.view.vizmap.VisualMappingManager;
import org.cytoscape.work.TaskFactory;
import org.cytoscape.work.TaskIterator;
+import cpath.service.OutputFormat;
+
public class ExecuteGetRecordByCPathIdTaskFactory implements TaskFactory {
private final CPathWebService webApi;
private final String[] ids;
- private final CPathResponseFormat format;
+ private final OutputFormat format;
private final String networkTitle;
private final CPath2Factory cPathFactory;
private final BioPaxContainer bpContainer;
@@ -23,7 +24,7 @@
private final VisualMappingManager mappingManager;
public ExecuteGetRecordByCPathIdTaskFactory(CPathWebService webApi,
- String[] ids, CPathResponseFormat format, String
networkTitle,
+ String[] ids, OutputFormat format, String networkTitle,
CPath2Factory cPathFactory, BioPaxContainer bpContainer,
MapBioPaxToCytoscapeFactory mapperFactory,
NetworkListener networkListener, VisualMappingManager mappingManager) {
this.webApi = webApi;
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/DownloadDetails.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/DownloadDetails.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/DownloadDetails.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -21,11 +21,11 @@
import org.cytoscape.cpathsquared.internal.CPath2Factory;
import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebServiceImpl;
import org.cytoscape.work.TaskManager;
+import cpath.service.OutputFormat;
import cpath.service.jaxb.SearchHit;
/**
@@ -137,11 +137,12 @@
String networkTitle = peName + ": Network";
CPathWebService webApi = CPathWebServiceImpl.getInstance();
- CPathResponseFormat format;
+ OutputFormat format;
+ //TODO EXTENDED_BINARY_SIF?
if (CPathProperties.downloadMode ==
CPathProperties.DOWNLOAD_FULL_BIOPAX) {
- format = CPathResponseFormat.BIOPAX;
+ format = OutputFormat.BIOPAX;
} else {
- format = CPathResponseFormat.BINARY_SIF;
+ format = OutputFormat.BINARY_SIF;
}
TaskManager taskManager = factory.getTaskManager();
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/GuiUtils.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/GuiUtils.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/GuiUtils.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -1,7 +1,18 @@
package org.cytoscape.cpathsquared.internal.view;
+import javax.swing.ButtonGroup;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+import javax.swing.border.EmptyBorder;
import javax.swing.border.TitledBorder;
+
+import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
+
import java.awt.*;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
/**
* Graphical User Interface (GUI) Utiltities.
@@ -23,4 +34,78 @@
border.setTitleColor(new Color(102,51,51));
return border;
}
+
+ public static JScrollPane createConfigPanel() {
+ JPanel configPanel = new JPanel();
+ configPanel.setBorder(new TitledBorder("Retrieval Options"));
+ configPanel.setLayout(new GridBagLayout());
+ GridBagConstraints c = new GridBagConstraints();
+ final JRadioButton button1 = new JRadioButton("Full Model");
+
+ JTextArea textArea1 = new JTextArea();
+ textArea1.setLineWrap(true);
+ textArea1.setWrapStyleWord(true);
+ textArea1.setEditable(false);
+ textArea1.setOpaque(false);
+ Font font = textArea1.getFont();
+ Font smallerFont = new Font(font.getFamily(), font.getStyle(),
font.getSize() - 2);
+ textArea1.setFont(smallerFont);
+ textArea1.setText("Retrieve the full model, as stored in the original
BioPAX "
+ + "representation. In this representation, nodes within a
network can "
+ + "refer to physical entities and interactions.");
+ textArea1.setBorder(new EmptyBorder(5, 20, 0, 0));
+
+ JTextArea textArea2 = new JTextArea(3, 20);
+ textArea2.setLineWrap(true);
+ textArea2.setWrapStyleWord(true);
+ textArea2.setEditable(false);
+ textArea2.setOpaque(false);
+ textArea2.setFont(smallerFont);
+ textArea2.setText("Retrieve a simplified binary network, as inferred
from the original "
+ + "BioPAX representation. In this representation, nodes
within a network refer "
+ + "to physical entities only, and edges refer to inferred
interactions.");
+ textArea2.setBorder(new EmptyBorder(5, 20, 0, 0));
+
+
+ final JRadioButton button2 = new JRadioButton("Simplified Binary
Model");
+ button2.setSelected(true);
+ ButtonGroup group = new ButtonGroup();
+ group.add(button1);
+ group.add(button2);
+
+ c.fill = GridBagConstraints.HORIZONTAL;
+ c.weightx = 1.0;
+
+ c.gridx = 0;
+ c.gridy = 0;
+ configPanel.add(button2, c);
+
+ c.gridy = 1;
+ configPanel.add(textArea2, c);
+
+ c.gridy = 2;
+ configPanel.add(button1, c);
+
+ c.gridy = 3;
+ configPanel.add(textArea1, c);
+
+ // Add invisible filler to take up all remaining space
+ c.gridy = 4;
+ c.weighty = 1.0;
+ JPanel panel = new JPanel();
+ configPanel.add(panel, c);
+
+ button1.addActionListener(new ActionListener() {
+ public void actionPerformed(ActionEvent actionEvent) {
+ CPathProperties.downloadMode =
CPathProperties.DOWNLOAD_FULL_BIOPAX;
+ }
+ });
+ button2.addActionListener(new ActionListener() {
+ public void actionPerformed(ActionEvent actionEvent) {
+ CPathProperties.downloadMode =
CPathProperties.DOWNLOAD_REDUCED_BINARY_SIF;
+ }
+ });
+ JScrollPane scrollPane = new JScrollPane(configPanel);
+ return scrollPane;
+ }
}
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/SearchDetailsPanel.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/SearchDetailsPanel.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/SearchDetailsPanel.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -16,10 +16,11 @@
import org.cytoscape.cpathsquared.internal.CPath2Factory;
import
org.cytoscape.cpathsquared.internal.task.ExecuteGetRecordByCPathIdTaskFactory;
import org.cytoscape.cpathsquared.internal.webservice.CPathProperties;
-import org.cytoscape.cpathsquared.internal.webservice.CPathResponseFormat;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebService;
import org.cytoscape.cpathsquared.internal.webservice.CPathWebServiceImpl;
+import cpath.service.OutputFormat;
+
/**
* Search Details Panel.
*
@@ -106,11 +107,12 @@
CPathWebService webApi = CPathWebServiceImpl.getInstance();
ExecuteGetRecordByCPathIdTaskFactory taskFactory;
- CPathResponseFormat format;
+ OutputFormat format;
+ //TODO add EXTENDED_BINARY_SIF
if (CPathProperties.downloadMode ==
CPathProperties.DOWNLOAD_FULL_BIOPAX) {
- format = CPathResponseFormat.BIOPAX;
+ format = OutputFormat.BIOPAX;
} else {
- format = CPathResponseFormat.BINARY_SIF;
+ format = OutputFormat.BINARY_SIF;
}
taskFactory = factory.createExecuteGetRecordByCPathIdTaskFactory(
Deleted:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/TreeDemo.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/TreeDemo.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/view/TreeDemo.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -1,93 +0,0 @@
-package org.cytoscape.cpathsquared.internal.view;
-
-
-import java.util.*;
-import java.awt.*;
-import java.awt.event.*;
-import javax.swing.*;
-import javax.swing.tree.*;
-
-/**
- * Tree Demo. Used to debug JTreeWithCheckNodes.
- *
- * Code was originally obtained from:
- * http://www.javaresearch.org/source/javaresearch/jrlib0.6/org/jr/swing/tree/
- *
- * and, has since been modified.
- */
-public class TreeDemo extends JFrame {
-
- public TreeDemo() {
- super("CheckNode TreeExample");
- String[] strs = {"Filters (optional)", // 0
- "Filter by Data Source", // 1
- "Reactome (4)", // 2
- "Cancer Cell Map (5)", // 3
- "Filter by Interaction Type", // 4
- "Protein-Protein Interactions (43)", // 5
- "Other (52)"}; // 6
-
- CheckNode[] nodes = new CheckNode[strs.length];
- for (int i=0;i<strs.length;i++) {
- nodes[i] = new CheckNode(strs[i]);
- }
- nodes[0].add(nodes[1]);
- nodes[1].add(nodes[2]);
- nodes[1].add(nodes[3]);
- nodes[0].add(nodes[4]);
- nodes[3].setSelected(true);
- nodes[4].add(nodes[5]);
- nodes[4].add(nodes[6]);
- JTreeWithCheckNodes tree = new JTreeWithCheckNodes( nodes[0] );
- JScrollPane sp = new JScrollPane(tree);
-
- JTextArea textArea = new JTextArea(3,10);
- JScrollPane textPanel = new JScrollPane(textArea);
- JButton button = new JButton("print");
- button.addActionListener(
- new ButtonActionListener(nodes[0], textArea));
- JPanel panel = new JPanel(new BorderLayout());
- panel.add(button, BorderLayout.SOUTH);
-
- CollapsablePanel filterPanel = new CollapsablePanel("Filters (Optional)");
- filterPanel.getContentPane().add(sp);
-
- getContentPane().add(filterPanel, BorderLayout.CENTER);
- getContentPane().add(panel, BorderLayout.EAST);
- getContentPane().add(textPanel, BorderLayout.SOUTH);
- }
-
- class ButtonActionListener implements ActionListener {
- CheckNode root;
- JTextArea textArea;
-
- ButtonActionListener(final CheckNode root,
- final JTextArea textArea) {
- this.root = root;
- this.textArea = textArea;
- }
-
- public void actionPerformed(ActionEvent e) {
- Enumeration enum1 = root.breadthFirstEnumeration();
- while (enum1.hasMoreElements()) {
- CheckNode node = (CheckNode)enum1.nextElement();
- if (node.isSelected()) {
- TreeNode[] nodes = node.getPath();
- textArea.append("\n" + nodes[0].toString());
- for (int i=1;i<nodes.length;i++) {
- textArea.append("/" + nodes[i].toString());
- }
- }
- }
- }
- }
-
- public static void main(String args[]) {
- TreeDemo frame = new TreeDemo();
- frame.addWindowListener(new WindowAdapter() {
- public void windowClosing(WindowEvent e) {System.exit(0);}
- });
- frame.setSize(300, 200);
- frame.setVisible(true);
- }
-}
\ No newline at end of file
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathCytoscapeWebService.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathCytoscapeWebService.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathCytoscapeWebService.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -10,7 +10,7 @@
import org.cytoscape.cpathsquared.internal.CPath2Factory;
import org.cytoscape.cpathsquared.internal.CPathNetworkImportTask;
-import org.cytoscape.cpathsquared.internal.CPathPlugIn2;
+import org.cytoscape.cpathsquared.internal.view.GuiUtils;
import org.cytoscape.cpathsquared.internal.view.TabUi;
import org.cytoscape.cpathsquared.internal.view.CPathSearchPanel;
import org.cytoscape.io.webservice.NetworkImportWebServiceClient;
@@ -20,6 +20,8 @@
import org.cytoscape.work.TaskIterator;
import org.cytoscape.work.Tunable;
+import cpath.service.OutputFormat;
+
/**
* CPath Web Service, integrated into the Cytoscape Web Services Framework.
*/
@@ -39,7 +41,11 @@
public static final String RESPONSE_FORMAT = "response_format";
@Tunable(description="Filter by Organism - NCBI Taxonomy ID")
- Integer taxonomyId = -1;
+ Integer taxonomyId = -1; //TODO consider several values (logical 'OR')
+ @Tunable(description="Filter by BioPAX Class")
+ String biopaxType = null;
+ @Tunable(description="Filter by Data Source")
+ String dataSource = null; //TODO consider several values (logical 'OR')
private JPanel mainPanel;
@@ -67,8 +73,7 @@
@Override
public TaskIterator getTaskIterator() {
String query = "";
- CPathResponseFormat format = CPathResponseFormat.BINARY_SIF;
- CPathNetworkImportTask task =
factory.createCPathNetworkImportTask(query, webApi, format);
+ CPathNetworkImportTask task =
factory.createCPathNetworkImportTask(query, webApi, OutputFormat.BINARY_SIF);
return new TaskIterator(task);
}
@@ -90,7 +95,7 @@
TabUi tabbedPane = TabUi.getInstance();
tabbedPane.add("Search", cpathPanel);
- JScrollPane configPanel = CPathPlugIn2.createConfigPanel();
+ JScrollPane configPanel = GuiUtils.createConfigPanel();
tabbedPane.add("Options", configPanel);
mainPanel.add(tabbedPane, BorderLayout.CENTER);
}
Deleted:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathResponseFormat.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathResponseFormat.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathResponseFormat.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -1,57 +0,0 @@
-package org.cytoscape.cpathsquared.internal.webservice;
-
-/**
- * CPath Response Format.
- */
-public class CPathResponseFormat {
- private String format;
-
- /**
- * BioPAX Format.
- */
- public static CPathResponseFormat BIOPAX = new CPathResponseFormat
("biopax");
-
- /**
- * Simplified Binary SIF Format.
- */
- public static CPathResponseFormat BINARY_SIF = new CPathResponseFormat
("binary_sif");
-
- /**
- * Generic XML Format.
- */
- public static CPathResponseFormat GENERIC_XML = new CPathResponseFormat
("xml");
-
- /**
- * Gets the Proper cPath Response Format.
- * @param format Format String.
- * @return CPathResponseFormat Object.
- */
- public static CPathResponseFormat getResponseFormat (String format) {
- if (format.equals(BIOPAX.getFormatString())) {
- return BIOPAX;
- } else if (format.equals(BINARY_SIF.getFormatString())) {
- return BINARY_SIF;
- } else if (format.equals(GENERIC_XML.getFormatString())) {
- return GENERIC_XML;
- }
- else {
- throw new IllegalArgumentException ("Format: " + format + " is
not valid.");
- }
- }
-
- /**
- * Private Constructor.
- * @param format Format String.
- */
- private CPathResponseFormat(String format) {
- this.format = format;
- }
-
- /**
- * Gets the format string.
- * @return format string.
- */
- public String getFormatString() {
- return this.format;
- }
-}
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathWebService.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathWebService.java
2011-10-26 20:43:45 UTC (rev 27311)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/webservice/CPathWebService.java
2011-10-26 21:44:32 UTC (rev 27312)
@@ -5,7 +5,10 @@
import org.biopax.paxtools.model.level3.BioSource;
import org.biopax.paxtools.model.level3.Entity;
-import cpath.service.jaxb.*;
+
+import cpath.service.OutputFormat;
+import cpath.service.jaxb.SearchResponse;
+
import org.cytoscape.work.TaskMonitor;
/**
@@ -61,7 +64,7 @@
* @throws CPathException CPath Error.
* @throws EmptySetException Empty Set Error.
*/
- public String getRecordsByIds(String[] ids, CPathResponseFormat format,
TaskMonitor taskMonitor)
+ public String getRecordsByIds(String[] ids, OutputFormat format,
TaskMonitor taskMonitor)
throws CPathException, EmptySetException;
/**
--
You received this message because you are subscribed to the Google Groups
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/cytoscape-cvs?hl=en.