FileDocCategorySizeDatePackage
EventObject.javaAPI DocJava SE 5 API1558Fri Aug 26 14:57:22 BST 2005java.util

EventObject

public class EventObject extends Object implements Serializable

The root class from which all event state objects shall be derived.

All Events are constructed with a reference to the object, the "source", that is logically deemed to be the object upon which the Event in question initially occurred upon.

since
JDK1.1

Fields Summary
private static final long
serialVersionUID
protected transient Object
source
The object on which the Event initially occurred.
Constructors Summary
public EventObject(Object source)
Constructs a prototypical Event.

param
source The object on which the Event initially occurred.
exception
IllegalArgumentException if source is null.


                                     
       
	if (source == null)
	    throw new IllegalArgumentException("null source");

        this.source = source;
    
Methods Summary
public java.lang.ObjectgetSource()
The object on which the Event initially occurred.

return
The object on which the Event initially occurred.

        return source;
    
public java.lang.StringtoString()
Returns a String representation of this EventObject.

return
A a String representation of this EventObject.

        return getClass().getName() + "[source=" + source + "]";