public class ModelChangedEvent extends Object implements IModelChangedEvent
IModelChangedEventCHANGE, INSERT, REMOVE, WORLD_CHANGED| Constructor and Description |
|---|
ModelChangedEvent(IModelChangeProvider provider,
int type,
Object[] objects,
String changedProperty)
The constructor of the event.
|
ModelChangedEvent(IModelChangeProvider provider,
Object object,
String changedProperty,
Object oldValue,
Object newValue)
A costructor that should be used for changes of object properties.
|
| Modifier and Type | Method and Description |
|---|---|
Object[] |
getChangedObjects()
Returns an array of model objects that are affected by the change.
|
String |
getChangedProperty()
Returns a name of the object's property that has been changed if change
type is CHANGE.
|
IModelChangeProvider |
getChangeProvider()
Returns the provider that fired this event.
|
int |
getChangeType()
Returns the type of change that occured in the model (one of INSERT,
REMOVE, CHANGE or
WORLD_CHANGED ).
|
Object |
getNewValue()
When model change is of type CHANGE, this method is used to
obtain the new value of the property (after the change).
|
Object |
getOldValue()
When model change is of type CHANGE, this method is used to
obtain the old value of the property (before the change).
|
public ModelChangedEvent(IModelChangeProvider provider, int type, Object[] objects, String changedProperty)
provider - the change providertype - the event typeobjects - the changed objectschangedProperty - or null if not applicablepublic ModelChangedEvent(IModelChangeProvider provider, Object object, String changedProperty, Object oldValue, Object newValue)
provider - the event providerobject - affected objectchangedProperty - changed property of the affected objectoldValue - the value before the changenewValue - the value after the changepublic IModelChangeProvider getChangeProvider()
IModelChangedEventgetChangeProvider in interface IModelChangedEventpublic Object[] getChangedObjects()
IModelChangedEventgetChangedObjects in interface IModelChangedEventpublic String getChangedProperty()
IModelChangedEventgetChangedProperty in interface IModelChangedEventpublic Object getOldValue()
IModelChangedEventgetOldValue in interface IModelChangedEventpublic Object getNewValue()
IModelChangedEventgetNewValue in interface IModelChangedEventpublic int getChangeType()
IModelChangedEventgetChangeType in interface IModelChangedEvent
Copyright (c) 2000, 2016 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.