Class ViewBeforeLeaveEvent

  • All Implemented Interfaces:
    java.io.Serializable

    public class ViewBeforeLeaveEvent
    extends java.util.EventObject
    Event sent to the View instance before navigating away from it.

    Provides a navigate() method which must be called for the navigation to take place.

    Since:
    8.1
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class java.util.EventObject

        source
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected boolean isNavigateRun()
      Checks if the navigate command has been executed.
      void navigate()
      Performs the navigation which triggered the event in the first place.
      • Methods inherited from class java.util.EventObject

        getSource, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ViewBeforeLeaveEvent

        public ViewBeforeLeaveEvent​(Navigator navigator,
                                    ViewLeaveAction action)
        Creates a new event instance for the given navigator.
        Parameters:
        navigator - the navigator instance
        action - the command to execute when calling navigate()
    • Method Detail

      • navigate

        public void navigate()
        Performs the navigation which triggered the event in the first place.
      • isNavigateRun

        protected boolean isNavigateRun()
        Checks if the navigate command has been executed.
        Returns:
        true if navigate() has been called, false otherwise