tripkit-android / com.skedgo.tripkit.routing / TripGroup
TripGroup
open class TripGroup
Represents a list of [`Trip`](../-trip/index.md)s. A list of
Trip
s comprises of a display trip (aka representative trip) and alternative trips. A display trip can be accessed via [`#getDisplayTrip()`](get-display-trip.md) while alternative trips can be retrieved via
#getTrips()
minus [`#getDisplayTrip()`](get-display-trip.md). That's because
#getTrips()
returns a list of `[
Trip`](../-trip/index.md)s including alternative trips and display trip.
Besides, a [`TripGroup`](./index.md) also hold info related to
Source
via `[
#getSources()`](get-sources.md).
Constructors
Name | Summary |
---|---|
<init> | Represents a list of [`Trip`](../-trip/index.md)s. A list of Trip s comprises of a display trip (aka representative trip) and alternative trips. A display trip can be accessed via [`#getDisplayTrip()`](get-display-trip.md) while alternative trips can be retrieved via #getTrips() minus [`#getDisplayTrip()`](get-display-trip.md). That's because #getTrips() returns a list of `[ Trip](../-trip/index.md)s including alternative trips and display trip. TripGroup()` |
Functions
Name | Summary |
---|---|
addAsDisplayTrip | A sample use case: Add a trip computed by waypoint API into trip list.open fun addAsDisplayTrip(trip: Trip ): Unit |
addTrip | open fun addTrip(trip: Trip !): Unit |
changeDisplayTrip | open fun changeDisplayTrip(trip: Trip ): TripGroup ! |
getDisplayTrip | open fun getDisplayTrip(): Trip ? |
getDisplayTripId | open fun getDisplayTripId(): Long |
getFrequency | open fun getFrequency(): Int |
getSources | open fun getSources(): MutableList < Source !>? |
getTrips | open fun getTrips(): ArrayList < Trip !>? |
getVisibility | open fun getVisibility(): GroupVisibility ! |
setDisplayTripId | open fun setDisplayTripId(displayTripId: Long ): Unit |
setFrequency | open fun setFrequency(frequency: Int ): Unit |
setSources | open fun setSources(sources: MutableList < Source !>?): Unit |
setTrips | open fun setTrips(trips: ArrayList < Trip !>!): Unit |
setVisibility | open fun setVisibility(visibility: GroupVisibility ): Unit |
uuid | open fun uuid(uuid: String !): Unit open fun uuid(): String ! |
Extension Functions
Name | Summary |
---|---|
containsAnyMode | fun TripGroup .containsAnyMode(modeIds: List < String >): Boolean |
containsMode | fun TripGroup .containsMode(modeId: String ): Boolean |
getTrip | fun TripGroup .getTrip(tripId: Long ): Trip ? |