Packagecom.afcomponents.umap.interfaces
Interfacepublic interface IProvider extends flash.events.IEventDispatcher
ImplementorsDefaultProvider, MicrosoftProvider, OpenStreetProvider, XMLProvider, YahooProvider

IProvider defines a special controller class which should hold an array of Map Types and handle requests for copyright information.



Public Properties
 PropertyDefined by
  logo : DisplayObject
[read-only] Returns a display object with the provider's logo.
IProvider
  mapTypes : Array
[read-only] Array which holds map types supported by this Provider.
IProvider
Public Methods
 MethodDefined by
  
addMapType(type:IMapType):Boolean
Adds new map type to the map types Array.
IProvider
  
dispose():void
Frees the resources accuired by the Provider.
IProvider
  
Returns default copyright string.
IProvider
  
getMapTypeByName(mapTypeName:String):IMapType
Returns map type reference by it's name.
IProvider
  
init(core:UMap):void
Initializes the provider and starts the loading process.
IProvider
  
loadCopyright(center:LatLng, bounds:LatLngBounds, zoom:Number, event:String = ""):void
Loads copyrights for the specified center, bounds, zoom and event.
IProvider
Property detail
logoproperty
logo:DisplayObject  [read-only]

Returns a display object with the provider's logo. Override it for custom logo.

Implementation
    public function get logo():DisplayObject
mapTypesproperty 
mapTypes:Array  [read-only]

Array which holds map types supported by this Provider.

Implementation
    public function get mapTypes():Array
Method detail
addMapType()method
public function addMapType(type:IMapType):Boolean

Adds new map type to the map types Array.

Parameters
type:IMapType — Valid map type object.

Returns
Boolean — A value of true if the map type was sucessfully added to the map types array; false if it was not.
dispose()method 
public function dispose():void

Frees the resources accuired by the Provider.

getDefaultCopyright()method 
public function getDefaultCopyright():String

Returns default copyright string.

Returns
String
getMapTypeByName()method 
public function getMapTypeByName(mapTypeName:String):IMapType

Returns map type reference by it's name.

Parameters
mapTypeName:String — Name of the map type to search.

Returns
IMapType — Reference to the found map type; null if it wasn't found.
init()method 
public function init(core:UMap):void

Initializes the provider and starts the loading process.

Parameters
core:UMap — Reference to the core object.
loadCopyright()method 
public function loadCopyright(center:LatLng, bounds:LatLngBounds, zoom:Number, event:String = ""):void

Loads copyrights for the specified center, bounds, zoom and event. After the copyright data has been loaded, class should dispatch ControlEvent.COPYRIGHT_CHANGED event with the new copyright information.

Parameters
center:LatLng — The coordinates of the map center.
 
bounds:LatLngBounds — The bounds of the map view.
 
zoom:Number — Current map zoom level.
 
event:String (default = "") — Indicates the map event.