// // AMapLocationCommonObj.h // AMapLocationKit // // Created by AutoNavi on 15/10/22. // Copyright © 2015年 Amap. All rights reserved. // #import #import #import ///AMapLocation errorDomain extern NSString * const AMapLocationErrorDomain; ///AMapLocation errorCode typedef NS_ENUM(NSInteger, AMapLocationErrorCode) { AMapLocationErrorUnknown = 1, ///<未知错误 AMapLocationErrorLocateFailed = 2, ///<定位错误 AMapLocationErrorReGeocodeFailed = 3, ///<逆地理错误 AMapLocationErrorTimeOut = 4, ///<超时 AMapLocationErrorCanceled = 5, ///<取消 AMapLocationErrorCannotFindHost = 6, ///<找不到主机 AMapLocationErrorBadURL = 7, /// ///格式化地址 @property (nonatomic, copy) NSString *formattedAddress; ///国家 @property (nonatomic, copy) NSString *country; ///省/直辖市 @property (nonatomic, copy) NSString *province; ///市 @property (nonatomic, copy) NSString *city; ///区 @property (nonatomic, copy) NSString *district; ///乡镇 @property (nonatomic, copy) NSString *township __attribute__((deprecated("该字段从v2.2.0版本起不再返回数据,建议您使用AMapSearchKit的逆地理功能获取."))); ///社区 @property (nonatomic, copy) NSString *neighborhood __attribute__((deprecated("该字段从v2.2.0版本起不再返回数据,建议您使用AMapSearchKit的逆地理功能获取."))); ///建筑 @property (nonatomic, copy) NSString *building __attribute__((deprecated("该字段从v2.2.0版本起不再返回数据,建议您使用AMapSearchKit的逆地理功能获取."))); ///城市编码 @property (nonatomic, copy) NSString *citycode; ///区域编码 @property (nonatomic, copy) NSString *adcode; ///街道名称 @property (nonatomic, copy) NSString *street; ///门牌号 @property (nonatomic, copy) NSString *number; ///兴趣点名称 @property (nonatomic, copy) NSString *POIName; ///所属兴趣点名称 @property (nonatomic, copy) NSString *AOIName; @end #pragma mark - AMapLocationPoint ///经纬度坐标点对象 @interface AMapLocationPoint : NSObject ///纬度 @property (nonatomic, assign) CGFloat latitude; ///经度 @property (nonatomic, assign) CGFloat longitude; /** * @brief AMapNaviPoint类对象的初始化函数 * @param lat 纬度 * @param lon 经度 * @return AMapNaviPoint类对象id */ + (AMapLocationPoint *)locationWithLatitude:(CGFloat)lat longitude:(CGFloat)lon; @end ///POI信息 @interface AMapLocationPOIItem : NSObject ///id @property (nonatomic, copy) NSString *pId; ///名称 @property (nonatomic, copy) NSString *name; ///类型 @property (nonatomic, copy) NSString *type; ///类型编码 @property (nonatomic, copy) NSString *typeCode; ///地址信息 @property (nonatomic, copy) NSString *address; ///经纬度 @property (nonatomic, strong) AMapLocationPoint *location; ///电话号码 @property (nonatomic, copy) NSString *tel; ///省份 @property (nonatomic, copy) NSString *province; ///城市 @property (nonatomic, copy) NSString *city; ///区 @property (nonatomic, copy) NSString *district; @end ///行政区域信息 @interface AMapLocationDistrictItem : NSObject ///城市编码 @property (nonatomic, copy) NSString *cityCode; ///区域编码 @property (nonatomic, copy) NSString *districtCode; ///区名 @property (nonatomic, copy) NSString *district; ///行政区域轮廓坐标点,每个行政区可能有多个模块,每个模块的坐标点数组由AMapLocationPoint构成 @property (nonatomic, copy) NSArray *> *polylinePoints; @end ///AMapLocation CoordinateType typedef NS_ENUM(NSUInteger, AMapLocationCoordinateType) { AMapLocationCoordinateTypeBaidu = 0, ///