Interface INavigationService
Represents a contract with a FrameworkElement that contains INavigationView.
Through defined INavigationViewPageProvider service allows you to use the Dependency Injection pattern in WPF UI navigation.
public interface INavigationService- Extension Methods
Methods
GetNavigationControl()
Provides direct access to the control responsible for navigation.
INavigationView GetNavigationControl()Returns
- INavigationView
- Instance of the INavigationView control. 
GoBack()
Navigates the NavigationView to the previous journal entry.
bool GoBack()Returns
Navigate(string)
Lets you navigate to the selected page based on it's tag. Should be used with INavigationViewPageProvider.
bool Navigate(string pageIdOrTargetTag)Parameters
- pageIdOrTargetTagstring
- Id or tag of the page. 
Returns
Navigate(string, object?)
Lets you navigate to the selected page based on it's tag. Should be used with INavigationViewPageProvider.
bool Navigate(string pageIdOrTargetTag, object? dataContext)Parameters
Returns
Navigate(Type)
Lets you navigate to the selected page based on it's type. Should be used with INavigationViewPageProvider.
bool Navigate(Type pageType)Parameters
- pageTypeType
- Typeof the page.
Returns
Navigate(Type, object?)
Lets you navigate to the selected page based on it's type, Should be used with INavigationViewPageProvider.
bool Navigate(Type pageType, object? dataContext)Parameters
Returns
NavigateWithHierarchy(Type)
Synchronously adds an element to the navigation stack and navigates current navigation Frame to the
bool NavigateWithHierarchy(Type pageType)Parameters
- pageTypeType
- Type of control to be synchronously added to the navigation stack 
Returns
NavigateWithHierarchy(Type, object?)
Synchronously adds an element to the navigation stack and navigates current navigation Frame to the
bool NavigateWithHierarchy(Type pageType, object? dataContext)Parameters
- pageTypeType
- Type of control to be synchronously added to the navigation stack 
- dataContextobject
- DataContext object 
Returns
SetNavigationControl(INavigationView)
Lets you attach the control that represents the INavigationView.
void SetNavigationControl(INavigationView navigation)Parameters
- navigationINavigationView
- Instance of the INavigationView.