public void SetupNavigation(PhoneApplicationFrame rootFrame)
        {
            var navigation = new FluentNavigation(rootFrame);

            navigation.WhenNavigatedTo <LoginPage>()
            .ThenTo <AccountCreatePage>()
            .ThenToAnyPage()
            .RemoveEntriesFromBackStack(2);

            navigation.WhenNavigatedTo <LoginPage>()
            .ThenTo <AccountCreatePage>()
            .RemoveEntriesFromBackStack(0);

            navigation.WhenNavigatedTo <LoginPage>()
            .ThenToAnyPage()
            .RemoveEntriesFromBackStack(1);

            navigation.WhenNavigatedTo <AccountCreatePage>()
            .ThenToAnyPage()
            .RemoveEntriesFromBackStack(1);

            navigation.WhenNavigatedTo <OrderConfirmPage>()
            .ThenTo <MainPage>()
            .RemoveEntriesFromBackStack(2);
        }
        private void RegisterNavigation()
        {
            var fluentNavigation = new FluentNavigation(RootFrame);

            fluentNavigation.WhenNavigatedTo <MainPage>()
            .ThenTo <UserProfilePage>()
            .RemoveEntriesFromBackStack(1);

            fluentNavigation.WhenNavigatedTo <UserProfilePage>()
            .ThenTo <MainPage>()
            .RemoveEntriesFromBackStack(1);
        }
        private void RegisterNavigationCoercion()
        {
            var fluent = new FluentNavigation(RootFrame);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <BookmarksPivot>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <ContentsPage>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <SearchInBookPage>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <BookmarksPivot>()
            .ThenTo <BookmarkSearchPage>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(3);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(1);

            fluent.WhenNavigatedTo <ReadPage>()
            .ThenTo <BookInfoPage>()
            .ThenTo <ReadPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <CatalogPage>()
            .ThenTo <AuthorizationPage>()
            .ThenTo <CatalogPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <BookInfoPage>()
            .ThenTo <AuthorizationPage>()
            .ThenTo <BookInfoPage>()
            .RemoveEntriesFromBackStack(2);

            fluent.WhenNavigatedTo <BookInfoPage>()
            .ThenTo <WebBrowserPage>()
            .ThenTo <BookInfoPage>()
            .RemoveEntriesFromBackStack(2);
        }