10.2.5: <AGSWebMapDelegate> Protocol Reference
10.2.5
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Pages
<AGSWebMapDelegate> Protocol Reference

Description

A protocol which must be adopted by a class wishing to serve as a delegate for AGSWebMap. An instance of the class must then be set as AGSWebMap::delegate .

AGSWebMap informs the delegate of events and consults the delegate before taking some action.

All of the methods of this protocol are optional.

Since
1.8
Inheritance diagram for <AGSWebMapDelegate>:

Instance Methods

(NSString *) - bingAppId
 
(NSString *) - bingAppIdForWebMap:
 
(void) - didFailToLoadLayer:url:baseLayer:withError:
 
(void) - didLoadLayer:
 
(void) - didOpenWebMap:intoMapView:
 
(void) - webMap:didFailToLoadLayer:baseLayer:federated:withError:
 
(void) - webMap:didFailToLoadWithError:
 
(void) - webMap:didFetchPopups:forExtent:
 
(void) - webMap:didFinishFetchingPopupsForExtent:
 
(void) - webMap:didLoadLayer:
 
(void) - webMap:didSwitchBaseMap:onMapView:
 
(void) - webMapDidLoad:
 

Method Documentation

- (NSString*) bingAppId
optional

Called when the webmap needs to open a Bing layer.

Since
1.8
Deprecated:
Deprecated at 10.1.1. Use AGSWebMap::bingAppIdForWebMap: instead.
- (NSString*) bingAppIdForWebMap: (AGSWebMap *)  webMap
optional

Called when the webmap needs to open a Bing layer.

Since
10.1.1
- (void) didFailToLoadLayer: (NSString *)  layerTitle
url: (NSURL *)  url
baseLayer: (BOOL)  baseLayer
withError: (NSError *)  error 
optional

Called when a layer fails to load. The delegate can either skip loading the layer using continueOpenAndSkipCurrentLayer (AGSWebMap) method or retry loading it with credentials using continueOpenWithCredential: (AGSWebMap) method

Parameters
layerTitleThe title of the layer being loaded.
urlThe url of the layer being loaded.
baseLayerWhether or not the layer is part of the basemap layers.
errorThe error describing why the layer failed to load.
Since
2.1
Deprecated:
Deprecated at 10.1.1. Use AGSWebMap::webMap:didFailToLoadLayer:baseLayer:federated:withError: instead.
- (void) didLoadLayer: (AGSLayer *)  layer
optional

Called when a layer loads.

Parameters
layerThe layer that loaded successfully.
Since
1.8
Deprecated:
Deprecated at 10.1.1. Use AGSWebMap::webMap:didLoadLayer: instead.
- (void) didOpenWebMap: (AGSWebMap *)  webMap
intoMapView: (AGSMapView *)  mapView 
optional

Called when a webmap is done opening into an AGSMapView.

Parameters
webMapThe web map that was successfully opened.
mapViewThe map view in which the web map was opened into.
Since
1.8
- (void) webMap: (AGSWebMap *)  webMap
didFailToLoadLayer: (AGSWebMapLayerInfo *)  layerInfo
baseLayer: (BOOL)  baseLayer
federated: (BOOL)  federated
withError: (NSError *)  error 
optional

Called when a layer fails to load. The delegate can either skip loading the layer using continueOpenAndSkipCurrentLayer (AGSWebMap) method or retry loading it with credentials using continueOpenWithCredential: (AGSWebMap) methods

Parameters
webMapThe webmap that was loaded
layerInfoThe AGSWebMapLayerInfo of the layer that failed to load.
baseLayerWhether or not the layer is part of the basemap layers.
federatedWhether or not the layer is federated with the portal that the web map is in.
errorThe error describing why the layer failed to load.
Since
10.1.1
- (void) webMap: (AGSWebMap *)  webMap
didFailToLoadWithError: (NSError *)  error 
optional

Tells the delegate that the specified error was encountered while tyring to retrieve the webmap's data.

Parameters
webMapThe webmap that failed to load.
errorInformation about the cause of the failure.
Since
2.0
- (void) webMap: (AGSWebMap *)  webMap
didFetchPopups: (NSArray *)  popups
forExtent: (AGSEnvelope *)  extent 
optional

Called when a group of popups is retrieved. This method can be called multiple times until AGSWebMap::webMapDidFinishFetchingPopups: is called.

Since
10.2
- (void) webMap: (AGSWebMap *)  webMap
didFinishFetchingPopupsForExtent: (AGSEnvelope *)  extent 
optional

Called when all the popups have been retrieved.

Since
10.2
- (void) webMap: (AGSWebMap *)  webMap
didLoadLayer: (AGSLayer *)  layer 
optional

Called when a layer loads successfully.

Parameters
webMapThe web map that the loaded layer belongs to.
layerThe layer that was successfully loaded.
Since
10.1.1
- (void) webMap: (AGSWebMap *)  webMap
didSwitchBaseMap: (AGSWebMapBaseMap *)  baseMap
onMapView: (AGSMapView *)  mapView 
optional

Called when the webmap is done switching the basemap.

Since
10.2.3
- (void) webMapDidLoad: (AGSWebMap *)  webMap
optional

Tells the delegate that the webmap data was retrieved successfully.

Parameters
webMapThe webmap that was loaded.
Since
2.0