BMFRouteStep.fromMap constructor

BMFRouteStep.fromMap(
  1. Map map
)

map => BMFRouteStep

Implementation

BMFRouteStep.fromMap(Map map)
    : assert(map != null,
          'Construct a BMFRouteStep,The parameter map cannot be null !') {
  distance = map['distance'];
  duration = map['duration'];
  if (map['points'] != null) {
    points = new List<BMFCoordinate>();
    map['points'].forEach((v) {
      points.add(BMFCoordinate.fromMap(v as Map));
    });
  }
  // points = points;
  pointsCount = map['pointsCount'];
  name = map['name'];
}