public interface INavigationRegion : INotifyPropertyChanged The content-type-independent view of a NavigationRegion, for hosts that present a region without knowing its content type. Only NavigationRegion implements it.
Remarks
INotifyPropertyChanged.PropertyChanged is the region's event, with the same property names. The entry in a Committed returned by INavigationRegion.BackAsync, INavigationRegion.ClearAsync or INavigationRegion.ReplaceBorrowedAsync is a NavigationEntry of Object, a different instance from the typed entry in INavigationRegion.CurrentEntry and INavigationRegion.History. Compare entries by INavigationEntry.Id, not by reference.
Properties
CanGoBack
bool CanGoBack { get; } Gets whether a retained entry exists to go back to.
Current
object? Current { get; } Gets the current content, or null when the region is empty.
CurrentEntry
INavigationEntry? CurrentEntry { get; } Gets the current entry, or null when the region is empty.
History
IReadOnlyList<INavigationEntry> History { get; } Gets the retained entries below the current entry, from bottom to top.
IsTransitioning
bool IsTransitioning { get; } Gets whether a transition of this region is in flight.
Methods
BackAsync
ValueTask<NavigationResult<object>> BackAsync(NavigationRequestOptions? options = null, CancellationToken cancellationToken = default) Retires the current entry and resumes the top retained entry.
Remarks
Compare the result's entry with this region's entries by INavigationEntry.Id.
ClearAsync
ValueTask<NavigationResult<object>> ClearAsync(NavigationRequestOptions? options = null, CancellationToken cancellationToken = default) Retires every entry. The region becomes empty.
Remarks
Compare the result's entry with this region's entries by INavigationEntry.Id.
ReplaceBorrowedAsync
ValueTask<NavigationResult<object>> ReplaceBorrowedAsync(object content, NavigationRequestOptions? options = null, CancellationToken cancellationToken = default) Replaces the current entry with borrowed content. For presentation adapters that select existing models without knowing the region's generic content type.
Exceptions
ArgumentExceptionThe content is not assignable to
INavigationRegion.ContentType.
Remarks
The engine runs the same guards and lifetime rules as typed Replace. The caller retains ownership.