|
Generated by JDiff |
||||||||
PREV PACKAGE NEXT PACKAGE FRAMES NO FRAMES |
This file contains all the changes in documentation in the packagejavax.swing.event
as colored differences. Deletions are shownlike this, and additions are shown like this.
If no deletions or additions are shown in an entry, the HTML tags will be what has changed. The new HTML tags are shown in the differences. If no documentation existed, and then some was added in a later version, this change is noted in the appropriate class pages of differences, but the change is not shown on this page. Only changes in existing text are shown here. Similarly, documentation which was inherited from another class or interface is not shown here.
Note that an HTML error in the new documentation may cause the display of other documentation changes to be presented incorrectly. For instance, failure to close a <code> tag will cause all subsequent paragraphs to be displayed differently.
Constructs an AncestorEvent object to identify a change in an ancestor-component's display-status. @param source the JComponent that originated the event (typically this
) @param id an int specifying #ANCESTOR_ADDED #ANCESTOR_REMOVED or #ANCESTOR_MOVED @param ancestor a Container object specifying the ancestor-component whose display-status changed @param ancestorParent a Container object specifying the ancestor's parent
AncestorListener Interface to support notification when changes occur to a JComponent or one of its ancestors. These include movement and when the component becomes visible or invisible either by the setVisible() method or by being added or removed from the component hierarchy. @version 1.7 099 02/2102/9800 @author Dave Moore
CaretEvent is used to notify interested parties that the text caret has changed in the event source.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
7 089 02/2802/9800 @author Timothy Prinzing
Listener for changes in the caret position of a text component. @version 1.4 086 02/2602/9800 @author Timothy Prinzing
CellEditorListener defines the interface for an object that listens to changes in a CellEditor @version 1.8 0810 02/2602/9800 @author Alan Chung
ChangeEvent is used to notify interested parties that state has changed in the event source.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
10 0812 02/2802/9800 @author Jeff Dinkins
Defines an object which listens for ChangeEvents. @version 1.6 098 02/2102/9800 @author Jeff Dinkins
Interface for document change notifications. This provides detailed information to Document observers about how the Document changed. It provides high level information such as type of change and where it occured as well as the more detailed structural changes (What Elements were inserted and removed). @author Timothy Prinzing @version 1.16 1018 02/2202/9800 @see javax.swing.text.Document @see DocumentListener
Interface for an observer to register to receive notifications of changes to a text document.The default implementation of the Document interface (AbstractDocument) supports asynchronous mutations. If this feature is used (i.e. mutations are made from a thread other than the Swing event thread) the listeners will be notified via the mutating thread. This means that if asynchronous updates are made the implementation of this interface must be threadsafe
The DocumentEvent notification is based upon the JavaBeans event model. There is no guarantee about the order of delivery to listeners and all listeners must be notified prior to making further mutations to the Document. This means implementations of the DocumentListener may not mutate the source of the event (i.e. the associated Document). @author Timothy Prinzing @version 1.
9 1011 02/2202/9800 @see javax.swing.text.Document @see javax.swing.text.StyledDocument @see DocumentEvent
A classClass EventListenerList, void add(Class, EventListener)whichthat holds a list of EventListeners. A single instance can be used to hold all listeners (of all types) for the instance using thelsitlist. It is the responsiblity of the class using the EventListenerList to provide type-safe API (preferably conforming to the JavaBeans spec) and methods which dispatch event notification methods to appropriate Event Listeners on the list. The main benefitswhichthat this class provides are that it is relatively cheap in the case of no listeners and it provides serialization foreventlistenerevent-listener lists in a single place as well as a degree of MT safety (when used correctly). Usage example: Say one is defining a classwhichthat sends out FooEvents andwantdsone wants to allow users of the class to register FooListeners and receive notification when FooEvents occur. The following should be added to the class definition:EventListenerListfoo should be changed to the appropriate name andlistenrListlistenerList = newEventListnerListEventListenerList(); FooEvent fooEvent = null; public void addFooListener(FooListener l) { listenerList.add(FooListener.class l); } public void removeFooListener(FooListener l) { listenerList.remove(FooListener.class l); } // Notify all listeners that have registered interest for // notification on this event type. The event instance // is lazily created using the parameters passed into // the fire method. protected voidfirefooXXXfireFooXXX() { // Guaranteed to return a non-null array Object[] listeners = listenerList.getListenerList(); // Process the listeners last to first notifying // those that are interested in this event for (int i = listeners.length-2; i>=0; i-=2) { if (listeners[i]==FooListener.class) { // Lazily create the event: if (fooEvent == null) fooEvent = new FooEvent(this); ((FooListener)listeners[i+1]).fooXXX(fooEvent); } } }MethodfireFooXxx to the appropriate method name.(oneOne fire method should exist for each notification method in the FooListener interface).Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
23 1027 02/0102/9800 @author Georges Saab @author Hans Muller @author James Gosling
Class EventListenerList, int getListenerCount()AddAdds the listener as a listener of the specified type. @param t the type of the listener to be added @param l the listener to be added
Class EventListenerList, int getListenerCount(Class)ReturnReturns the total number of listeners for thislistenerlistlistener list.
Class EventListenerList, Object[] getListenerList()ReturnReturns the total number of listeners of the supplied type for thislistenerlistlistener list.
Class EventListenerList, void remove(Class, EventListener)This passesPasses back the event listener list as an array of ListenerType-listener pairs. Note that for performance reasons this implementation passes back the actual data structure in which thelistnerlistener data is stored internally This method is guaranteed to pass back a non-null array so that no null-checking is required in fire methods. A zero-length array of Object should be returned if there are currently no listeners. WARNING Absolutely NO modification of the data contained in this array should be made -- if any such manipulation is necessary it should be done on a copy of the array returned rather than the array itself.
Class EventListenerList, String toString()RemoveRemoves the listener as a listener of the specified type. @param t the type of the listener to be removed @param l the listener to be removed
ReturnReturns a string representation of the EventListenerList.
HyperlinkEvent is used to notify interested parties that something has happened with respect to a hypertext link.Class HyperlinkEvent, constructor HyperlinkEvent(Object, EventType, URL)Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
9 0812 02/2802/9800 @author Timothy Prinzing
Creates a new object representing a hypertext link event. The other constructor is preferred as it provides more information if a URL could not be formed. This constructor is primarily for backward compatibility. @param source the object responsible for the event @param type the event type @param u the affected URLClass HyperlinkEvent, constructor HyperlinkEvent(Object, EventType, URL, String)
Creates a new object representing a hypertext link event. @param source the object responsible for the event @param type the event type @param u the affected URL. This may be null if a valid URL could not be created. @param desc the description of the link. This may be useful when attempting to form a URL resulted in a MalformedURLException. The description provides the text used when attempting to form the URL.
HyperlinkListener @version 1.5 087 02/2602/9800 @author Timothy Prinzing
An abstract adapter class for receiving internal frame events. The methods in this class are empty. This class exists as convenience for creating listener objects and is functionally equivalent to the WindowAdapter class in the AWT.See
WritingHowato Write anWindowInternal Frame Listener in The Java Tutorial and The Java Class Libraries (update) @see InternalFrameEvent @see InternalFrameListener @see java.awt.event.WindowListener @version 1.7 049 02/2202/9900 @author Thomas Ball
InternalFrameEvent: an AWTEvent which adds support for JInternalFrame objects as the event source. This class has the same event types as WindowEvent although different ids are used.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @see java.awt.event.WindowEvent @see java.awt.event.WindowListener @version 1.
7 0811 02/2802/9800 @author Thomas Ball
The listener interface for receiving internal frame events. This class is functionally equivalent to the WindowListener class in the AWT.See
WritingHowato Write anWindowInternal Frame Listener in The Java Tutorial and The Java Class Libraries (update) for further documentation. @see java.awt.event.WindowListener @version 1.6 089 02/2602/9800 @author Thomas Ball
Defines an event that encapsulates changes to a list.Class ListDataEvent, constructor ListDataEvent(Object, int, int, int)Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
9 0812 02/2802/9800 @author Hans Muller
Constructs a ListDataEvent object. @param source the source Object (typically this
) @param type an int specifying #CONTENTS_CHANGED #INTERVAL_ADDED or #INTERVAL_REMOVED @param index0 an int specifying the bottom of a range @param index1 an int specifying the top of a range
Class ListDataEvent, int getType()Returns the event type. The possible values are: @return an int representing the type value
ListDataListener @version 1.7 099 02/2102/9800 @author Hans Muller
An event that characterizes a change in the current selection. The change is limited to a row interval. ListSelectionListeners will generally query the source of the event for the new selected status of each potentially changed row.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
13 0815 02/2802/9800 @author Hans Muller @author Ray Ryan @see ListSelectionModel
The listener that's notified when a lists selection value changes. @see javax.swing.ListSelectionModel @version 1.7 099 02/2102/9800 @author Hans Muller
MenuDragMouseEvent is used to notify interested parties that the menu element has received a MouseEvent forwarded to it under drag conditions.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
7 089 02/2802/9800 @author Georges Saab
Defines a menu mouse-drag listener. @version 1.6 088 02/2602/9800 @author Georges Saab
MenuEvent is used to notify interested parties that the menu which is the event source has been posted selected or canceled.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
9 0811 02/2802/9800 @author Georges Saab @author David Karlton
MenuKeyEvent is used to notify interested parties that the menu element has received a KeyEvent forwarded to it in a menu tree.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
7 089 02/2802/9800 @author Georges Saab
MenuKeyListener @version 1.4 086 02/2602/9800 @author Georges Saab
Defines a listener for menu events. @version 1.Class MenuListener, void menuCanceled(MenuEvent)6 089 02/2602/9800 @author Georges Saab
Invoked when the menuClass MenuListener, void menuDeselected(MenuEvent)selectionis canceled. @param e a MenuEvent object
Invoked when the menuClass MenuListener, void menuSelected(MenuEvent)selection changesis deselected. @param e a MenuEvent object
Invoked when a menuitemis selected. @param e a MenuEvent object
The adapter which receives mouse events and mouse motion events. The methods in this class are empty; this class is provided as a convenience for easily creating listeners by extending this class and overriding only the methods of interest. @version 1.7 099 02/0102/9800 @author Philip Milne
A listener implementing all the methods in both the MouseListener and MouseMotionListener interfaces. @version 1.5 087 02/2602/9800 @author Philip Milne
PopupMenuEvent only contains the source of the event which is the JPoupMenu sending the eventWarning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
7 089 02/2802/9800 @author Arnaud Weber
A popup menu listener @version 1.4 096 02/2102/9800 @author Arnaud Weber
This subclass of java.beans.PropertyChangeSupport is identical in functionality -- it sacrifices thread-safety (not a Swing concern) for reduce memory consumption which helps performance (both big Swing concerns). Most of the overridden methods are only necessary because all of PropertyChangeSupport's instance data is private without accessor methods. @version 1.6 1112 02/1802/9800 @author unattributed
TableColumnModelEvent is used to notify listeners that a table column model has changed such as a column was added removed or moved.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
10 0812 02/2802/9800 @author Alan Chung @see TableColumnModelListener
TableColumnModelListener defines the interface for an object that listens to changes in a TableColumnModel. @version 1.8 0810 02/2602/9800 @author Alan Chung @see TableColumnModelEvent
TableModelEvent is used to notify listeners that a table model has changed. The model event describes changes to a TableModel and all references to rows and columns are in the co-ordinate system of the model. Depending on the parameters used in the constructors the TableModelevent can be used to specify the following types of changes:
TableModelEvent(source); // The data ie. all rows changed TableModelEvent(source HEADER_ROW); // Structure change reallcoate TableColumns TableModelEvent(source 1); // Row 1 changed TableModelEvent(source 3 6); // Rows 3 to 6 inclusive changed TableModelEvent(source 2 2 6); // Cell at (2 6) changed TableModelEvent(source 3 6 ALL_COLUMNS INSERT); // Rows (3 6) were inserted TableModelEvent(source 3 6 ALL_COLUMNS DELETE); // Rows (3 6) were deletedIt is possible to use other combinations of the parameters not all of them are meaningful. By subclassing you can add other information for example: whether the event WILL happen or DID happen. This makes the specification of rows in DELETE events more useful but has not been included in the swing package as the JTable only needs post-event notification.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
14 0816 02/2802/9800 @author Alan Chung @author Philip Milne @see TableModel
TableModelListener defines the interface for an object that listens to changes in a TableModel. @version 1.10 0912 02/2102/9800 @author Alan Chung @see javax.swing.table.TableModel
An event used to identify a single path in a tree. The source returned by getSource will be an instance of JTree.For further documentation and examples see the following sections in The Java Tutorial: How to Write a Tree Expansion Listener and How to Write a Tree-Will-Expand Listener.
Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @author Scott Violet @version 1.
13 0816 02/2802/9800
The listener that's notified when a tree expands or collapses a node. For further documentation and examples see How to Write a Tree Expansion Listener a section in The Java Tutorial. @author Scott Violet
Encapsulates information describing changes to a tree model and used to notify tree model listeners of the change. For more information and examples see How to Write a Tree Model Listener a section in The Java Tutorial.Class TreeModelEvent, TreePath getTreePath()Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
22 0826 02/2802/9800 @author Rob Davis @author Ray Ryan @author Scott Violet
Returns the TreePath objectFor all events exceptidentifyingtreeStructureChanged returns the parent of the changednodenodes.UseForgetLastPathComponenttreeStructureChanged events returns the ancestor of theonstructure thatobjecthas changed. This andgetChildIndices
are used to get a list of thedataeffected nodes.stored atThe one exception to this is a treeNodesChanged event thatnodeis to identify the root in which case this will return the root andgetChildIndices
will return null. @return the TreePathobjectused in identifying the changednodenodes. @see TreePath#getLastPathComponent
Class TreeModelListener, void treeNodesChanged(TreeModelEvent)TreeChangeListenerDefinesdefinesthe interface for an object that listens to changes in a TreeModel. For further information and examples see How to Write a Tree Model Listener a section in The Java Tutorial. @version 1.11 0414 02/2202/9900 @author Rob Davis @author Ray Ryan
Class TreeModelListener, void treeNodesInserted(TreeModelEvent)Invoked after a node (or a set of siblings) has changed in some way. The node(s) have not changed locations in the tree or altered their children arrays but other attributes have changed and may affect presentation. Example: the name of a file has changed but it is in the same location in the file system.
To indicate the root has changed childIndices and children will be null.
Use
e.
pathgetPath()returnsthe pathto get the parent of the changed node(s).e.
returns the index(es) of the changed node(s).childIndicesgetChildIndices()
Class TreeModelListener, void treeNodesRemoved(TreeModelEvent)Invoked after nodes have been inserted into the tree.
Use
e.
pathgetPath()returnsto get the parent of the newnodesnode(s).e.
returns thechildIndicesgetChildIndices()indicesindex(es) of the newnodesnode(s) in ascending order.
Class TreeModelListener, void treeStructureChanged(TreeModelEvent)Invoked after nodes have been removed from the tree. Note that if a subtree is removed from the tree this method may only be invoked once for the root of the removed subtree not once for each individual set of siblings removed.
Use
e.
pathgetPath()returnsto get the former parent of the deletednodesnode(s).e.
returns in ascending order thechildIndicesgetChildIndices()indicesindex(es) thenodesnode(s) had beforethey werebeing deletedin ascending order.
Invoked after the tree has drastically changed structure from a given node down. If the path returned by e.getPath() is of length one and the first element does not identify the current root node the first element should become the new root of the tree.
Use
e.
pathgetPath() toholdsget the path to the node.e.
returns null.childIndicesgetChildIndices()
An event that characterizes a change in the current selection. The change is based on any number of paths. TreeSelectionListeners will generally query the source of the event for the new selected status of each potentially changed row.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @see TreeSelectionListener @see javax.swing.tree.TreeSelectionModel @version 1.
15 0822 02/2802/9800 @author Scott Violet
The listener that's notified when the selection in a TreeSelectionModel changes. For more information and examples see How to Write a Tree Selection Listener a section in The Java Tutorial. @see javax.swing.tree.TreeSelectionModel @see javax.swing.JTree @version 1.8 0911 02/2102/9800 @author Scott Violet
The listener that's notified when a tree expands or collapses a node. For further information and examples see How to Write a Tree-Will-Expand Listener a section in The Java Tutorial. @version 1.3 086 02/2602/9800 @author Scott Violet
An event indicating that an operation which can be undone has occurred.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. A future release of Swing will provide support for long term persistence. @version 1.
12 0814 02/2802/9800 @author Ray Ryan
Interface implemented by a class interested in hearing about undoable operations. @version 1.11 0813 02/2602/9800 @author Ray Ryan