Class CustomEventParams.Builder

java.lang.Object
com.teamdev.jxbrowser.dom.event.CustomEventParams.Builder
Enclosing interface:
CustomEventParams

public static final class CustomEventParams.Builder extends Object
A builder of CustomEventParams.

Builders are created by invoking EventParams.newBuilder(). Each of the setter methods modifies the state of the builder and returns the same instance. Builders are not thread-safe and should not be used concurrently from multiple threads without external synchronization.

Since:
8.0.0
  • Method Details

    • detail

      public CustomEventParams.Builder detail(Object detail)
      Sets the payload of the custom event.

      It is converted to a JavaScript type based on the following rules: Java to JavaScript.

      Parameters:
      detail - the payload
      Returns:
      this builder
    • eventParams

      public CustomEventParams.Builder eventParams(EventParams eventParams)
      Sets the generic event parameters for this custom event.
      Parameters:
      eventParams - the generic event parameters
      Returns:
      this builder
    • build

      public CustomEventParams build()
      Returns a new CustomEventParams instance built from the current state of this builder.
      Returns:
      a new EventParams instance