• 2010年8月29日周日_Using the Sample Xcode Projects_5


    /****************************************************/

    //Using the Sample Xcode Projects

    //2010年8月29日

    /****************************************************/

    Resource Center

    When you installed the ArcGIS for iPhone SDK, you not only installed the header files and documentation necessary to build your own iPhone application - you also installed sample projects that you can use to jump start your development with the SDK.

    当你安装了ArcGIS for iPhone SDK,你不仅仅安装了创建你自己的ipone应用程序所需的头文件和documentation,你也安装了例子工程,你可以使用他们跳过使用SDK进行的开发。

     For the beta release, there are six key samples that are installed:

    对于发行的beta,这里有他们安装的六个重要的例子:

    • MapViewDemo
    • QueryTaskDemo
    • GraphicsDemo
    • GeometryServiceTaskDemo
    • AsyncGPDemo
    • GeocodingDemo

    MapView Demo Sample

    The MapView Demo sample is a simple view application that illustrates how you can create a map view and add a tile map service layer and dynamic map service layer.

    A search bar lets you search for US counties by name (case sensitive) and it will apply a query definition to the drawing of the layer. A slider is provided as well to illustrate how you can control the opacity of the dynamic map layer.

    The sample is located at:

    ~/Library/SDKs/Samples/MapViewDemo

    MapView Demo 例子是一个简单的视图例子,她说明(阐明了)你如何创建一个地图视图,并添加一个tilemap服务图层和一个dynamic地图服务图层。

    一个搜索栏能够让你通过名称搜索US的州,并且使用一个查询定义来绘制图层。一个slider也被提供,用来说明你如何控制dynamic地图图层的透明度。

    这个例子被放置在:~/Library/SDKs/Samples/MapViewDemo

    QueryTask Demo Sample

    The Query task demo sample illustrates how you can use the AGSQueryTask class to find features that you search for and display the results in a list using a UITableView. You can then click on individual results to see more details about the feature. Note that the search is case sensitive.

    It is important to note that the query task executes in a separate thread from the main thread of the application. This allows the main thread to stay responsive(敏感的,反应快的) while the query is being executed on the server and in the background. It is assumed that the AGSQueryTask Delegate executes in the main thread.

    The sample is located at:

    ~/Library/SDKs/Samples/QueryTaskDemo

    Query task deomo 例子说明了你如何使用AGSQueryTask类来找到你要搜索的features并将查询的结果使用一个UITableTrew以列表的形式展示。Note that the search is case sensitive.

    然后你可以单击一个单独的结果来查看关于这个feature更详细的欣喜。

    一个很重的地方就是你要注意这个查询任务是由一个和应用程序的主线程不同的单独的线程执行的。当查询正在后台服务器上执行的时候,主线程还能够保持敏感的、反映快速的。

    它假设AGSQueryTask代表主线程上面的执行。

    例子存放在:~/Library/SDKs/Samples/QueryTaskDemo

    Graphics Demo Sample

    The Graphics demo sample illustrates how you can work with graphics layers (multiple graphics layers of varying types) in the map view. The UISegmentedControl allows you to switch between graphics layers.

    Using the Counties view, the state of California is displayed and you can click anywhere on the state to identify a county. The graphics for each county have a custom info template which returns text to in a clickable callout. Clicking the accessory(.附(零,配)件;装饰品;同谋,帮凶) button (arrow inside the callout) navigates to a new view which lists the details of the county.

    Clicking on the cities view illustrates how you can create graphics of differing types via a Unique Value Renderer. In this instance, the cities are rendered using a UniqueValueRenderer based on the "TYPE" attribute of the city layer. The yellow circle for census designated(指派,委任;标出,把…定名为) place, the white diamonds for city and the blue cross for towns.

    Graphics demo 例子说明了你如何和Graphics layer在map 视图中一起工作(不同类型的多Graphicslayers)。UISegmentedControl 允许你在不同的Graphics layers切换。

    使用国家视图,加利福尼亚州展现出来,你可以在加利福尼亚州的任何位置上面单击来鉴定一个郡县。The graphics for each county have a custom info template which returns text to in a clickable callout。单击装饰作用的按钮,导航到一个新的视图,在这个视图里面列出了这个country的详细信息。

    单击城市视图,它说明了你如何通过一个Unique Value Renderer创建不同类型的graphics。在这个例子中,城市使用了一个基于city layer的一个“TYPE”属性的UniqueValueRenderer来渲染地图。黄色的圆圈用于人口统计指定的地方,白色的钻石用于表示城市,蓝色的十字表示城镇。

    Note:

    The city graphics don't have a infoTemplate, the Callout will not be displayed for these features, even when clicked.

    The sample is located at:

    ~/Library/SDKs/Samples/GraphicsDemo

    注意:

    City图层没有一个info的模板。Callout不会为这些features展示,即使单击的后也不会展示。

    Sample被放置

    ~/Library/SDKs/Samples/GraphicsDemo

    GeometryServiceDemo

    The GeometryService demo sample illustrates how you can leverage a Geometry Service to include advanced geometric operations through a web service and exercises the GeometryServiceTask class within the API.

    The GeometryService demo uses a buffer service hosted on http://sampleserver1.arcgisonline.com to buffer point geometries and add the results as graphics to the map.

    The sample is located at:

    ~/Library/SDKs/Samples/GeometryServiceDemo

    GeometryService demo 例子说明了你如何影响一个Geometry服务通过一个web服务包含一个先进的图形操作、在API中运行GeometryService任务类。

    GeometryService dome使用一个基于http://sampleserver1.arcgisonline.com的buffer服务来对点图形进行缓冲,然后将查询结果以图形添加到地图上面。

    例子放置在:

    ~/Library/SDKs/Samples/GeometryServiceDemo

    AsyncGP Demo

    The AsyncGP demo sample demonstrates how you can execute a geoprocessing tool as a service asynchronously using the Geoprocessor class in the API.

    The AsyncGP demo leverages a "Mailing List" sample geoprocessing service that is hosted at http://sampleserver2.arcgisonline.com.

    The sample is located at:

    ~/Library/SDKs/Samples/AsyncGPDemo

    AsyncGP domo 例子说明了你如何使用API中的Geoprocessor类将一个geoprocessing工具当做一个service来执行。

    AsyncGP domo  影响了一个部署在http://sampleserver2.arcgisonline.com 上面的一个名称为’’Mailing List ”的 geoprocessing服务

    例子放置在   ~/Library/SDKs/Samples/AsyncGPDemo

    Geocoding Demo

    The Geocoding demo sample illustrates how you can use a custom ArcGIS Server locator service with the AGSLocator class in the API to find a location, zoom to that location and provide details for it on the map using a callout graphic.

    The Geocoding demo leverages locator services available through http://services.arcgisonline.com.

    The sample is located at:

    ~/Library/SDKs/Samples/GeocodingDemo

       Geocoding deom 例子说明了你如何使用一个自定义的ArcGIS Server 定义服务和API中AGSLocaltor类来查找一个位置,并缩放到当前的位置,使用一个callout graphic 为他在地图上提供更多的服务。

    Geocoding deomo 使用的定位服务通过http://services.arcgisonline.com获取。

  • 相关阅读:
    SpringBoot整合Flyway(数据库版本迁移工具)
    Java并发编程实战 05等待-通知机制和活跃性问题
    Java并发编程实战 04死锁了怎么办?
    Java并发编程实战 03互斥锁 解决原子性问题
    Java并发编程实战 02Java如何解决可见性和有序性问题
    Flutter学习笔记(40)--Timer实现短信验证码获取60s倒计时
    Flutter学习笔记(39)--BottomNavigationBar底部item超过3个只显示icon,不显示title
    Flutter学习笔记(38)--自定义控件之组合控件
    Flutter学习笔记(36)--常用内置动画
    Flutter学习笔记(37)--动画曲线Curves 效果
  • 原文地址:https://www.cnblogs.com/xingchen/p/1812327.html
Copyright © 2020-2023  润新知