Although working with Plastic is easy, the use of a client-side library to handle everyday housekeeping tasks such as keeping track of when the Plastic Hub is available can make it even easier. The following two Java libraries fullfil a similar function: plasticizing your Java application with a minimum of effort.
The java library used to plastic-enable Topcat and SPLAT is available in the standalone package PlasKit , which also provides an experimental lightweight hub implementation and testing tools. Please see the above page for further information on its use.
The Java library used to Plastic-enable xmdv-lite, Tabview, VAST, and AstroScope is available for use under the Academic Free Licence. It handles everyday tasks such as managing the connection to the Plastic hub, and responding to the core messages. Documentation including code samples can be found by following the Javadoc and xref links to the left under Project Reports. In particular, there is a sample client showing how to use the library. For a very trivial example see also SimplestExampleApplication.java
Maven users can automatically download and link to this, and any dependent jars, by including the following in their POM:
<dependency> <groupId>org.votech.ds6.plastic</groupId> <artifactId>plastic</artifactId> <version>version</version> <type>jar</type> </dependency> ... <repositories> <repository> <id>agmaven1</id> <name>AstroGrid Maven 1.0</name> <url>http://www.astrogrid.org/maven</url> <layout>legacy</layout> </repository> <repository> <id>agmaven2</id> <name>AstroGrid Maven 2.0</name> <url>http://www.astrogrid.org/maven</url> </repository> </repositories>
Replace artifactId plastic with plastic1.5 if you're working with Java 1.5. This will ensure you get the Java 1.5 versions of the dependencies too.
Further information can be found from the project summary report.