Author: rodche
Date: 2011-11-09 15:25:25 -0800 (Wed, 09 Nov 2011)
New Revision: 27439
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/pom.xml
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathCytoscapeWebService.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathProperties.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathWebServiceImpl.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CyActivator.java
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecutePhysicalEntitySearchTask.java
Log:
Changed version, and - paxtools version, some text/logs, etc...
Modified: csplugins/trunk/toronto/rodche/cpathsquared-impl/pom.xml
===================================================================
--- csplugins/trunk/toronto/rodche/cpathsquared-impl/pom.xml 2011-11-09
22:48:40 UTC (rev 27438)
+++ csplugins/trunk/toronto/rodche/cpathsquared-impl/pom.xml 2011-11-09
23:25:25 UTC (rev 27439)
@@ -15,7 +15,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.cytoscape</groupId>
<artifactId>cpathsquared-impl</artifactId>
- <version>0.0.1-alpha1-SNAPSHOT</version>
+ <version>0.0.1-SNAPSHOT</version>
<name>${bundle.symbolicName} [${bundle.namespace}]</name>
<packaging>bundle</packaging>
<scm>
@@ -72,7 +72,6 @@
<version>${cytoscape.api.version}</version>
<scope>provided</scope>
</dependency>
-
<dependency>
<groupId>org.cytoscape</groupId>
<artifactId>biopax-impl</artifactId>
@@ -95,9 +94,6 @@
<version>${cytoscape.api.version}</version>
<scope>provided</scope>
</dependency>
-
-
-
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
@@ -113,7 +109,7 @@
<dependency>
<groupId>org.biopax.paxtools</groupId>
<artifactId>paxtools-core</artifactId>
- <version>4.0.0-SNAPSHOT</version>
+ <version>4.0.1-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>pathwaycommons.cpath</groupId>
@@ -123,8 +119,40 @@
<dependency>
<groupId>org.biopax.paxtools</groupId>
<artifactId>pathwaycommons-client</artifactId>
- <version>4.0.0-SNAPSHOT</version>
+ <version>4.0.1-SNAPSHOT</version>
</dependency>
+
+ <!-- Spring Dependencies to embed (temporary; must use/start Spring
EBR bundles instead) -->
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-context</artifactId>
+ <version>3.0.5.RELEASE</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-core</artifactId>
+ <version>3.0.5.RELEASE</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-oxm</artifactId>
+ <version>3.0.5.RELEASE</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-web</artifactId>
+ <version>3.0.5.RELEASE</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-beans</artifactId>
+ <version>3.0.5.RELEASE</version>
+ <scope>runtime</scope>
+ </dependency>
</dependencies>
<build>
@@ -146,7 +174,8 @@
<Private-Package>${bundle.namespace}.internal.*</Private-Package>
<Embed-Dependency>
*;groupId=org.biopax.paxtools;type=!pom;inline=true;scope=compile|runtime,
-
*;artifactId=cpath-api;type=!pom;inline=true;scope=compile|runtime
+
*;artifactId=cpath-api;type=!pom;inline=true;scope=compile|runtime,
+
*;groupId=org.springframework;type=!pom;inline=true;scope=runtime
</Embed-Dependency>
<Import-Package>*;resolution:=optional</Import-Package>
<!-- <_include>-osgi.bnd</_include>
-->
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathCytoscapeWebService.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathCytoscapeWebService.java
2011-11-09 22:48:40 UTC (rev 27438)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathCytoscapeWebService.java
2011-11-09 23:25:25 UTC (rev 27439)
@@ -18,16 +18,21 @@
import org.cytoscape.model.CyNetwork;
import org.cytoscape.work.TaskIterator;
import org.cytoscape.work.Tunable;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import cpath.service.OutputFormat;
/**
* CPath Web Service, integrated into the Cytoscape Web Services Framework.
*/
-public class CPathCytoscapeWebService extends AbstractWebServiceClient
implements NetworkImportWebServiceClient, SearchWebServiceClient<Object> {
- // Display name of this client.
- private static final String DISPLAY_NAME = CPathProperties.serverName +
- " Web Service Client";
+public class CPathCytoscapeWebService extends AbstractWebServiceClient
+ implements NetworkImportWebServiceClient,
SearchWebServiceClient<Object>
+{
+ private static final Logger LOGGER =
LoggerFactory.getLogger(CPathCytoscapeWebService.class);
+
+ // Display name of this client.
+ private static final String DISPLAY_NAME = CPathProperties.serverName + "
Client";
/**
* NCBI Taxonomy ID Filter.
@@ -41,10 +46,10 @@
@Tunable(description="Filter by Organism - NCBI Taxonomy ID")
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')
+// @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;
@@ -97,6 +102,9 @@
JScrollPane configPanel = GuiUtils.createConfigPanel();
tabbedPane.add("Options", configPanel);
mainPanel.add(tabbedPane, BorderLayout.CENTER);
+
+ if(LOGGER.isDebugEnabled())
+ LOGGER.debug("CPathCytoscapeWebService created!");
}
private static String makeDescription() {
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathProperties.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathProperties.java
2011-11-09 22:48:40 UTC (rev 27438)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathProperties.java
2011-11-09 23:25:25 UTC (rev 27439)
@@ -32,9 +32,9 @@
"information collected from public pathway databases, which you
can " +
"browse or search. <BR><BR>Pathways include biochemical reactions,
complex " +
"assembly, transport and catalysis events, and physical
interactions " +
- "involving proteins, DNA, RNA, small molecules and complexes.";
+ "involving proteins, DNA, RNA, small molecules and complexes. Now
using BioPAX Level3!";
- public static String iconToolTip = "Retrieve Pathway Data from
PathwayCommons.org";
+ public static String iconToolTip = "Import Pathway Data from new
PathwayCommons.org";
public static String iconFileName = "pc.png";
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathWebServiceImpl.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathWebServiceImpl.java
2011-11-09 22:48:40 UTC (rev 27438)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CPathWebServiceImpl.java
2011-11-09 23:25:25 UTC (rev 27439)
@@ -1,6 +1,5 @@
package org.cytoscape.cpathsquared.internal;
-import java.io.StringReader;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
@@ -8,9 +7,10 @@
import org.biopax.paxtools.io.pathwayCommons.PathwayCommons2Client;
import org.biopax.paxtools.io.pathwayCommons.util.PathwayCommonsException;
import org.biopax.paxtools.model.level3.BioSource;
-import org.biopax.paxtools.model.level3.PhysicalEntity;
import org.cytoscape.cpathsquared.internal.util.EmptySetException;
import org.cytoscape.work.TaskMonitor;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import cpath.service.OutputFormat;
import cpath.service.jaxb.SearchResponse;
@@ -23,7 +23,8 @@
public class CPathWebServiceImpl implements CPathWebService {
private static ArrayList<CPathWebServiceListener> listeners = new
ArrayList<CPathWebServiceListener>();
private static CPathWebService webApi;
-
+ private static final Logger LOGGER =
LoggerFactory.getLogger(CPathWebServiceImpl.class);
+
/**
* Gets a singleton instance of the cPath2 web service handler.
* @return CPathWebService Object.
@@ -51,13 +52,19 @@
public SearchResponse searchPhysicalEntities(String keyword, int
ncbiTaxonomyId,
TaskMonitor taskMonitor) throws CPathException, EmptySetException {
- // Notify all listeners of start
+ if(LOGGER.isDebugEnabled())
+ LOGGER.debug("searchPhysicalEntities: query=" + keyword);
+
+ // Notify all listeners of start
for (int i = listeners.size() - 1; i >= 0; i--) {
CPathWebServiceListener listener = listeners.get(i);
listener.searchInitiatedForPhysicalEntities(keyword,
ncbiTaxonomyId);
}
PathwayCommons2Client client = new PathwayCommons2Client();
+ if(LOGGER.isDebugEnabled())
+ LOGGER.debug("cPath2Url=" + client.getEndPointURL());
+
client.setOrganisms(Collections.singleton(String.valueOf(ncbiTaxonomyId)));
//protocol.setCommand(CPathProtocol.COMMAND_SEARCH);
client.setType("PhysicalEntity");
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CyActivator.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CyActivator.java
2011-11-09 22:48:40 UTC (rev 27438)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/CyActivator.java
2011-11-09 23:25:25 UTC (rev 27439)
@@ -58,7 +58,12 @@
VisualMappingFunctionFactory discreteMappingFactoryRef =
getService(bc,VisualMappingFunctionFactory.class,"(mapping.type=discrete)");
VisualMappingFunctionFactory passthroughMappingFactoryRef =
getService(bc,VisualMappingFunctionFactory.class,"(mapping.type=passthrough)");
- BinarySifVisualStyleFactory binarySifVisualStyleUtil = new
BinarySifVisualStyleFactory(visualStyleFactoryRef,visualMappingManagerRef,discreteMappingFactoryRef,passthroughMappingFactoryRef);
+ BinarySifVisualStyleFactory binarySifVisualStyleUtil = new
BinarySifVisualStyleFactory(
+ visualStyleFactoryRef,
+ visualMappingManagerRef,
+ discreteMappingFactoryRef,
+ passthroughMappingFactoryRef);
+
CPath2Factory cPath2Factory = new CPath2Factory(
cySwingApplicationRef,
taskManagerRef,
@@ -76,9 +81,10 @@
networkListenerRef,
binarySifVisualStyleUtil,
visualMappingManagerRef);
+
CPathCytoscapeWebService cPathWebService = new
CPathCytoscapeWebService(cPath2Factory);
- registerAllServices(bc,cPathWebService, new Properties());
+ registerAllServices(bc, cPathWebService, new Properties());
}
}
Modified:
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecutePhysicalEntitySearchTask.java
===================================================================
---
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecutePhysicalEntitySearchTask.java
2011-11-09 22:48:40 UTC (rev 27438)
+++
csplugins/trunk/toronto/rodche/cpathsquared-impl/src/main/java/org/cytoscape/cpathsquared/internal/task/ExecutePhysicalEntitySearchTask.java
2011-11-09 23:25:25 UTC (rev 27439)
@@ -90,6 +90,8 @@
if (e.getErrorCode() != CPathException.ERROR_CANCELED_BY_USER) {
throw e;
}
+ } catch (Throwable e) { // - helps with optional/unresolved runtime
dependencies!
+ throw new RuntimeException(e);
} finally {
taskMonitor.setStatusMessage("Done");
taskMonitor.setProgress(1);
--
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.