Web ADF controls are designed to consolidate and utilize data from multiple sources. These include ArcGIS Server services accessed through either Local or Internet connections, ArcIMS services, ArcWeb Services, WMS services, Microsoft Bing Maps services and Web ADF graphics data sources. One of the main benefits of the Web ADF is the ability to display maps generated by one or more data sources at the same time, consolidated in a Map control. Web ADF components are designed to utilize data sources as resources. The capabilities of a data source determine the type of resource and subsequent functionalities it can provide.
Every data source available in the Web ADF is in essence a custom data source, plugged into the Web ADF via implementation of the Web ADF Common Data Source API (also known as the "Common API") interfaces. In most cases, each data source has a "data source specific API" which can be used on its own. To be used as a resource within the Web ADF, the data source must implement the appropriate Common API interfaces and classes. The capabilities of the data source dictate which interfaces and classes are appropriate. For example, the ESRI.ArcGIS.ADF.ArcGISServer assembly contains the SOAP proxies and value objects associated with the ArcGIS Server SOAP API. It can be used by itself, outside the Web ADF controls and API to work with ArcGIS Server services. To use ArcGIS Server services as data sources in the Web ADF, a Common API implementation of the ArcGIS Server SOAP API is provided in the ESRI.ArcGIS.ADF.Web.DataSources.ArcGISServer assembly. The Web ADF uses this ArcGIS Server implementation of the Common API to utilize ArcGIS Server data sources, both Local and Internet.
Each data source supported out-of-the-box with the Web ADF has its own library, prefixed with ESRI.ArcGIS.ADF.Web.DataSources. The data source implementation libraries contain resource and functionality classes which provide access to basic capabilities of the data source. For example, if a data source can generate a map, it supports MapResource and MapFunctionality. The Map control and developers will use the MapResource to create a MapFunctionality to generate a map. You will also notice that some data sources have more capabilities than others. In some cases, for more fine-grained tasks, the MapFunctionality class contains a hook into a data source specific API corresponding with the data source type. The ArcGIS Server SOAP API and the ArcIMS API are two examples of these lower-level APIs that provide data-source-specific, fine-grained capabilities.
When adding additional data to a Web ADF application, it is important to understand the limitations of each data source and just how the additional data will be added. From the Web ADF perspective you have two options to consider when adding data dynamically at runtime (appropriate samples are referenced):
1) Add a data source as a new Web ADF resource
This is a relatively coarse-grained operation where the Web ADF API is used to add a new resource item to a resource manager. This can be accomplished at design-time using a resource manager control or programmatically at runtime. In this case, the Web ADF is solely responsible for integrating and managing the new resource item with existing resources. This topic is discussed in more detail in the Resources and Functionalities topic.
2) Add a layer to the data source of an existing Web ADF resource
This is a fine-grained operation supported via the use of a data source specific API. A new layer (feature or image) may be able to be added to an existing data source at the data service level. For example, a dynamic layer can be added to an existing ArcIMS or ArcGIS Server map service (Local connections only). In some cases, the state dynamic layer can also be managed by the Web ADF (ArcIMS). In others the developer must explicitly manage the change (ArcGIS Server Local) because it involves a stateful change to the service.
Sample: ArcIMS_AddDynamicData
Sample: ArcGIS_AddDynamicData
ArcGIS Server Local
An ArcGIS Server local data source represents a local area network (LAN) connection to an ArcGIS Server service via the Server Object Manager. In order to connect, you need to provide the name of the server and service you want to connect to, along with identity information that verifies you are a member of the agsusers or agsadmin group on the machine where the Server Object Manager (SOM) is installed.ArcGIS Server local data sources provide access to pooled and non-pooled ArcGIS Server map, image, geocode, and geoprocessing services. Local data sources enable developers to work with fine-grained ArcObjects via server context. Thus, rich ArcObjects capabilities can be leveraged and utilized within a Web ADF application, such as editing feature layers, solving network solutions, or projecting geometry. In addition, the Server Object Manager is only designed to leverage Windows local and NT domain users and groups for "all or nothing" access to services. As a result, ArcGIS Server local data sources use the identity of the Web application to authenticate access to ArcGIS Server services. Only one Web application identity is permitted, therefore the defined identity must have access to all ArcGIS Server local data sources. To set the Web application identity, see the Add ArcGIS Identity discussion.
To work with an ArcGIS Server local data source programmatically, use the ArcGIS Server data source implementation library (ESRI.ArcGIS.ADF.Web.DataSources.ArcGISServer). From the MapFunctionality class of this assembly, you can access the map description and, ultimately work with the ArcGIS Server SOAP API. An ArcGIS Server local resource (e.g. MapResourceLocal) also provides access to server context via the ServerContextInfo.ServerContext property. In general, resource classes that work with ArcGIS Server local data sources include the suffix "Local" on a class name. For example the MapResourceLocal class is designed to work with ArcGIS Server local data sources in the Web ADF. Note that developers working with non-pooled services must explicitly release server context. A few options are provided in the Managing server context section.
ArcGIS Server local data sources can also utilize cached map services. For more information see the discussion topic about map caching in the ArcGIS Server Manager help.
For additional information on ArcGIS Server implementation in the 9.3 multi-source Web ADF see the discussion topic ArcGIS Server Implementation in the Web ADF.
ArcGIS Server Internet
Selecting an ArcGIS Server Internet data source implies that the
client will use access an ArcGIS Server service through a Web service
endpoint. An ArcGIS Server Web service provides access to the ArcGIS
Server SOAP API via a WSDL (Web Service Description Language) which
can be used by a client to generate value objects and proxies in a native
development environment. For ArcGIS Server services, the SOAP API
only exposes a subset of stateless functionality available via
ArcObjects. As a result, ArcGIS Server Internet data sources
will only work with ArcGIS Server services in a stateless
manner. Server context is not available via an ArcGIS Server
Internet data source, so fine-grained ArcObjects capabilities are not available.
Since ArcGIS Server Web services can also utilize authentication enabled
on a Web server, multiple Internet data sources with different authentication
credentials can be used within the same Web application.
ArcGIS Server Internet data sources can be used as map, image, geocode, and
geoprocessing resources. In a resource manager, when specifying the
definition for an ArcGIS Server Internet connection, provide the URL for
the server that contains the service, then select which service you want
to view from the dropdown box. If authentication is enabled on the site,
enter a username, password and domain before connecting. For more
information on secured services, see ASP.NET
Security.
Ensure that ArcGIS Internet data sources you use are pooled GIS services.
Pooled services are shared among users of the Web application. Non-pooled
service instances (processes) are dedicated to a single user, and the
instance is destroyed after the user finishes with it. If you use a non-pooled
service in an Internet connection, a new process will be created and destroyed
with every map or other GIS operation. This will lead to inefficient use of
resources on the GIS server, and will contribute no advantage to the
application. If necessary, contact the GIS server administrator to ensure that
Internet services used in the application are set to pooled status. For more
information on pooling of services, see
Tuning and configuring services in ArcGIS Server Help.
To work with an ArcGIS Server Internet data source programmatically, use
the ArcGIS Server data source implementation library
(ESRI.ArcGIS.ADF.Web.DataSources.ArcGISServer). This library contains
Functionality classes like the other data source libraries. It also contains
other classes used for performing more fine-grained tasks in a stateless
environment. In general, resource classes that work with ArcGIS Server
Internet data sources include the suffix "Internet" on a
class name. For example the MapResourceInternet class is designed to work
with ArcGIS Server Internet data sources in the Web ADF. Both
local and internet data source implementation use the ArcGIS Server
SOAP API to work with an ArcGIS Server service. The ArcGIS Server service
proxies (Web server and DCOM) and Value objects are contained in the
library ESRI.ArcGIS.ADF.ArcGISServer.
If you want to serve data via a Web service, you need to create a server
object, then use the Web Service Publisher to create the Web service. For
instructions, see
Publishing Web services.
ArcGIS Server Internet data sources can also utilize cached map services.
For more information see the
ArcGIS Server Manager Help topic on map caches.
For additional information on ArcGIS Server implementation in the 9.3
multi-source Web ADF see the discussion topic ArcGIS
Server Implementation in the Web ADF.
Microsoft Virtual Earth
The Microsoft Bing Maps (formerly known as Virtual Earth) platform offers access to rich map imagery and data
as well as robust search, location, and routing services. The Web ADF enables
the integration of Microsoft Bing Maps imagery data and services in ADF
applications through the implementation of the Common API in the
ESRI.ArcGIS.ADF.Web.DataSources.VirtualEarthService library. Access to the
Bing Maps platform requires explicit registration with Microsoft. The
subsequent use of Bing Maps services in the Web ADF requires that you
provide an account id and password when utilizing a Virtual Earth resource
item.
If you have purchased a Microsoft Bing Maps license with ArcGIS Server,
check with your ArcGIS Server administrator for the Bing Maps account id
and password you should use with the ADF. If an existing license is
not available, the following steps will assist you in registering for a Bing Maps account id and password:
- Create a Microsoft Windows Live ID. You can use an existing Live ID account if you already have one.
- Log in on the Microsoft Bing Maps Platform developer account signup page with your Windows Live ID.
- Create a new Microsoft Bing Maps Platform developer account and note the email address you provided. The Microsoft Bing Maps Platform account administrator will send you your new account ID and instructions to complete your registration by providing a password.
- Once registration is completed, you can use Virtual Earth resource items in the ADF. To verify your account is active, use the Verify Credentials page in the Microsoft Bing Maps Platform Customer Services site. Use your Windows Live ID to log in to the Customer Services site.
Bing Maps Web Services host both staging and production environments.
By default, once you have a valid Bing Maps account id and password, you
will work with the staging environment designed to support development and
testing. Map imagery will contain a watermark to indicate the staging
services are being used. To access the production environment, you must
be a licensed customer. Contact the
Microsoft Bing Maps Licensing Team for more information.
It is important to note that Bing Maps imagery is only
provided in the Web Mercator coordinate system and cannot be reprojected
on the fly.
ArcIMS
Selecting an ArcIMS data source implies that a client will access either TCP or HTTP. For TCP connections, specify the host and port number of the ArcIMS Application Server. For HTTP connections, specify the URL to the ArcIMS servlet connector. Both image and ArcMap image services are supported as map resources. Geocode capabilities exposed in an image service are supported as geocode resources.To work with an ArcIMS data source programmatically, start with the ArcIMS data source implementation library (ESRI.ArcGIS.ADF.Web.DataSources.IMS). Through the MapFunctionality class in this library, you can access a MapView class in the Web ADF’s ArcIMS API (ESRI.ArcGIS.ADF.IMS). Almost all fine-grained functionality available via ArcXML is exposed through the ArcIMS API.
ArcWeb Services
* Note, the ArcWeb service data source has been deprecated in ArcGIS Server 9.3.1. This data source will be removed in the next minor version release.ArcWeb Services is a subscription-based Web services platform managed by ESRI that allows you to integrate datasets into your Web applications on demand without having to purchase and maintain the data yourself. You can find more detailed information about ArcWeb Services at http://www.esri.com/software/arcwebservices. ArcWeb services require a valid ArcWeb account for access. Credit deductions are calculated the same for Web ADF applications as they are for non-Web ADF applications.
You can use the Web ADF controls to view and query ArcWeb Services. ArcWeb services can be added as map resources to a Web ADF application and blended with other resources. For map image data, the Map Image Web service is used. The URL is: http://www.arcwebservices.com/services/v2006/MapImage.wsdl. To query feature data, the Spatial Query Web service is used. The URL is: http://www.arcwebservices.com/services/v2006/SpatialQuery.wsdl. Both urls are static and cannot be changed.
ArcWeb services can also be used as geocode resources. The Address Finder Web service is used. The URL is: http://www.arcwebservices.com/services/v2006/AddressFinder.wsdl.
ArcWeb Services cannot be made transparent, therefore, when blending ArcWeb Services with other services, the ArcWeb Service must be the bottom layer of the map.
To work with an ArcWeb service programmatically, start with the ArcWeb service data source implementation library (ESRI.ArcGIS.ADF.Web.DataSources.ArcWebService). The ArcWeb service proxies and value objects are included with the data source specific assembly, ESRI.ArcGIS.ADF.ArcWebService. The implementation library does not provide a link to the data source specific classes it uses - they are managed internally.
OGC (WMS) Services
The Web controls support services that implement the OpenGIS Consortium (OGC) Web Map Service (WMS) specifications. To add an OGC (WMS) service to your application, you will need to know the url of the service to which you want to connect. Only map resources are supported. When you set the Definition information in the MapResourceManager, a dialog will allow you to enter an endpoint to a single WMS service. The service may contain multiple layers, which are referenced in the url with the "services" argument and a unique id for each layer. By default all layers are added to the url.To serve data as a WMS service, you can create an ArcGIS Server map service with the WMS capability enabled. See the ArcGIS Server Help system for more information on publishing map services and enabling capabilities. ArcIMS also has the ability to publish services that comply with WMS specifications.
Here are a few WMS endpoint examples:
ArcGIS Server WMS services - http://<hostname>/arcgis/services/<servicename>/MapServer/WMSServer
ArcIMS WMS services - http://<hostname>/wmsconnector/com.esri.wms.Esrimap/<servicename>
CGI enabled WMS services - http://<hostname>/cgi-bin/customwms
Graphics Layers
You can use a graphics layer to efficiently display geographic features at the
Web tier. These features may or may not originate from one of the services
listed above. For example, you may have used an existing service on your map to
return a table of point geometries from a geocoding operation, or you may have
used your own GPS unit to collect a set of waypoints. Either way, you can
render these features in a graphics layer.
The Web ADF provides a Graphics data source unique to the Web ADF. The Graphics
data source can be added as a map resource item of type "GraphicsLayer" to
a MapResourceManager and displayed in an associated Map control. A Web
ADF Graphics resource is a type of System.Data.DataSet which can hold many
DataTables. You can access the Web ADF GraphicsDataSet via the
Graphics property on a Graphics map resource.
The Web ADF also defines two graphics layer types: ElementGraphicsLayer
and FeatureGraphicsLayer. Both layers are a type of
System.Data.DataTable, thus they can be added to the GraphicsDataSet Tables
collection. Graphics layer content is stored in-memory by the Web application.
As a result, the amount of content in a graphics layer is proportional to the
amount of memory required for the Web application. Note that graphics layer
types must be created and managed programmatically.
ElementGraphicsLayers are designed to store basic graphic elements,
namely geometry and a symbol. One ElementGraphicsLayer can store
different types of geometry. In general, they were not designed for attribute
storage. They are often used to display selected features in a map.
FeatureGraphicsLayers are designed to emulate a true feature layer.
Each layer only supports one geometry type. Web ADF renderers can be applied to
symbolize geometry based on attribute values in the DataTable. FeatureGraphicsLayers
also support queries.
The Web ADF handles drawing each graphics layer type within a Graphics Layer
resource. As a result, the Web ADF also provides a set of geometry types,
symbols, and renderers that can be used with graphics layer types. Note, Web
ADF symbology supports variable transparency (0%-100%). A
comprehensive discussion of graphics in the Web ADF is provided in the
Graphics layers and core classes topic.