PreviewPublicTransportRouteViewModel

Properties

Link copied to clipboard
open override val departure: DepartureInfo

Information about the starting point of the route.

Link copied to clipboard
open override val destination: DestinationInfo

Detailed information about the final destination, including the stop, address, and arrival time.

Link copied to clipboard
open override val destinationTimeZone: TimeZone

Timezone of the route's destination point.

Link copied to clipboard
open override val isStopsListExpanded: StateFlow<Boolean>

Indicates whether the list of intermediate stops is currently expanded (visible) or collapsed (hidden).

Link copied to clipboard
open override val routeSegments: MutableStateFlow<List<RouteSegment>>

Ordered list of route segments that together form the complete journey. Each element represents a contiguous part of the route between two points. The sequence follows chronological order from departure to arrival.

Link copied to clipboard
open override val totalDuration: Duration

Total travel duration from start to end of the route. Excludes waiting times and transfer times.

Link copied to clipboard
open override val totalFare: FareInfo? = null

Total fare for the entire journey. Includes both the amount and the currency for proper formatting.

Functions

Link copied to clipboard
open override fun onBackButtonClick()

Handles the user action of clicking the "Back" button in the route card.

Link copied to clipboard
open override fun onStartNavigation()

Handles the user action of starting navigation along the currently selected public transport route.

Link copied to clipboard
open override fun onWalkNavigatorClick()

Handles the user action of clicking the "Pedestrian Navigator" button.

Link copied to clipboard
open override fun setStopsListExpanded(value: Boolean)

Update state of the intermediate stops list.