出自百度地图API
跳转到:导航
,
搜索
com.baidu.mapapi
类 MKOfflineMap
java.lang.Object
∟ com.baidu.mapapi.MKOfflineMap
public class MKOfflineMap
extends java.lang.Object
离线地图类(只支持老版离线地图)。
字段摘要
方法摘要
返回类型方法
booleanstart(int cityID)
启动下载指定城市ID的离线地图
Locationpause(int cityID)
暂停下载指定城市ID的离线地图
Bundleremove(int cityID)
删除指定城市ID的离线地图
getOfflineCityList()
返回支持离线地图城市列表(只有手机插入SD卡,才支持此功能。如果手机无SD卡,返回为空)
searchCity(String cityName)
根据城市名搜索该城市离线地图记录
intscan()
扫描加载离线地图包
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
字段详细信息
TYPE_NEW_OFFLINE
public static final int TYPE_NEW_OFFLINE
新安装离线地图事件类型另请参见:
TYPE_DOWNLOAD_UPDATE
public static final int TYPE_DOWNLOAD_UPDATE
离线地图下载更新事件类型另请参见:
TYPE_VER_UPDATE
public static final int TYPE_VER_UPDATE
离线地图数据版本更新事件类型另请参见:
方法详细信息
init
public boolean init(BMapManager bmapMan, MKOfflineMapListener listener)
初始化参数:
bmapMan - 实例化的BMapManger
start
public boolean start(int cityID)
启动下载指定城市ID的离线地图参数:
cityID - 指定的城市ID
pause
public boolean pause(int cityID)
暂停下载指定城市ID的离线地图参数:
cityID - 指定的城市ID
remove
public boolean remove(int cityID)
删除指定指定城市ID的离线地图参数:
cityID - 指定的城市ID
getHotCityList
public ArrayList getHotCityList()
返回热门城市列表
getOfflineCityList
public ArrayList getOfflineCityList()
返回支持离线地图城市列表(只有手机插入SD卡,才支持此功能。如果手机无SD卡,返回为空)
searchCity
public ArrayList searchCity(String cityName)
根据城市名搜索该城市离线地图记录参数:
cityName - 城市名
getAllUpdateInfo
public ArrayList getAllUpdateInfo()
返回各城市离线地图更新信息
getUpdateInfo
public MKOLUpdateElement getUpdateInfo(int cityID)
返回指定城市ID离线地图更新信息参数:
cityID - 指定的城市ID
scan
public int scan()
扫描加载离线地图包返回:
添加的离线包个数