@DOMObjectAttribute @DOMNameAttribute(name="CustomEvent") public class CustomEvent extends Event
Events using the CustomEvent interface can be used to carry custom data.
| Modifier and Type | Class and Description |
|---|---|
static class |
CustomEvent.CustomEventInit
Represents a dictionary that is having optional arguments for setting the detail information about the event.
|
Event.EventInitAT_TARGET_PHASE, BUBBLING_PHASE, CAPTURING_PHASE, NONE_PHASEPropertyChanged, PropertyChangedDelegate| Constructor and Description |
|---|
CustomEvent(java.lang.String type)
Initializes a new instance of the
CustomEvent class. |
CustomEvent(java.lang.String type,
CustomEvent.CustomEventInit eventInitDict)
Initializes a new instance of the
CustomEvent class. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
getDetail()
Gets the custom data.
|
void |
initCustomEvent(java.lang.String type,
boolean bubbles,
boolean cancelable,
java.lang.Object detail)
/// The
Event.initEvent(String, boolean, boolean) method is used to initialize the value of an Event created through the IDocumentEvent interface. |
createDOMContentLoadedEvent, createError, createEvent, createEvent, createEventByType, dispatch, getBubbles, getCancelable, getCurrentTarget, getDefaultPrevented, getEventPhase, getTarget, getTimeStamp, getType, initEvent, isTrusted, preventDefault, setCurrentTarget, setEventPhase, setTarget, stopImmediatePropagation, stopPropagationfireNotifyPropertyChanged, getCurrentValues, getRuntimesBinding, setCurrentValues, setField, setRuntimesBindingpublic CustomEvent(java.lang.String type)
Initializes a new instance of the CustomEvent class.
type - The event type.public CustomEvent(java.lang.String type,
CustomEvent.CustomEventInit eventInitDict)
Initializes a new instance of the CustomEvent class.
type - The event type.eventInitDict - The event initialize dictionary.@DOMNameAttribute(name="detail") public java.lang.Object getDetail()
Gets the custom data.
Value: The detail.@DOMNameAttribute(name="initCustomEvent") public void initCustomEvent(java.lang.String type, boolean bubbles, boolean cancelable, java.lang.Object detail)
/// The Event.initEvent(String, boolean, boolean) method is used to initialize the value of an Event created through the IDocumentEvent interface.
type - The event type.bubbles - if set to true [bubbles].cancelable - if set to true [cancelable].detail - The custom data.
IEventTarget.dispatchEvent(com.aspose.html.dom.events.Event) method,
though it may be called multiple times during that phase if necessary.
If called multiple times the final invocation takes precedence.
If called from a subclass of Event interface only the values specified in the initEvent method are modified, all other attributes are left unchanged.