# RoutingStateMixins

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-reactiveui/routing/trait-routingstatemixins/

**trait** · [`ferroui-reactiveui`](/docs/0.5.0/api/ferroui-reactiveui/) · v0.5.0

```rust
trait RoutingStateMixins
```

Queries of the navigation stack of a [`RoutingState`](/docs/0.5.0/api/ferroui-reactiveui/routing/struct-routingstate/) (`RoutingStateMixins`).

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.ReactiveUI/routing/routing_state_mixins.rs#L9)

## Members

- [`find_view_model_in_stack`](#function-find_view_model_in_stack)
- [`get_current_view_model`](#function-get_current_view_model)

<a id="function-find_view_model_in_stack"></a>

### find_view_model_in_stack

```rust
fn find_view_model_in_stack<T: IRoutableViewModel>(self: &Self) -> Option<Rc<T>>
```

The view model of the type `T` nearest the top of the stack, or `None` when the stack has
none (`FindViewModelInStack<T>()`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.ReactiveUI/routing/routing_state_mixins.rs#L12)

<a id="function-get_current_view_model"></a>

### get_current_view_model

```rust
fn get_current_view_model(self: &Self) -> Option<RoutableViewModel>
```

The view model on top of the stack, or `None` when it is empty (`GetCurrentViewModel()`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.ReactiveUI/routing/routing_state_mixins.rs#L15)

## Trait implementations

- [`RoutingStateMixins`](/docs/0.5.0/api/ferroui-reactiveui/routing/trait-routingstatemixins/)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
