BMFSuggestionInfo.fromMap constructor

BMFSuggestionInfo.fromMap(
  1. Map map
)

map => BMFSuggestionInfo

Implementation

BMFSuggestionInfo.fromMap(Map map)
    : assert(map != null,
          'Construct a BMFSuggestionInfo,The parameter map cannot be null !') {
  key = map['key'];
  location =
      map['location'] == null ? null : BMFCoordinate.fromMap(map['location']);
  uid = map['uid'];
  city = map['city'];
  district = map['district'];
  tag = map['tag'];
  address = map['address'];
  if (map['children'] != null) {
    children = new List<BMFSuggestionChildrenInfo>();
    map['children'].forEach((v) {
      children.add(BMFSuggestionChildrenInfo.fromMap(v as Map));
    });
  }
}