Package io.jmix.flowui
Class ViewNavigators
java.lang.Object
io.jmix.flowui.ViewNavigators
Provides fluent interface for navigating to views.
-
Field Summary
Modifier and TypeFieldDescriptionprotected DetailViewNavigationProcessor
protected ListViewNavigationProcessor
protected ViewNavigationProcessor
-
Constructor Summary
ConstructorDescriptionViewNavigators
(DetailViewNavigationProcessor detailViewNavigationProcessor, ListViewNavigationProcessor listViewNavigationProcessor, ViewNavigationProcessor viewNavigationProcessor) -
Method Summary
Modifier and TypeMethodDescription<E> DetailViewNavigator<E>
detailView
(EntityPickerComponent<E> picker) Creates a detail view navigator to edit an entity selected in the picker component.<E> DetailViewNavigator<E>
detailView
(ListDataComponent<E> listDataComponent) Creates a detail view navigator to edit an entity selected in the list component.<E> DetailViewNavigator<E>
detailView
(Class<E> entityClass) Creates a detail view navigator for an entity class.protected <E> Class<E>
getBeanType
(EntityPickerComponent<E> picker) protected <E> Class<E>
getBeanType
(ListDataComponent<E> listDataComponent) <E> ListViewNavigator<E>
Creates a list view navigator for an entity class.Creates a view navigator.Creates a view navigator.
-
Field Details
-
Constructor Details
-
Method Details
-
detailView
Creates a detail view navigator for an entity class.Example of navigating to a view for editing an entity:
viewNavigators.detailView(Customer.class) .editEntity(customersTable.getSingleSelectedItem()) .withViewClass(CustomerDetailView.class) .navigate();
Example of navigating to a view for creating a new entity instance:
viewNavigators.detailView(Customer.class) .newEntity() .withViewClass(CustomerDetailView.class) .navigate();
- Parameters:
entityClass
- edited entity class
-
detailView
Creates a detail view navigator to edit an entity selected in the list component.- Parameters:
listDataComponent
- the component which provides a selected entity to edit- See Also:
-
detailView
Creates a detail view navigator to edit an entity selected in the picker component.- Parameters:
picker
- the component which provides an entity to edit- See Also:
-
listView
Creates a list view navigator for an entity class.Example of navigating to a view for editing an entity and returning to the calling view:
viewNavigators.listView(Customer.class) .withViewClass(CustomerListView.class) .withBackwardNavigation(true) .navigate();
- Parameters:
entityClass
- edited entity class
-
view
Creates a view navigator.- Parameters:
viewClass
- class of the view to navigate to
-
view
Creates a view navigator.- Parameters:
viewId
- id of the view to navigate to (as set in theViewController
annotation)
-
getBeanType
-
getBeanType
-