java.beans
Class IndexedPropertyChangeEvent

java.lang.Object
  extended by java.util.EventObject
      extended by java.beans.PropertyChangeEvent
          extended by java.beans.IndexedPropertyChangeEvent
All Implemented Interfaces:
Serializable

public class IndexedPropertyChangeEvent
extends PropertyChangeEvent

This is like a PropertyChangeEvent, but also carries with it the index of the property which changed.

Since:
1.5
See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
IndexedPropertyChangeEvent(Object source, String name, Object oldValue, Object newValue, int index)
          Create a new IndexedPropertyChangeEvent.
 
Method Summary
 int getIndex()
          Return the index of the changed property.
 
Methods inherited from class java.beans.PropertyChangeEvent
getNewValue, getOldValue, getPropagationId, getPropertyName, setPropagationId
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IndexedPropertyChangeEvent

public IndexedPropertyChangeEvent(Object source,
                                  String name,
                                  Object oldValue,
                                  Object newValue,
                                  int index)
Create a new IndexedPropertyChangeEvent.

Parameters:
source - the Bean containing the property
name - the property's name
oldValue - the old value of the property
newValue - the new value of the property
index - the index of the element in the property which changed
Throws:
IllegalArgumentException - if source is null
Method Detail

getIndex

public int getIndex()
Return the index of the changed property.

Returns:
the index