# NavigationEventState

# NavigationEventState

Artifact:[androidx.navigationevent:navigationevent-compose](https://developer.android.com/jetpack/androidx/releases/navigationevent)  
[View Source](https://cs.android.com/search?q=file:androidx/navigationevent/compose/NavigationEventState.kt+class:androidx.navigationevent.compose.NavigationEventState)  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/navigationevent#1.0.0)
Common/All
  - Cmn  

  ```
  class NavigationEventState<T : NavigationEventInfo>
  ```

*** ** * ** ***

This class serves as the Compose-layer adapter for the navigation event system. It holds the developer-defined history partitions ([currentInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#currentInfo()),[backInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#backInfo()),[forwardInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#forwardInfo())) and is updated with the local[transitionState](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#transitionState())by the[NavigationEventHandler](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventHandler)it is provided to.

This object is created via[rememberNavigationEventState](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/package-summary#rememberNavigationEventState(androidx.navigationevent.NavigationEventInfo,kotlin.collections.List,kotlin.collections.List))and consumed by[NavigationEventHandler](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventHandler)to link the hoisted history state with the active handler's callbacks and gesture state.  

|                                                                                                                                                 See also                                                                                                                                                  |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---|
| [NavigationEventHandler](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/package-summary#NavigationEventHandler(androidx.navigationevent.compose.NavigationEventState,kotlin.Boolean,kotlin.Function0,kotlin.Function0,kotlin.Boolean,kotlin.Function0,kotlin.Function0)) |   |

## Summary

|                                                          ### Public properties                                                           |
|------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|
| [List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)`<T>`                                           | [backInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#backInfo()) A list of destinations the user may navigate back to.                  | Cmn |
| `T`                                                                                                                                      | [currentInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#currentInfo()) The contextual information for the currently active destination. | Cmn |
| [List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)`<T>`                                           | [forwardInfo](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#forwardInfo()) A list of destinations the user may navigate forward to.         | Cmn |
| [NavigationEventTransitionState](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventTransitionState) | [transitionState](https://developer.android.com/reference/kotlin/androidx/navigationevent/compose/NavigationEventState#transitionState()) The current physical gesture state from the dispatcher.  | Cmn |

## Public properties

### backInfo

Cmn  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/navigationevent#1.0.0)  

```
val backInfo: List<T>
```

A list of destinations the user may navigate back to.  

### currentInfo

Cmn  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/navigationevent#1.0.0)  

```
val currentInfo: T
```

The contextual information for the currently active destination.  

### forwardInfo

Cmn  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/navigationevent#1.0.0)  

```
val forwardInfo: List<T>
```

A list of destinations the user may navigate forward to.  

### transitionState

Cmn  
Added in[1.0.0](https://developer.android.com/jetpack/androidx/releases/navigationevent#1.0.0)  

```
val transitionState: NavigationEventTransitionState
```

The current physical gesture state from the dispatcher. This value is collected from the local[NavigationEventHandler](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventHandler)and will be either[NavigationEventTransitionState.Idle](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventTransitionState.Idle)or[NavigationEventTransitionState.InProgress](https://developer.android.com/reference/kotlin/androidx/navigationevent/NavigationEventTransitionState.InProgress). This property will update frequently during a gesture.