Class DirectionsRequest

java.lang.Object
es.situm.sdk.directions.DirectionsRequest
All Implemented Interfaces:
android.os.Parcelable, MapperInterface

public class DirectionsRequest extends Object implements android.os.Parcelable, MapperInterface
Parameters to request a route with DirectionsManager.

Use the DirectionsRequest.Builder to create an instance. Instances are immutable.

  • Field Details

  • Method Details

    • getFrom

      public Point getFrom()
      Returns the point where the route should start.
      Returns:
      Point point inside a building (Point.isIndoor() == true)
    • getBearingFrom

      @Nullable public Angle getBearingFrom()
      Returns the user's bearing in the starting point.
      Returns:
      Angle
    • getTo

      public Point getTo()
      Returns the point where the route should end.
      Returns:
      Point point inside a building (Point.isIndoor() == true)
    • getPoiToIdentifier

      public String getPoiToIdentifier()
      Returns the identifier of the POI where the route should end.
      Returns:
      String Identifier of the POI
    • getOptions

      public DirectionsOptions getOptions()
      Returns object that contains different parameters related to how a route is computed.
      Returns:
      DirectionsOptions
    • getExcludedTags

      public List<String> getExcludedTags()
    • getIncludedTags

      public List<String> getIncludedTags()
    • isAccessible

      public boolean isAccessible()
      Returns whether the route has to be suitable for wheel chairs (true) or not (false)
      Returns:
      boolean
    • getAccessibilityMode

      public DirectionsRequest.AccessibilityMode getAccessibilityMode()
      Returns the DirectionsRequest.AccessibilityMode of the route
      Returns:
      DirectionsRequest.AccessibilityMode
    • minimizeFloorChanges

      public boolean minimizeFloorChanges()
      Returns if the route will be calculated minimizing the floor changes
    • getExclusions

      public List<es.situm.sdk.directions.internal.calc.RouteCollider> getExclusions()
      Returns the list of elements used to exclude areas from the route. For internal use only.
      Returns:
      List of exclusions.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • describeContents

      public int describeContents()
      Specified by:
      describeContents in interface android.os.Parcelable
    • writeToParcel

      public void writeToParcel(android.os.Parcel dest, int flags)
      Specified by:
      writeToParcel in interface android.os.Parcelable
    • toMap

      public Map<String,Object> toMap()
      Description copied from interface: MapperInterface
      Method to transform object into Map<String, Object>
      Specified by:
      toMap in interface MapperInterface
      Returns:
      Map<String, Object> with the information of the object mapped
    • fromMap

      public static DirectionsRequest fromMap(Map<String,Object> map) throws IllegalArgumentException
      Return a new DirectionsRequest instance object containing the data at the given map. Use MapperInterface to populate the Map. The expected fields are those defined at DirectionsRequest.Builder. The DirectionsOptions will be ignored.
      Parameters:
      map - Map containing the data used to populate the new object.
      Returns:
      New instance.
      Throws:
      IllegalArgumentException - If there is not enough information at the given map or it is incorrect.