Package io.github.mmm.ui.api.controller
Interface UiNavigationManager
- All Superinterfaces:
io.github.mmm.event.EventSource<UiNavigationEvent,UiNavigationEventListener>
public interface UiNavigationManager
extends io.github.mmm.event.EventSource<UiNavigationEvent,UiNavigationEventListener>
Interface to manage
UiControllers.- Since:
- 1.0.0
-
Method Summary
Modifier and TypeMethodDescriptionstatic UiNavigationManagerget()<W extends io.github.mmm.ui.api.widget.UiRegularWidget>
UiController<W> getController(String id) default <W extends io.github.mmm.ui.api.widget.UiRegularWidget>
UiController<W> This method navigates back in the history to theUiPlacethat has been visited before.This method navigates forward in the history.default voidnavigateTo(UiPlace place) Navigates to the givenUiPlace.voidnavigateTo(UiPlace place, boolean replace) Navigates to the givenUiPlace.voidupdatePlace(UiPlace place) Replaces thecurrent placewith the givenUiPlacewithout creating a new entry in the navigation history.Methods inherited from interface io.github.mmm.event.EventSource
addListener, addListener, addWeakListener, removeListener
-
Method Details
-
getController
- Type Parameters:
W- type of theview.- Parameters:
id- theIDof the requestedUiController.- Returns:
- the requested
UiControllerornullif no suchUiControllerexists.
-
getRequiredController
default <W extends io.github.mmm.ui.api.widget.UiRegularWidget> UiController<W> getRequiredController(String id) - Type Parameters:
W- type of theview.- Parameters:
id- theIDof the requestedUiController.- Returns:
- the requested
UiController. - Throws:
io.github.mmm.base.exception.ObjectNotFoundException- if noUiControllerexists with the givenid.
-
getCurrentPlace
UiPlace getCurrentPlace()- Returns:
- the current
UiPlace. Will benulluntil initialized by firstnavigation.
-
updatePlace
Replaces thecurrent placewith the givenUiPlacewithout creating a new entry in the navigation history.- Parameters:
place- the updatedUiPlace. Currently theIDof thecurrent placemay not change. This is only to updateparameters. E.g. if you want to represent the selection of a master-detail dialog in the location (URL) you can use aparameter. This method allows to update theUiPlaceand therefore the location without adding it to the history sonavigateBack()navigating back} is not replaying the entire history of the end-users selection what is typically undesired.
-
get
- Returns:
- the instance of this
UiNavigationManager.
-