|
xArch/xADL 2.0 Data Binding Library | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.uci.isr.xarch.XArchEvent
An event object that is broadcast to XArchListeners
when an xArch element changes.
| Field Summary | |
static int |
ADD_EVENT
Event type used when an element is added. |
static int |
ATTRIBUTE_CHANGED
Source type used when an attribute changes. |
static int |
CLEAR_EVENT
Event type used when an element or set of elements is cleared. |
static int |
ELEMENT_CHANGED
Source type used when an element changes. |
protected int |
eventType
|
protected boolean |
isAttached
true if the source of the event is attached to the
xArch element in the context, false otherwise. |
static int |
PROMOTE_EVENT
Event type used when an element is promoted |
static int |
REMOVE_EVENT
Event type used when an element is removed. |
static int |
SET_EVENT
Event type used when an element is set |
static int |
SIMPLE_TYPE_VALUE_CHANGED
Source type used when a simple type's value changes. |
protected IXArchElement |
src
|
protected int |
srcType
|
protected Object |
target
This is a string with the value if srcType = ATTRIBUTE_CHANGED, a string with the value srcType = SIMPLE_TYPE_VALUE_CHANGED, otherwise it's an IXArchElement if srcType = ELEMENT_CHANGED. |
protected String |
targetName
|
| Constructor Summary | |
XArchEvent(IXArchElement src,
int eventType,
int srcType,
String targetName,
Object target,
boolean isAttached)
Create a new xArch event. |
|
| Method Summary | |
int |
getEventType()
Get the event type of this event. |
boolean |
getIsAttached()
Determine whether the changed xArch element is currently attached to (has as an ancestor) the xArch element that emits this event. |
IXArchElement |
getSource()
Get the source xArch element of this event. |
int |
getSourceType()
Get the source type of this event. |
Object |
getTarget()
Get the target of this event. |
String |
getTargetName()
Get the target name of this event. |
void |
setEventType(int eventType)
Set the event type of this event. |
void |
setIsAttached(boolean isAttached)
Set whether the changed xArch element is currently attached to (has as an ancestor) the xArch element that emitted this event. |
void |
setSource(IXArchElement src)
Set the source of this event. |
void |
setSourceType(int srcType)
Set the source type of this event. |
void |
setTarget(Object target)
Set the target of this event. |
void |
setTargetName(String targetName)
Set the target name of this event. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final int SET_EVENT
public static final int CLEAR_EVENT
public static final int ADD_EVENT
public static final int REMOVE_EVENT
public static final int PROMOTE_EVENT
public static final int ATTRIBUTE_CHANGED
public static final int ELEMENT_CHANGED
public static final int SIMPLE_TYPE_VALUE_CHANGED
protected IXArchElement src
protected int eventType
protected int srcType
protected String targetName
protected Object target
protected boolean isAttached
true if the source of the event is attached to the
xArch element in the context, false otherwise.
| Constructor Detail |
public XArchEvent(IXArchElement src,
int eventType,
int srcType,
String targetName,
Object target,
boolean isAttached)
src - xArch element that is the source of this event (i.e. that
changed.)eventType - One of the event types (above) that indicates what
happened.srcType - One of the event types (above) that indicates what
changed.targetName - Name of the element or attribute that was
set/added/cleared/removed.target - The attribute/element/value that was
set/added/cleared/removed.isAttached - true if the element that was changed is
actually connected to the xArch element emitting this event or not.| Method Detail |
public void setSource(IXArchElement src)
src - Source of this event.public IXArchElement getSource()
public void setEventType(int eventType)
eventType - Event type.public int getEventType()
public void setSourceType(int srcType)
srcType - Source type.public int getSourceType()
public void setTargetName(String targetName)
targetName - Target name.public String getTargetName()
public void setTarget(Object target)
target - Event target.public Object getTarget()
public void setIsAttached(boolean isAttached)
isAttached - Whether the changed element is attached or not.public boolean getIsAttached()
true if it is attached, false
otherwise.
|
xArch/xADL 2.0 Data Binding Library | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||