Special class capable of proxying Bing service requests through a server side proxy script.
This script should be able to perform a SOAP query to a MapPoint service.
Another requirement is the ability to perform the digest authentication with the destination service.
MapPointProxy is required for all Bing services:
Example
Here is a quick example of the MapPointProxy intialization:
import com.afcomponents.umap.providers.microsoft.MapPointProxy;
import com.afcomponents.umap.providers.microsoft.MapPointTokenRequest;
import com.afcomponents.umap.events.MapPointProxyEvent;
// initalize proxy
MapPointProxy.initialize("http://www.umapper.com/demo/dmitry/msproxy.php");
// request token, and wait for valid token
var proxy:MapPointProxy = MapPointProxy.getInstance();
proxy.getToken();
proxy.addEventListener(MapPointProxyEvent.REQUEST_COMPLETE, proxyComplete);
// wait for token ready event
function proxyComplete(event:MapPointProxyEvent):void
{
if (event.request is MapPointTokenRequest)
{
// token ready!
trace("token: " + proxy.getToken());
}
}
You can also define the token in the
initialize() method as a second parameter,
if it was previoulsy obtained by other means.
data:String [read-only]Implementation
public function get data():String
loader:URLLoader [read-only]Implementation
public function get loader():URLLoader
loading:Boolean [read-only]Implementation
public function get loading():Boolean
request:IMapPointRequest [read-only]
Implementation
public function get request():IMapPointRequest
public static var TOKEN:String
public function MapPointProxy(proxyURL:String, prv:PrivateClass)Parameters
| proxyURL:String |
| |
| prv:PrivateClass |
public static function getInstance():MapPointProxy
Returns
public function getToken():String
Returns
public static function initialize(proxyURL:String, token:String = ""):MapPointProxyParameters
| proxyURL:String |
| |
| token:String (default = "") |
Returns
public function sendRequest(request:IMapPointRequest):BooleanParameters
Returns
public function setToken(token:String):voidParameters
© 2007-2009 advanced flash components