Class EventDispatchTreeImpl

java.lang.Object
com.sun.javafx.event.EventDispatchTreeImpl
All Implemented Interfaces:
EventDispatchTree, EventDispatchChain

public final class EventDispatchTreeImpl extends Object implements EventDispatchTree
  • Constructor Details

    • EventDispatchTreeImpl

      public EventDispatchTreeImpl()
  • Method Details

    • reset

      public void reset()
    • createTree

      public EventDispatchTree createTree()
      Specified by:
      createTree in interface EventDispatchTree
    • mergeTree

      public EventDispatchTree mergeTree(EventDispatchTree tree)
      Specified by:
      mergeTree in interface EventDispatchTree
    • append

      public EventDispatchTree append(EventDispatcher eventDispatcher)
      Description copied from interface: EventDispatchChain
      Appends the specified EventDispatcher to this chain. Returns a reference to the chain with the appended element.

      The caller shouldn't assume that this EventDispatchChain remains unchanged nor that the returned value will reference a different chain after the call. All this depends on the EventDispatchChain implementation.

      So the call should be always done in the following form: chain = chain.append(eventDispatcher);

      Specified by:
      append in interface EventDispatchChain
      Specified by:
      append in interface EventDispatchTree
      Parameters:
      eventDispatcher - the EventDispatcher to append to the chain
      Returns:
      the chain with the appended event dispatcher
    • prepend

      public EventDispatchTree prepend(EventDispatcher eventDispatcher)
      Description copied from interface: EventDispatchChain
      Prepends the specified EventDispatcher to this chain. Returns a reference to the chain with the prepended element.

      The caller shouldn't assume that this EventDispatchChain remains unchanged nor that the returned value will reference a different chain after the call. All this depends on the EventDispatchChain implementation.

      So the call should be always done in the following form: chain = chain.prepend(eventDispatcher);

      Specified by:
      prepend in interface EventDispatchChain
      Specified by:
      prepend in interface EventDispatchTree
      Parameters:
      eventDispatcher - the EventDispatcher to prepend to the chain
      Returns:
      the chain with the prepended event dispatcher
    • dispatchEvent

      public Event dispatchEvent(Event event)
      Description copied from interface: EventDispatchChain
      Dispatches the specified event through this EventDispatchChain. The return value represents the event after processing done by the chain. If further processing is to be done after the call the event referenced by the return value should be used instead of the original event. In the case the event is fully handled / consumed in the chain the returned value is null and no further processing should be done with that event.
      Specified by:
      dispatchEvent in interface EventDispatchChain
      Parameters:
      event - the event to dispatch
      Returns:
      the processed event or null if the event had been fully handled / consumed
    • toString

      public String toString()
      Overrides:
      toString in class Object