• 大小: 2.07MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-09-11
  • 语言: 其他
  • 标签: BaiduMap  

资源简介

BaiduMapsApiDemo

资源截图

代码片段和文件信息

package baidumapsdk.demo;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;

import com.baidu.mapapi.map.BaiduMap;
import com.baidu.mapapi.map.BaiduMapOptions;
import com.baidu.mapapi.map.MapStatus;
import com.baidu.mapapi.map.MapView;
import com.baidu.mapapi.model.LatLng;

/**
 * 演示MapView的基本用法
 */
public class baseMapDemo extends Activity {
@SuppressWarnings(“unused“)
private static final String LTAG = baseMapDemo.class.getSimpleName();
private MapView mMapView;
private BaiduMap mBaiduMap;

@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Intent intent = getIntent();
if (intent.hasExtra(“x“) && intent.hasExtra(“y“)) {
// 当用intent参数时,设置中心点为指定点
Bundle b = intent.getExtras();
LatLng p = new LatLng(b.getDouble(“y“) b.getDouble(“x“));
mMapView = new MapView(this
new BaiduMapOptions().mapStatus(new MapStatus.Builder()
.target(p).build()));
} else {
mMapView = new MapView(this new BaiduMapOptions());
}
setContentView(mMapView);
mBaiduMap = mMapView.getMap();
}

@Override
protected void onPause() {
super.onPause();
// activity 暂停时同时暂停地图控件
mMapView.onPause();
}

@Override
protected void onResume() {
super.onResume();
// activity 恢复时同时恢复地图控件
mMapView.onResume();
}

@Override
protected void onDestroy() {
super.onDestroy();
// activity 销毁时同时销毁地图控件
mMapView.onDestroy();
}

}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\src\
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\
     文件        1557  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\baseMapDemo.java
     文件         352  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\DemoApplication.java
     文件       13954  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\RoutePlanDemo.java
     文件        5522  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\BMapApiDemoMain.java
     文件        6465  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\ShareDemoActivity.java
     文件        6293  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\PoiSearchDemo.java
     文件        1778  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\layersDemo.java
     文件        4168  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\GeoCoderDemo.java
     文件         516  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\ShareDemo.java
     文件        5862  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\OverlayDemo.java
     文件        5489  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\LocationDemo.java
     文件        7281  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\MapControlDemo.java
     文件        1811  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\MultiMapViewDemo.java
     文件        4224  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\GeometryDemo.java
     文件        2442  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\UISettingDemo.java
     文件        2466  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\NaviDemo.java
     文件         535  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\CloudSearchDemo.java
     文件        4783  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\CloudSearchActivity.java
     文件        7209  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\BusLineSearchDemo.java
     文件        9060  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\OfflineDemo.java
     文件        1825  2014-06-03 09:16  BaiduMapsApiDemo\src\baidumapsdk\demo\MapFragmentDemo.java
     文件         852  2014-06-03 09:16  BaiduMapsApiDemo\.project
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\libs\
     文件      349252  2014-06-03 09:16  BaiduMapsApiDemo\libs\android-support-v4.jar
     文件       99119  2014-06-03 09:16  BaiduMapsApiDemo\libs\locSDK_3.1.jar
     目录           0  2014-06-03 09:16  BaiduMapsApiDemo\libs\armeabi\
     文件     1140400  2014-06-03 09:16  BaiduMapsApiDemo\libs\armeabi\libBaiduMapSDK_v3_0_0.so
............此处省略73个文件信息

评论

共有 条评论