Fork me on GitHub

Java Wrappers for the OpenMM C API

Force Field X makes use of OpenMM via Java wrappers for the OpenMM C API.

The wrappers are automatically generated using Jnaerator and are available on Github in case they may be useful to others:

Java Wrappers for the OpenMM C API

Including the Library in a Maven project.


How the Library Works

To use the Java OpenMM Wrappers within Java, please first initialize the library using the provided OpenMMUtils class:


This will extract the OpenMM binary libraries from the openmm-fat.jar file to a temporary directory and configure JNA to find them. OpenMM plugins can be loaded from the directory OpenMMUtils.OPENMM_PLUGIN_DIR as follows:

PointerByReference plugins =