public class LearnedTrip extends Trip implements Parcelable
LearnedTrip
is a Trip
learned from the user's driving behavior. LearnedTrip
s
can not be modified, however LearnedTrip
may improve over time as additional observation
of the user's driving behavior is gathered. The LearnedTrip
can be converted/added to a
SavedTrip
to customize notifications and schedule for the preferred route.Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
static Parcelable.Creator<LearnedTrip> |
CREATOR
Parcelable creator for this type.
|
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
Modifier and Type | Method and Description |
---|---|
int |
describeContents() |
boolean |
equals(Object o) |
Date |
getDateTime()
The predicted arrival date/time of this
LearnedTrip instance (UTC). |
LearnedLocation |
getDestination()
Get the destination of the
LearnedTrip . |
LearnedLocation |
getOrigin()
Get the origin of the
LearnedTrip . |
Route |
getRoute()
Get the
Route associated with the LearnedTrip . |
double |
getWeight()
Get the relative weight of this
LearnedTrip . |
int |
hashCode() |
boolean |
isHidden()
Gets the current visibility of the
LearnedTrip . |
SavedTrip |
toSavedTrip()
Convert this
LearnedTrip into a SavedTrip , using the origin, destination and
arrival time of the LearnedTrip . |
String |
toString() |
void |
writeToParcel(Parcel dest,
int flags) |
public static final Parcelable.Creator<LearnedTrip> CREATOR
public void writeToParcel(Parcel dest, int flags)
writeToParcel
in interface Parcelable
public int describeContents()
describeContents
in interface Parcelable
public Date getDateTime()
LearnedTrip
instance (UTC).public LearnedLocation getOrigin()
LearnedTrip
.LearnedTrip
public LearnedLocation getDestination()
LearnedTrip
.LearnedTrip
public double getWeight()
LearnedTrip
. Higher values indicate higher likelihood
of taking this LearnedTrip
over other LearnedTrip
s at the same time.LearnedTrip
public Route getRoute()
Route
associated with the LearnedTrip
. The returned Route
will not contain any details until it is updated using RouteManager.getUpdatedRouteInfo(RouteManager.UpdatedRouteOptions, RouteManager.IUpdatedRouteListener)
.
Based on the user's driving pattern the same Trip
may result in multiple LearnedTrip
s
if for example the user takes different routes on different days.Route
associated with the trip or null
if not availablepublic boolean isHidden()
LearnedTrip
. All LearnedTrip
s are visible
unless they are explicitly hidden.true
if the trip is hidden, false
otherwise.public SavedTrip toSavedTrip()
LearnedTrip
into a SavedTrip
, using the origin, destination and
arrival time of the LearnedTrip
.SavedTrip
Copyright © 2013-2018 INRIX, Inc. All Rights Reserved.