Packageorg.mvcexpress.base
Classpublic class ProxyMap
InheritanceProxyMap Inheritance Object

ProxyMap is responsible for storing proxy objects and handling injection.



Public Methods
 MethodDefined By
  
ProxyMap(messenger:Messenger)
CONSTRUCTOR
ProxyMap
  
isMapped(proxyObject:Proxy, injectClass:Class = null, name:String):Boolean
Checks if proxy object is already mapped.
ProxyMap
  
listMappings():String
Returns text of all mapped proxy objects, and keys they are mapped to.
ProxyMap
  
map(proxyObject:Proxy, injectClass:Class = null, name:String):void
Maps proxy object to injectClass and name.
ProxyMap
  
unmap(injectClass:Class, name:String):void
Removes proxy mapped for injection by injectClass and name.
ProxyMap
Constructor Detail
ProxyMap()Constructor
public function ProxyMap(messenger:Messenger)

CONSTRUCTOR

Parameters
messenger:Messenger
Method Detail
isMapped()method
public function isMapped(proxyObject:Proxy, injectClass:Class = null, name:String):Boolean

Checks if proxy object is already mapped.

Parameters

proxyObject:Proxy — Proxy instance to use for injection.
 
injectClass:Class (default = null) — Optional class to use for injection, if null proxyObject class is used. It is helpful if you want to map proxy interface or subclass.
 
name:String — Optional name if you need more then one proxy instance of same class.

Returns
Boolean — true if object is already mapped.
listMappings()method 
public function listMappings():String

Returns text of all mapped proxy objects, and keys they are mapped to.

Returns
String — Text string with all mapped proxies.
map()method 
public function map(proxyObject:Proxy, injectClass:Class = null, name:String):void

Maps proxy object to injectClass and name.

Parameters

proxyObject:Proxy — Proxy instance to use for injection.
 
injectClass:Class (default = null) — Optional class to use for injection, if null proxyObject class is used. It is helpful if you want to map proxy interface or subclass.
 
name:String — Optional name if you need more then one proxy instance of same class.

unmap()method 
public function unmap(injectClass:Class, name:String):void

Removes proxy mapped for injection by injectClass and name. If mapping does not exists - it will fail silently.

Parameters

injectClass:Class — class previously mapped for injection
 
name:String — name added to class, that was previously mapped for injection