类 DirectionsWaypoint

java.lang.Object
ai.nextbillion.kits.directions.models.DirectionsJsonObject
ai.nextbillion.kits.directions.models.DirectionsWaypoint
所有已实现的接口:
Serializable

public abstract class DirectionsWaypoint extends DirectionsJsonObject
An input coordinate snapped to the roads network.
另请参阅:
  • 构造器详细资料

    • DirectionsWaypoint

      public DirectionsWaypoint()
  • 方法详细资料

    • builder

      public static DirectionsWaypoint.Builder builder()
      Create a new instance of this class by using the DirectionsWaypoint.Builder class.
      返回:
      this classes DirectionsWaypoint.Builder for creating a new instance
    • name

      @Nullable public abstract String name()
      Provides the way name which the waypoint's coordinate is snapped to.
      返回:
      string with the name of the way the coordinate snapped to
    • location

      @Nullable public ai.nextbillion.kits.geojson.Point location()
      A Point representing this waypoint location.
      返回:
      GeoJson Point representing this waypoint location
    • toBuilder

      public abstract DirectionsWaypoint.Builder toBuilder()
      Convert the current DirectionsWaypoint to its builder holding the currently assigned values. This allows you to modify a single property and then rebuild the object resulting in an updated and modified DirectionsWaypoint.
      返回:
      a DirectionsWaypoint.Builder with the same values set to match the ones defined in this DirectionsWaypoint
    • typeAdapter

      public static com.google.gson.TypeAdapter<DirectionsWaypoint> typeAdapter(com.google.gson.Gson gson)
      Gson type adapter for parsing Gson to this class.
      参数:
      gson - the built Gson object
      返回:
      the type adapter for this class
    • fromJson

      public static DirectionsWaypoint fromJson(String json)
      Create a new instance of this class by passing in a formatted valid JSON String.
      参数:
      json - a formatted valid JSON string defining a DirectionsWaypoint
      返回:
      a new instance of this class defined by the values passed inside this static factory method