Class NavigationState

java.lang.Object
io.jmix.ui.navigation.NavigationState

public class NavigationState extends Object
Immutable object of this class represents some navigation state determined by URL fragment.

For example, if URL is:


   http://host:port/app/#main/12/orders/view?id=a9fc2d30b51ef30b7e4b5a1c2d
 
URL fragment will be:

   main/12/orders/view?id=a9fc2d30b51ef30b7e4b5a1c2d
 
Where:
   main - root screen route (in this case route of AppMainWindow)
   12 - URL state mark
   orders/view - route of nested screen (or screens)
   id=a9fc2d30b51ef30b7e4b5a1c2d - parameter
 
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • getRoot

      public String getRoot()
    • getStateMark

      public String getStateMark()
    • getNestedRoute

      public String getNestedRoute()
    • getParams

      @Nullable public Map<String,String> getParams()
    • getParamsString

      public String getParamsString()
      Returns:
      joined by "&" sign URL params, or empty string if no params for this state
    • asRoute

      public String asRoute()
      Returns:
      current state combined into URL fragment, e.g. main/0/orders?status=shipped
    • equals

      public boolean equals(Object that)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object