public class Bootstrap
extends java.lang.Object
The Bootstrap class will instantiate our AgentClassLoader
which will then be
responsible for loading all classes needed by our Java Enabler.
As in all assistive technology bootstrap loaders, this class must be entered in the comma delimited list of assistive_technologies per Accessibility Properties standards. Most simply, adding the appropriate entry to the file:
This file is expected to be located or created in the (java.home)/lib directory of each and every Java JRE\SDK that is expected to use these Java Enablers.
The entry in the file will look like this:
There are also some rumors that an 'accessibility.properties' file may be placed in the "users home directory" for those cases when the user does not have write access to the Java JRE directories. The Java system property "java.ext.dir" may also allow the user to place the required safsjvmagent.jar and properties files in directories writable by the user, but this has not been tested or verified. Consult Java support resources provided by Sun and others if you are faced with these types of issues.
As mentioned, multiple assistive technology entries are separated by commas.
This Bootstrap class and a minimum set of associated classes are expected to reside in the (java.home)/lib/ext directory of each and every Java JRE\SDK that is expected to use these Java enablers.
Copy the following files from SAFS/lib to the (java.home)/lib/ext directories:
The 'safsjvmagent.properties' file is expected to contain a 'safs.jvmagent.classpath' setting
containing the search paths to SAFS, STAF and other Jar file dependencies. Review and edit
this file as necessary to provide accurate classpath information. An example is below.
Note the reversed file separator character used even on Windows:
Additional agents or alternative agents can be specified in another comma-separated list property as the example below shows:
If this property is not present, the DEFAULT_AGENT (AgentImpl
) alone will be launched.
Each additional agent will be launched and should spawn its own separate threads as needed.
Future multi-platform installers should automate the proper generation of this 'safsjvmagent.properties' file and detecting and enabling Java JVMs.
The 'safsjvmagent.jar' file contains a default 'safsjvmagent.properties' file. But this may only work on Windows systems using the default installation options. If desired, changes made to the local 'safsjvmagent.properties' can be merged or updated into the JAR file. Any such JAR updates should be copied into all enabled JVMs that might be used by the application(s) to be tested. However, it is easier to simply provide a separate, editable properties file in each JDK\lib\ext directory.
AgentClassLoader
,
AgentImpl
,
org.safs.abbot.jvmagent.JVMAgent
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
AGENT_CLASSES
'safs.jvmagent.classes'
This is the property name in the safsjvmagent.properties file which can contain
a comma-separated list of Agent-type classes for this class to launch.
|
static java.lang.String |
AGENT_CLASSPATH
'safs.jvmagent.classpath'
This is the property name in the safsjvmagent.properties file which contains
the classpath the AgentClassLoader is expected to use when loading classes.
|
static java.lang.String |
DEFAULT_AGENT
'org.safs.rmi.engine.AgentImpl'
The default Agent instanced by the Bootstrap AgentClassLoader.
|
static java.lang.String |
DEFAULT_AGENT_PROPERTIES
'safsjvmagent.properties'
This is the properties file containing values used by this class.
|
(package private) java.io.BufferedWriter |
log |
Constructor and Description |
---|
Bootstrap()
Default Assistive Technologies constructor.
|
Modifier and Type | Method and Description |
---|---|
(package private) void |
closeLog() |
protected void |
finalize() |
(package private) void |
logInfo(java.lang.String message) |
(package private) void |
openLog(java.lang.String path) |
public static final java.lang.String DEFAULT_AGENT
public static final java.lang.String DEFAULT_AGENT_PROPERTIES
public static final java.lang.String AGENT_CLASSPATH
public static final java.lang.String AGENT_CLASSES
java.io.BufferedWriter log
public Bootstrap()
Copyright © SAS Institute. All Rights Reserved.