com.sun.java.accessibility.util
Class AccessibilityEventMonitor

java.lang.Object
  |
  +--com.sun.java.accessibility.util.AccessibilityEventMonitor

public class AccessibilityEventMonitor
extends java.lang.Object

The AccessibilityEventMonitor implements a PropertyChange listener on every UI object that implements interface Accessibility in the Java Virtual Machine. The events captured by these listeners are made available through a listeners supported by AccessibilityEventMonitor. With this, all the individual events on each of the ui object instances are funnelled into one set of PropertyChange listeners.

This class depends upon EventQueueMonitor, which provides the base level support for capturing the top-level containers as they are created.

For JDK1.1 only, the EventQueueMonitor class needs to be in the CLASSPATH environment variable and the following line needs to be in the awt.properties file:

 AWT.EventQueueClass=com.sun.java.accessibility.util.EventQueueMonitor
 

For JDK1.2, EventQueueMonitor merely needs to be in the CLASSPATH. The best way for this to happen is to place the jaccess.jar file in the standard extensions directory (e.g., $JDKHOME/jre/lib/ext).


Field Summary
protected static com.sun.java.accessibility.util.AccessibilityEventMonitor.AccessibilityEventListener accessibilityListener
          The actual listener that is installed on the component instances.
protected static AccessibilityListenerList listenerList
          The current list of registered PropertyChangeListener classes.
 
Constructor Summary
AccessibilityEventMonitor()
           
 
Method Summary
static void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Adds the specified listener to receive all PropertyChange events on each UI object instance in the Java Virtual Machine as they occur.
static void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Removes the specified listener so it no longer receives PropertyChange events when they occur.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

listenerList

protected static AccessibilityListenerList listenerList
The current list of registered PropertyChangeListener classes.
See Also:
addPropertyChangeListener(java.beans.PropertyChangeListener), removePropertyChangeListener(java.beans.PropertyChangeListener)

accessibilityListener

protected static com.sun.java.accessibility.util.AccessibilityEventMonitor.AccessibilityEventListener accessibilityListener
The actual listener that is installed on the component instances. This listener calls the other registered listeners when an event occurs. By doing things this way, the actual number of listeners installed on a component instance is drastically reduced.
Constructor Detail

AccessibilityEventMonitor

public AccessibilityEventMonitor()
Method Detail

addPropertyChangeListener

public static void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Adds the specified listener to receive all PropertyChange events on each UI object instance in the Java Virtual Machine as they occur.

Note: this listener is automatically added to all component instances created after this method is called. In addition, it is only added to UI object instances that support this listener type.

Parameters:
l - the listener to add
See Also:
removePropertyChangeListener(java.beans.PropertyChangeListener)

removePropertyChangeListener

public static void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Removes the specified listener so it no longer receives PropertyChange events when they occur.
Parameters:
l - the listener to remove
See Also:
addPropertyChangeListener(java.beans.PropertyChangeListener)