Comment on page
The process of installing your extensions in MotiveWave™ is referred to as ‘Deployment’. There are essentially two use cases for deploying extensions:
- 1.Development – As you are coding your extension, you will want to deploy your changes to MotiveWave™ so you can test your changes.
- 2.Distribution – When you have completed development you will want to package your extensions and make them available to other users.
You may distribute your extensions by providing the .class (and .properties) files directly to your customers but you may find this awkward if you have more than one.
The preferred way to distribute these files is to package them together in a Jar (Java ARchive) file. This is a standard Java mechanism for distributing Java libraries or applications. If you would like to know more about this format you can visit this website address: http://java.sun.com/developer/Books/javaprogramming/JAR/
The sample Eclipse project includes the ability to create a Jar file for distribution in the ANT build script. You may also use the deployment features of Eclipse to create your Jar file.
MotiveWave™ will dynamically load extensions from the directory ‘MotiveWave Extensions’. This directory is created by MotiveWave™ when it first starts. Depending on the environment you have, it will be found:
- 1.Windows – C:\Documents and Settings\<username>\MotiveWave Extensions
- 2.Mac OSX - /Users/<username>/MotiveWave Extensions
This directory is searched (recursively) for the following types of files:
- 1.JAR Files (.jar) – These are essentially ‘zip files’ that contain .class and .properties files
- 2.Class Files (.class) – These files are generated by the javac compiler. Note: you must preserve the directory structure when copying these files into the ‘MotiveWave Extensions’ directory. For example classes in the ‘study_examples’ package must be put in the ‘MotiveWave Extensions\study_examples’ directory.
- 3.Properties Files (.properties) – These files contain the translatable text that has been separated from the code (see section on Internationalization). Similar to the class files, you must preserve the directory structure when copying these files into ‘MotiveWave Extensions’ directory.
Starting with version 5.4.21 third-party libraries (jar files) can now be used in the SDK. These jar files must be added in the ext subdirectory of the MotiveWave Extensions directory. On startup of MotiveWave, all jar files in this subdirectory will be added to the class path. If any jar files are added or modified in this directory, MotiveWave will need to be restarted to pick up the new changes.
The screen shot below shows an example of third-party libraries added to the ext directory in the Motive Wave Extensions.