com.amap.api.trace

## 接口 TraceListener

-     public interface TraceListener

  轨迹纠偏回调
  Trajectory correction callback
  从以下版本开始:
    3.4.0

- - ### 方法概要

    所有方法 实例方法 抽象方法
    限定符和类型 | 方法和说明
    --- | ---
    `void` | `onFinished(int lineID, java.util.List<LatLng> linepoints, int distance, int waitingtime)` 轨迹纠偏成功回调 Trajectory correction success callback
    `void` | `onRequestFailed(int lineID, java.lang.String errorInfo)` 轨迹纠偏失败回调 Trajectory correction failure callback
    `void` | `onTraceProcessing(int lineID, int index, java.util.List<LatLng> segments)` 轨迹纠偏过程回调，一条轨迹分割为多个段，按索引顺序回调其中一段 Trajectory correction process callback, a trajectory is divided into multiple segments, and one segment is called back in index order

- - ### 方法详细资料

    - #### onRequestFailed

          void onRequestFailed(int lineID,
                               java.lang.String errorInfo)

      轨迹纠偏失败回调
      Trajectory correction failure callback
      参数:
        `lineID` - 用于标示一条轨迹，支持多轨迹纠偏，如果多条轨迹调起纠偏接口，则lineID需不同
        Used to mark a trajectory, supports multi-trajectory correction. If multiple trajectories trigger the correction interface, the lineID must be different
        `errorInfo` - 轨迹纠偏失败原因
        Reason for trajectory correction failure
      从以下版本开始:
        3.4.0

    - #### onTraceProcessing

          void onTraceProcessing(int lineID,
                                 int index,
                                 java.util.List<LatLng> segments)

      轨迹纠偏过程回调，一条轨迹分割为多个段，按索引顺序回调其中一段
      Trajectory correction process callback, a trajectory is divided into multiple segments, and one segment is called back in index order
      参数:
        `lineID` - 用于标示一条轨迹，支持多轨迹纠偏，如果多条轨迹调起纠偏接口，则lineID需不同
        Used to mark a trajectory, supports multi-trajectory correction. If multiple trajectories trigger the correction interface, the lineID must be different
        `index` - 一条轨迹分割为多个段,标示当前轨迹段索引
        A trajectory is divided into multiple segments, indicating the current segment index
        `segments` - 一条轨迹分割为多个段，segments标示当前轨迹段经过纠偏后经纬度点集合
        A trajectory is divided into multiple segments, and segments indicate the collection of latitude and longitude points of the current segment after correction
      从以下版本开始:
        3.4.0

    - #### onFinished

          void onFinished(int lineID,
                          java.util.List<LatLng> linepoints,
                          int distance,
                          int waitingtime)

      轨迹纠偏成功回调
      Trajectory correction success callback
      参数:
        `lineID` - 用于标示一条轨迹，支持多轨迹纠偏，如果多条轨迹调起纠偏接口，则lineID需不同
        Used to mark a trajectory, supports multi-trajectory correction. If multiple trajectories trigger the correction interface, the lineID must be different
        `linepoints` - 整条轨迹经过纠偏后点的经纬度集合
        Collection of latitude and longitude points of the entire trajectory after correction
        `distance` - 该轨迹经过纠偏后总距离，单位米
        Total distance of the trajectory after correction, in meters
        `waitingtime` - 该轨迹中间停止时间，以GPS速度为参考，单位秒
        Intermediate stop time of the trajectory, with GPS speed as reference, in seconds
      从以下版本开始:
        3.4.0