-
Notifications
You must be signed in to change notification settings - Fork 5
PC2Client
Our team will commit to implementing and supporting a convenient java client for new Pathway Commons web services (cPath2 client) for developers (including us) to use in their projects, such as in Cytoscape apps, to quickly start exploring and querying the integrated PC BioPAX L3 database. Besides, we are forcing anyone to use this client only; feel free to develop a simpler and or more specific one.
To develop a swiss-army-knife java client for the cPath2 web services (BioPAX Level 3). To make it provide a convenient fluent query API, reasonable defaults, and documentation.
| Requirements | Priority | Size/Complexity |
|---|---|---|
| Basic programmatic access to all cPath2 atomic commands and parameters (without processing the results, not adding layers of data interpretation) | medium | small/normal |
| Advanced access/analysis on top of cPath2 (post-process results; built-in complex queries (series of server calls); FAQ use-cases queries, e.g., search that includes guessing, id-mapping, data inference/merging, etc.) | medium | large/complex |
| Easy get to (PC) BioPAX L3 data using Paxtools library (for tests/examples/docs) | high | medium/moderate |
| Accessing cPath2 resources from the new Cytoscape plugin/app | high | medium/complex |
- http://code.google.com/p/pathway-commons/source/checkout
- http://code.google.com/p/pathway-commons/source/browse/#hg%2Fcpath-client
Note: the latest, stateless client class, is CPathClient, whereas CPath2Client is the deprecated one (stateful, had problems with HTTP redirects).
- http://repo.pathway-commons.googlecode.com/hg/
- http://cpath2-site.pathway-commons.googlecode.com/hg/cpath-client/index.html
(%TODO% copy/move to the auto-generated documentation site)
//default - will use Pathway Commons web service endpoint URL
CPathClient client = CPAthClient.newInstance();
// then, result=client.create*Query()...result() or ...stringResult(format), etc.
in a Maven project, add to the pom.xml the following:
<repositories>
<repository>
<id>pathway-commons</id>
<name>Pathway Commons Repository at Google Code</name>
<url>http://repo.pathway-commons.googlecode.com/hg/</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>biopax.releases</id>
<name>BioPAX Repository</name>
<url>http://www.biopax.org/m2repo/releases/</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>biopax.snapshots</id>
<name>BioPAX Snapshots Repository</name>
<url>http://www.biopax.org/m2repo/snapshots/</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>pathwaycommons.cpath</groupId>
<artifactId>cpath-client</artifactId>
<version>4.1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.biopax.paxtools</groupId>
<artifactId>paxtools-core</artifactId>
<version>4.2.1</version>
</dependency>
</dependencies>
See also:
- example pom.xml (please ignore OSGi and Cytoscape specifics if you are not making a Cytoscape 3 app);
- see also, like client.create* usage, here;
- this project's tests can be used as example too.
Alternatively, or for a kick off, simply add the fat client jar to your Java (or JPype) project (temporarily here available).