2010年9月09日_周四_OverViewOfTheMobileControls_1.2
Posted on 2010-09-12 16:40 星尘的天空 阅读(207) 评论(0) 编辑 收藏 举报/*********************************************************/
//Mobile SDK controls overview
//
/***************************************************************/
The Mobile SDK provides a number of Visual Studio components to help you quickly and effieciently create a mobile application. These are integrated into the Visual Studio toolbox, and can be found under the ArcGIS Mobile controls tab, when you install the mobile SDK.
The following paragraphs(段落) provide an overview for these controls. Some of these are described in more detail in later topics.
Mobile SDK提供了一系列的VS控件来帮助你快速、高效的创建一个mobile应用程序。 这些都被集成到VS工具箱中,当你安装Mobile SDK的时候,可以在ArcGIS Mobile 控件Tab中找到他们,
下面的段落对这些控件提供了一个概述。这些中的其中一些控件会在后面的题目中详细讨论。
Map
The Map control is designed to display geographic data from a single MapCache which obtains its data from a published mobile enabled map service. Layer properties such as visbility, symbology and scale thresholds default to their values in the published map although some of these can be changed at runtime. To use the control, drag it on to a form within your project. A MapCache component will be created if it does not already exist. A number of other Mobile SDK controls can enhance the user experience with the map, such as the Scale Bar, Navigation, and GPS Display controls.
地图控件被设计为展示一个独立的MapCache图形数据,Mapcache数据包含着一个发布为Mobile可以使用的地图服务。图层属性,比如:可见性、图标和比例尺开始的时候都默认的为发布的地图中值,尽管其中的一些可以在运行的状态下改变。为了使用这些控件,拖放他们到你的工程中的一个form中。 如果没有MapCache,那么需要创建一个MapCache、其他的一些Maobile SDK控件可以增强用户的地图体验,比如:比例尺控件、导航控件、GPS展示控件。
MobileService
A Mobile Service is fundemental component in all Mobile SDK applications. It serves as the data communication mechanism to send and retrieve data from a published mobile enabled map service and is also responsible for the storage of data on the local device. For normal applications a Mobile Service is added when you add a new Map control to your application. It is possible to have headless apps where you have a mobile service but no map.
Mobile Service是所有基于Mobile SDK应用程序的基础组件。 她就像一个数据交互机器,发送并接受来自可以提供mobile 地图服务的数据,她也负责存储数据到本地的
设备中一般的应用程序,当添加一个新的地图控件的时候,Mobile Server就会自动的谈价。也可能会遇到一个意外的程序,它拥有一个mobileService 但是没有一个Map
Zoom In, Zoom Out and Pan MapActions
These controls allow the map to perform zoom in, zoom out and Pan navigation with an input device such as mouse or pen. To enable these modes, add the controls to your application then set the CurrentMapAction property on the Map control to be one of these components.
放大、缩小、漫游等地图动作
这些控件可以使用一个输入设备让地图执行放大、缩小、漫游导航等,比如:鼠标、光笔。 为了使这些功能可用,将这些控件添加到你的应用程序,然后设置地图控件的CurrentMapAction属性为这些组件中的一个
Selection MapAction
This component provides an interactive method to select geographic features on the map. Add the component to your application then set it to the CurrentMapAction on the map. Selection criteria can be set through the component properties. The resulting selection set is obtained from the GetFeatureSelection property after a MapActionCompleted event is fired.
选择地图动作
这些组件提供交互的方法在地图上面选择features。 添加这个空间到你的应用程序,然后设置它为地图的当前地图操作(/动作)。通过组件的属性可以设置选择的标准(准则)。 当一个mapActionCompleted 事件被触发后,通过GetFeatureSelection属性可以获取选中的结果。
GPS File and GPS Serial(连续剧,连载故事 a.连续的) Port Connection
These components manage a connection to a serial port with a GPS device or a file containing GPS sentances. The component properties set attributes such as the COM port, Baud rate for the serial connection and Filename for the file connection. Once the GPS connection is opened ,GPS attributes can be obtained via the GpsEventArgs class on the GpsChanged event.
这些组件管理连续端口和GPS设备或者一个包含GP句子的文件的连接。组件的属性可以设备属性,比如:COM端口,用于连续连接的波特率和文件连接的名称。 一旦GPS连接打开,可以通过GPSChange事件中的一个GSPEventArg类来获取GPS属性。
GPS Display
The GPS Display component displays a GPS location on a map control from coordinates obtained via a GPS Serial Port or File Connection. See also Using GPS devices for more information on this component.
GPS展示
GPS展示组件在一个地图控件上面展示一个GSP位置,他们的坐标是通过一个GPS连续端口和一个文件连接。更过关于这个组件的详细信息,请查看Using GPS devices
Using the Scalebar
The scalebar control is designed to add a basic scalebar to the map display. The scalebar properties such as text color, units, scalebar position etc are set through the component properties.
Additionally the scalebar can also show the status of information coming from an ArcGIS Server connection. When the application is retrieving information from ArcGIS Server, an in progress bar is displayed within the scalebar indicating to the user that the map is still receiving information.
使用比例尺:
比例尺控件被设计为添加一个基础的比例尺工具到地图展示上面。比例尺属性比如:文件颜色、单位、比例尺的位置等等都可以通过组件的属性设置。
另外,callebar也可以展示来自ArcGIS Server 连接信息的状态。当一个应用程序从ArcGIS Server中重新获取信息的时候,scalebar控件中展示一个进度条工具,她向用户指出地图仍然在获取信息。
The scalebar is displayed on the map at the position determined by the DisplayPosition property. The default units are set to US Customary (Miles, Yards, Feet and inches) but this can be changed to Metric via the UnitSystem property. The scale threshold(门槛,门口;入门,开端,起始点) at which the units change is fixed.
To display the in progress bar within the scalebar, set the MapCache property to the map cache within your application. The ShowProgress property must also be set to true.
比例尺在地图上显示的位置由DisplayPosition属性决定。默认的地图单位设置为US的习惯(公里、码、英尺、英寸),但是可以通过UnitSystem属性改变为公制的。The scale threshold(门槛,门口;入门,开端,起始点) at which the units change is fixed.
为了在比例尺中展示一个进度条,在你的程序中设备地图的Mapcache属性,地图的ShowProgress属性也必须设置为true。