/tripkit/TripKitAndroidUI/com.skedgo.tripkit.ui.trippreview.nearby/SharedNearbyTripPreviewItemViewModel

SharedNearbyTripPreviewItemViewModel

\ class SharedNearbyTripPreviewItemViewModel@Injectconstructor(regionService: RegionService, locationsApi: LocationsApi) : TripPreviewPagerItemViewModel

Constructors

SharedNearbyTripPreviewItemViewModel @Inject
constructor(regionService: RegionService, locationsApi: LocationsApi)

Properties

Name Summary
action var action: String
actionChosen val actionChosen: PublishRelay<String>
bookingForm var bookingForm: BehaviorRelay<BookingForm>
buttonText val buttonText: ObservableField<String>
closeClicked var closeClicked: TapAction<TripPreviewPagerItemViewModel>
description var description: ObservableField<String>
duration val duration: ObservableField<String>
enableActionButtons val enableActionButtons: ObservableBoolean
externalActionChosen val externalActionChosen: PublishRelay<Action>
externalActions val externalActions: ObservableArrayList<ExternalActionViewModel>
externalActionsBinding val externalActionsBinding: ItemBinding<ExternalActionViewModel>
fromLocation val fromLocation: ObservableField<String>
hasExternalActions val hasExternalActions: ObservableBoolean
hasPickUpWindow val hasPickUpWindow: ObservableField<Boolean>
icon var icon: ObservableField<Drawable>
instructionTitle var instructionTitle: ObservableField<String>
loadedSegment var loadedSegment: TripSegment?
locationDetails var locationDetails: BehaviorRelay<NearbyLocation>
locationList var locationList: BehaviorRelay<List<NearbyLocation>>
message var message: ObservableField<String>
messageTitle var messageTitle: ObservableField<String>
messageVisible var messageVisible: ObservableBoolean
modeIconUrl val modeIconUrl: ObservableField<String>
modeTitle val modeTitle: ObservableField<String>
notes var notes: ObservableField<String>
pickUpWindowMessage val pickUpWindowMessage: ObservableField<String>
requestedDropOff val requestedDropOff: ObservableField<String>
requestedPickUp val requestedPickUp: ObservableField<String>
segment var segment: TripSegment?
showActions val showActions: ObservableBoolean
showDescription var showDescription: ObservableBoolean
showLaunchInMaps var showLaunchInMaps: ObservableBoolean
showLaunchInMapsClicked var showLaunchInMapsClicked: TapStateFlow<TripPreviewPagerItemViewModel>
startDateTime val startDateTime: ObservableField<String>
title var title: ObservableField<String>
toLocation val toLocation: ObservableField<String>

Functions

Name Summary
autoClear fun <T> Observable<T>.autoClear(): Observable<T>
fun Disposable.autoClear()
generateTransportDetails fun generateTransportDetails(): TransportDetails
getModeTitle fun getModeTitle(segment: TripSegment): String
onCleared open override fun onCleared()
This method will be called when this ViewModel is no longer used and will be destroyed.
setSegment open override fun setSegment(context: Context, segment: TripSegment)
withAction fun withAction(context: Context)
fun withAction(isAppInstalled: Boolean)