- java.lang.Object
 -  
      
- com.sun.java.accessibility.util.AWTEventMonitor
 -  
        
- com.sun.java.accessibility.util.SwingEventMonitor
 
 
 
-  
       
public class SwingEventMonitor extends AWTEventMonitor
SwingEventMonitor通过添加有条件地安装在Java虚拟机中的每个Swing组件实例上的一组侦听SwingEventMonitor扩展AWTEventMonitor。 这些侦听器捕获的事件通过SwingEventMonitor支持的统一侦听器集提供。 这样,每个AWT和Swing组件实例上的所有单个事件都会汇集到按类别细分的一组侦听器中(有关类别,请参阅EventID)。此类依赖于
EventQueueMonitor,它提供了在创建顶级容器时捕获它们的基本级别支持。因为此类扩展
AWTEventMonitor,所以不必同时使用此类和AWTEventMonitor。 如果要监视AWT和Swing组件,则应该只使用此类。- 另请参见:
 -  
         
AWTEventMonitor 
 
-  
        
       
-  
             
字段汇总
字段 变量和类型 字段 描述 protected static EventListenerListlistenerList其他类注册的所有侦听器的主列表。-  
               
声明的属性在类 com.sun.java.accessibility.util.AWTEventMonitor
actionListener, adjustmentListener, componentListener, componentWithFocus, containerListener, focusListener, itemListener, keyListener, mouseListener, mouseMotionListener, textListener, windowListener 
 -  
               
 
-  
             
构造方法摘要
构造方法 构造器 描述 SwingEventMonitor() 
-  
             
方法摘要
-  
               
声明方法的类 com.sun.java.accessibility.util.AWTEventMonitor
addActionListener, addAdjustmentListener, addComponentListener, addContainerListener, addFocusListener, addItemListener, addKeyListener, addMouseListener, addMouseMotionListener, addTextListener, addWindowListener, getComponentWithFocus, removeActionListener, removeAdjustmentListener, removeComponentListener, removeContainerListener, removeFocusListener, removeItemListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeTextListener, removeWindowListener 
 -  
               
 
 -  
             
 
-  
        
       
-  
             
字段详细信息
-  
listenerList
protected static final EventListenerList listenerList
其他类注册的所有侦听器的主列表。 这只能通过在此类中调用add或remove侦听器方法进行公开修改。 
 -  
 
-  
             
