fipaos.tool.loader
Class FIPAOSClassLoader
java.lang.Object
|
+--java.lang.ClassLoader
|
+--fipaos.tool.loader.FIPAOSClassLoader
- public class FIPAOSClassLoader
- extends ClassLoader
Custom class-loader to allow FIPA-OS classes and JAR's/ZIP's from a particular
location to be added to the classpath, as well as minimising the amount and
complexity of platform-specific script files required to launch FIPA-OS
Upon being loaded, this class loads system properties (accessible using System.getProperty()
)
from a file called fipa-os.properties
on the classpath, and then
the current directory (if they exist). Properties set in later of the two overrides values in the
former.
A classpath is then created which contains the following elements:
- The
classes
directory of the FIPA-OS installation (relative to the value assigned
to the fipaos.home
system property)
- The relevant FIPA-OS JAR within the same
classes
directory (name determined based
upon the value of fipaos.version
and fipaos.debug
system properties)
- All .ZIP and .JAR files in the directory referenced by the
fipaos.imports
system property.
Method Summary |
static void | main(String[] args) |
static void | setupSystemProperties() Locate fipaos.properties file and load it into system properties |
Methods inherited from class java.lang.ClassLoader |
loadClass, getParent, getResource, getResources, getSystemResource, getSystemResources, getResourceAsStream, getSystemResourceAsStream, getSystemClassLoader |
Methods inherited from class java.lang.Object |
getClass, hashCode, equals, toString, notify, notifyAll, wait, wait, wait |
main
public static void main(String[] args)
throws java.lang.Throwable
setupSystemProperties
public static void setupSystemProperties()
- Locate fipaos.properties file and load it into system properties
to Class java.lang.String- System properties that should use absolute path-names
to Class java.util.List
- Static list of ClassPath elements