public class Event extends Object
| Constructor and Description |
|---|
Event() |
Event(Event source)
Copy constructor.
|
Event(String type)
Create an event of the specified type with no target and no data.
|
Event(String type,
BaseComponent target)
Create an event of the specified type and target with no data.
|
Event(String type,
BaseComponent target,
BaseComponent relatedTarget)
Create an event of the specified type, target, and related target with no data.
|
Event(String type,
BaseComponent target,
BaseComponent relatedTarget,
Object data)
Create an event of the specified type, target, related target, and data.
|
Event(String type,
BaseComponent target,
Object data)
Create an event of the specified type, target, and data.
|
Event(String type,
Event source)
Copy constructor, but with explicit type.
|
| Modifier and Type | Method and Description |
|---|---|
BaseComponent |
getCurrentTarget()
Returns the event's current target (the component that handled the event).
|
Object |
getData()
Returns arbitrary data associated with the event, if any.
|
Page |
getPage()
Returns the page associated with the event.
|
BaseComponent |
getRelatedTarget()
Returns the event's related target, if any.
|
BaseComponent |
getTarget()
Returns the event's target (the component on which the event occurred).
|
String |
getTargetId()
Returns the id of the DOM element that was the actual target of the event.
|
String |
getType()
Returns the type of event.
|
boolean |
isStopped()
Returns true if propagation has been stopped.
|
void |
stopPropagation()
Flags the event to prevent further propagation in the event handler chain.
|
public Event()
public Event(String type)
type - The event type.public Event(String type, BaseComponent target)
type - The event type.target - The target of the event.public Event(String type, BaseComponent target, Object data)
type - The event type.target - The target of the event.data - Arbitrary data to associate with the event.public Event(String type, BaseComponent target, BaseComponent relatedTarget)
type - The event type.target - The target of the event.relatedTarget - The related target that participated in the event.public Event(String type, BaseComponent target, BaseComponent relatedTarget, Object data)
type - The event type.target - The target of the event.relatedTarget - The related target that participated in the event.data - Arbitrary data to associate with the event.public Event(Event source)
source - Source event to copy.public Page getPage()
public String getType()
public BaseComponent getTarget()
public BaseComponent getCurrentTarget()
public BaseComponent getRelatedTarget()
mouseenter
event, the target is the component entered; the related target is the component exited.public String getTargetId()
public Object getData()
public void stopPropagation()
public boolean isStopped()
Copyright © 2017 Regenstrief Center for Biomedical Informatics. All rights reserved.