方法详细信息
-  
addAncestorListener
public static void addAncestorListener(AncestorListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有ANCESTOR事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeAncestorListener(javax.swing.event.AncestorListener) 
 
-  
removeAncestorListener
public static void removeAncestorListener(AncestorListener l)
删除指定的侦听器,以便它们在发生时不再接收ANCESTOR事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addAncestorListener(javax.swing.event.AncestorListener) 
 
-  
addCaretListener
public static void addCaretListener(CaretListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有CARET事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeCaretListener(javax.swing.event.CaretListener) 
 
-  
removeCaretListener
public static void removeCaretListener(CaretListener l)
删除指定的侦听器,以便它们在发生时不再接收CARET事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addCaretListener(javax.swing.event.CaretListener) 
 
-  
addCellEditorListener
public static void addCellEditorListener(CellEditorListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有CELLEDITOR事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeCellEditorListener(javax.swing.event.CellEditorListener) 
 
-  
removeCellEditorListener
public static void removeCellEditorListener(CellEditorListener l)
删除指定的侦听器,以便它们在发生时不再接收CELLEDITOR个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addCellEditorListener(javax.swing.event.CellEditorListener) 
 
-  
addChangeListener
public static void addChangeListener(ChangeListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有CHANGE事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeChangeListener(javax.swing.event.ChangeListener) 
 
-  
removeChangeListener
public static void removeChangeListener(ChangeListener l)
删除指定的侦听器,以便它们在发生时不再接收CHANGE事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addChangeListener(javax.swing.event.ChangeListener) 
 
-  
addColumnModelListener
public static void addColumnModelListener(TableColumnModelListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有COLUMNMODEL事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeColumnModelListener(javax.swing.event.TableColumnModelListener) 
 
-  
removeColumnModelListener
public static void removeColumnModelListener(TableColumnModelListener l)
删除指定的侦听器,以便它们在发生时不再接收COLUMNMODEL事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addColumnModelListener(javax.swing.event.TableColumnModelListener) 
 
-  
addDocumentListener
public static void addDocumentListener(DocumentListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有DOCUMENT事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeDocumentListener(javax.swing.event.DocumentListener) 
 
-  
removeDocumentListener
public static void removeDocumentListener(DocumentListener l)
删除指定的侦听器,以便它们在发生时不再接收DOCUMENT事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addDocumentListener(javax.swing.event.DocumentListener) 
 
-  
addListDataListener
public static void addListDataListener(ListDataListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有LISTDATA事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeListDataListener(javax.swing.event.ListDataListener) 
 
-  
removeListDataListener
public static void removeListDataListener(ListDataListener l)
删除指定的侦听器,以便它们在发生时不再接收LISTDATA事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addListDataListener(javax.swing.event.ListDataListener) 
 
-  
addListSelectionListener
public static void addListSelectionListener(ListSelectionListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有LISTSELECTION事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeListSelectionListener(javax.swing.event.ListSelectionListener) 
 
-  
removeListSelectionListener
public static void removeListSelectionListener(ListSelectionListener l)
删除指定的侦听器,以便它们在发生时不再接收LISTSELECTION事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addListSelectionListener(javax.swing.event.ListSelectionListener) 
 
-  
addMenuListener
public static void addMenuListener(MenuListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有MENU事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeMenuListener(javax.swing.event.MenuListener) 
 
-  
removeMenuListener
public static void removeMenuListener(MenuListener l)
删除指定的侦听器,以便它们在发生时不再接收MENU事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addMenuListener(javax.swing.event.MenuListener) 
 
-  
addPopupMenuListener
public static void addPopupMenuListener(PopupMenuListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有POPUPMENU事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removePopupMenuListener(javax.swing.event.PopupMenuListener) 
 
-  
removePopupMenuListener
public static void removePopupMenuListener(PopupMenuListener l)
删除指定的侦听器,以便它们在发生时不再接收POPUPMENU事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addPopupMenuListener(javax.swing.event.PopupMenuListener) 
 
-  
addTableModelListener
public static void addTableModelListener(TableModelListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有TABLEMODEL事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeTableModelListener(javax.swing.event.TableModelListener) 
 
-  
removeTableModelListener
public static void removeTableModelListener(TableModelListener l)
删除指定的侦听器,以便它们在发生时不再接收TABLEMODEL个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addTableModelListener(javax.swing.event.TableModelListener) 
 
-  
addTreeExpansionListener
public static void addTreeExpansionListener(TreeExpansionListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有TREEEXPANSION事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeTreeExpansionListener(javax.swing.event.TreeExpansionListener) 
 
-  
removeTreeExpansionListener
public static void removeTreeExpansionListener(TreeExpansionListener l)
删除指定的侦听器,以便它们在发生时不再接收TREEEXPANSION个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addTreeExpansionListener(javax.swing.event.TreeExpansionListener) 
 
-  
addTreeModelListener
public static void addTreeModelListener(TreeModelListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有TREEMODEL事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeTreeModelListener(javax.swing.event.TreeModelListener) 
 
-  
removeTreeModelListener
public static void removeTreeModelListener(TreeModelListener l)
删除指定的侦听器,以便它们在发生时不再接收TREEMODEL个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addTreeModelListener(javax.swing.event.TreeModelListener) 
 
-  
addTreeSelectionListener
public static void addTreeSelectionListener(TreeSelectionListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有TREESELECTION事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeTreeSelectionListener(javax.swing.event.TreeSelectionListener) 
 
-  
removeTreeSelectionListener
public static void removeTreeSelectionListener(TreeSelectionListener l)
删除指定的侦听器,以便它们在发生时不再接收TREESELECTION个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addTreeSelectionListener(javax.swing.event.TreeSelectionListener) 
 
-  
addUndoableEditListener
public static void addUndoableEditListener(UndoableEditListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有UNDOABLEEDIT事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeUndoableEditListener(javax.swing.event.UndoableEditListener) 
 
-  
removeUndoableEditListener
public static void removeUndoableEditListener(UndoableEditListener l)
删除指定的侦听器,以便它们在发生时不再接收UNDOABLEEDIT个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addUndoableEditListener(javax.swing.event.UndoableEditListener) 
 
-  
addInternalFrameListener
public static void addInternalFrameListener(InternalFrameListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有INTERNALFRAME事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeInternalFrameListener(javax.swing.event.InternalFrameListener) 
 
-  
removeInternalFrameListener
public static void removeInternalFrameListener(InternalFrameListener l)
删除指定的侦听器,以便它们发生时不再接收INTERNALFRAME事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addInternalFrameListener(javax.swing.event.InternalFrameListener) 
 
-  
addPropertyChangeListener
public static void addPropertyChangeListener(PropertyChangeListener l)
添加指定的侦听器以在Java虚拟机中的每个组件实例上发生所有PROPERTYCHANGE事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removePropertyChangeListener(java.beans.PropertyChangeListener) 
 
-  
removePropertyChangeListener
public static void removePropertyChangeListener(PropertyChangeListener l)
删除指定的侦听器,以便它们在发生时不再接收PROPERTYCHANGE个事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addPropertyChangeListener(java.beans.PropertyChangeListener) 
 
-  
addVetoableChangeListener
public static void addVetoableChangeListener(VetoableChangeListener l)
添加指定的侦听器,以便在Java虚拟机中的每个组件实例上发生所有VETOABLECHANGE事件。注意:此侦听器将自动添加到调用此方法后创建的所有组件实例中。 此外,它仅添加到支持此侦听器类型的组件实例。
- 参数
 -  
              
l- 要添加的侦听器 - 另请参见:
 -  
              
removeVetoableChangeListener(java.beans.VetoableChangeListener) 
 
-  
removeVetoableChangeListener
public static void removeVetoableChangeListener(VetoableChangeListener l)
删除指定的侦听器,以便它们在发生时不再接收VETOABLECHANGE事件。- 参数
 -  
              
l- 要删除的侦听器 - 另请参见:
 -  
              
addVetoableChangeListener(java.beans.VetoableChangeListener) 
 
 -  
 
 -