Previous Page Parent Page Next Page TOC
Installation | Language Bindings | Java Bindings Installation

Java Bindings Installation

Java Bindings Installation

Once you downloaded the binary package for the Java bindings you have to unpack it. It will be unpacked to a directory called copasi_java. This directory contains the native library, three jar files, a documentation file and the license file.
The copasi.jar file contains the actual language bindings for COPASI. The copasi_gui.jar file contains a little sample swing application that loads an SBML file and can run a time course simulation on the model contained in the SBML file. The unittests.jar file contains some unittests that can be used to check whether the bindings are working.

In order to run the unittests, junit needs to be available.
To run the unittests, you could use the following call:
java -Djava.library.path=. \
      -classpath copasi.jar:unittests.jar:junit.jar \
      junit.textui.TestRunner org.COPASI.unittests.RunTests

For Windows XP running all tests at once did not work using junit 4.4, running the individual tests in the unittests.jar worked however, so I am pretty sure the bindings are OK. If you want to run the tests and running all as described above does not work, just run the individual tests by replacing theorg.COPASI.unittests.RunTests by one of the individual test classes, e.g.org.COPASI.unittests.Test_RunSimulations.


Please note that under Microsoft Windows the language bindings require certain versions of the Microsoft runtime libraries. If these are not installed, the bindings might not work. Please see the download page for the individual language binding versions for the runtime requirements.