Package com.teamdev.jxbrowser.dom.event
Interface CustomEventParams
- All Superinterfaces:
EventParams
The parameters of the custom DOM event.
- Since:
- 7.21
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder ofCustomEventParams. -
Method Summary
Modifier and TypeMethodDescriptiondefault <T> Tdetail()Returns the payload of the custom event.default booleanReturnstrueif the event bubbles up through the DOM.default booleanReturnstrueif the event can be canceled, and therefore prevented as if the event never happened.default booleanReturnstrueif the event is trusted, and therefore was generated by a user action.static CustomEventParams.BuildernewBuilder(Document document) Creates a newCustomEventParamsbuilder.
-
Method Details
-
newBuilder
Creates a newCustomEventParamsbuilder.- Parameters:
document- The document where this event will be dispatched.- Returns:
- a new
CustomEventParams.Builderinstance - Since:
- 8.0.0
-
isBubbles
default boolean isBubbles()Description copied from interface:EventParamsReturnstrueif the event bubbles up through the DOM.- Specified by:
isBubblesin interfaceEventParams
-
isCancelable
default boolean isCancelable()Description copied from interface:EventParamsReturnstrueif the event can be canceled, and therefore prevented as if the event never happened.- Specified by:
isCancelablein interfaceEventParams
-
isTrusted
default boolean isTrusted()Description copied from interface:EventParamsReturnstrueif the event is trusted, and therefore was generated by a user action.- Specified by:
isTrustedin interfaceEventParams
-
detail
default <T> T detail()Returns the payload of the custom event.The type mapping rules are the following:
| JavaScript | Java | |--------------------|----------------| | Number | Double | | BigInt | BigInteger | | String | String | | Boolean | Boolean | | Symbol | JsSymbol | | null and undefined | null | | Node | JsObject, Node | | ArrayBuffer | JsArrayBuffer | | Array | JsArray | | Set | JsSet | | Map | JsMap | | Object | JsObject | | Proxy Object | Object |
Proxy objects are mapped to the corresponding injected Java object.
- Type Parameters:
T- the result type according to the type mapping rules- Returns:
- the object from the
detailfield of theCustomEvent.
-