[static] Efficiently determines whether or not one class descends from
another in inheritance hierarchy- class relationships are cached
by the ClassUtils implementation-
(uses org.as3commons lib to quickly discover class hierarchy.
Implementation public function get hostObjectDelegate():HostObject public function set hostObjectDelegate(value:HostObject):void
Constructor Detail
CSHostObject
()
Constructor
public function CSHostObject(delegateHostObject:HostObject = null)
Since :
CS5
Removed :
CS5.5
Constructor
Parameters
delegateHostObject:HostObject (default = null)
Method Detail
callProperty
()
method
override flash_proxy function callProperty(methodName:*, ... args):*
Since :
CS5
Removed :
CS5.5
Parameters
methodName:*
... args
Returns
*
createWithArgs
()
method
protected function createWithArgs(args:Array):void
Since :
CS5
Removed :
CS5.5
Parameters
args:Array
filterArgsForHBAPI
()
method
public static function filterArgsForHBAPI(args:Array):Array
Since :
CS5
Removed :
CS5.5
Function to clean up the argument list and put it into a format that
makes sense for HBAPI. Note that this occurs after replaceDefaultArgs
and is just before we do, say, a __call to the host.
Parameters
args:Array — the inbound actual parameters
Returns
Array — array of parameters that will make sense for the host when sent over HBAPI
filterSingleObjectForHBAPI
()
method
public static function filterSingleObjectForHBAPI(value:Object):Object
Since :
CS5
Removed :
CS5.5
Parameters
value:Object — object to translate for forward calls
Returns
Object — the translated object that can safely be used to call through to the host
getClassObjectForName
()
method
public static function getClassObjectForName(className:String):HostObject
Since :
CS5
Removed :
CS5.5
This returns a "Class" object, meaning, a HostObject that can be used
to make static function calls or get static properties
Parameters
className:String — qualified name of the class object
Returns
HostObject — a class object for given className, which is the root HostObject if the className is empty or null
getProperty
()
method
override flash_proxy function getProperty(name:*):*
Since :
CS5
Removed :
CS5.5
Parameters
name:*
Returns
*
getSpecialTranslation
()
method
public static function getSpecialTranslation(className:String, ho:HostObject, expectedReturnType:Class, ownerName:String):*
Since :
CS5
Removed :
CS5.5
Parameters
className:String
ho:HostObject
expectedReturnType:Class
ownerName:String
Returns
*
hostCall
()
method
public function hostCall(name:String, expectedReturnType:Class, rawargs:Array):*
Since :
CS5
Removed :
CS5.5
Encapsulates a function call to the host
Parameters
name:String — the name of the host function to call
expectedReturnType:Class — what type we believe the host should return
rawargs:Array — the actual parameters sent by the client
Returns
* — a wrapped host object (or perhaps more primitive type?)
hostCallStatic
()
method
public static function hostCallStatic(className:String, methodName:String, expectedReturnType:Class, rawargs:Array):*
Since :
CS5
Removed :
CS5.5
Implements a safe call of a static method on the host
Parameters
className:String — identifies the host classname that we want to call the method on
methodName:String — identifies method to call
expectedReturnType:Class — what class we want the return type to be
rawargs:Array — the arguments to pass to the method
Returns
*
hostCreate
()
method
protected function hostCreate(args:Array):void
Since :
CS5
Removed :
CS5.5
Parameters
args:Array
hostGet
()
method
public function hostGet(name:String, expectedReturnType:Class):*
Since :
CS5
Removed :
CS5.5
Encapsulates a property get to the host
Parameters
name:String — the name of the property to dereference
expectedReturnType:Class — what type we believe the host should return for this property
Returns
* — a wrapped host object (or perhaps more primitive type?), returns null in the event that the host throws an error on the getter
hostGetIndex
()
method
public function hostGetIndex(idx:Object, expectedReturnType:Class):*
Since :
CS5
Removed :
CS5.5
Encapsulates a indexed get to the host
Parameters
idx:Object — the id of the index (either integer, or a name)
expectedReturnType:Class — what type we believe the host should return for this property
Returns
* — a wrapped host object (or perhaps more primitive type?)
hostGetStatic
()
method
public static function hostGetStatic(className:String, propertyName:String, expectedReturnType:Class):*
Since :
CS5
Removed :
CS5.5
Implements a safe get of a static property on the host
Used by for instance, all the enum implementations.
Marked public to be easily testable.
Parameters
className:String — identifies the host classname that we want a property from
propertyName:String — identifies property of interest
expectedReturnType:Class — what class we want the return type to be
Returns
*
hostSet
()
method
public function hostSet(name:String, rawvalue:*):void
Since :
CS5
Removed :
CS5.5
Encapsulates a property set to the host
Parameters
name:String — the name of the property to set
rawvalue:* — the new value it should be set to
hostSetStatic
()
method
public static function hostSetStatic(className:String, propertyName:String, rawvalue:*):*
Since :
CS5
Removed :
CS5.5
Implements a safe set of a static property on the host
Parameters
className:String — identifies the host classname that we want a property from
propertyName:String — identifies property of interest
rawvalue:* — the value to set the property to
Returns
*
isDescendedFrom
()
method
public static function isDescendedFrom(clz:Class, ancClass:Class):Boolean
Since :
CS5
Removed :
CS5.5
Efficiently determines whether or not one class descends from
another in inheritance hierarchy- class relationships are cached
by the ClassUtils implementation-
(uses org.as3commons lib to quickly discover class hierarchy.
Parameters
clz:Class — the class whose ancestry we're interested in
ancClass:Class — a potential ancestor
Returns
Boolean — true if clz descended from ancClass, false otherwise
replaceDefaultArgs
()
method
public function replaceDefaultArgs(args:Array, defaultArgs:Array):Array
Since :
CS5
Removed :
CS5.5
Function to tidy up arguments prior to call.
Marked public to be more easily testable.
TODO: this could be static, it doesn't need to be an instance func
Parameters
args:Array
defaultArgs:Array
Returns
Array
setProperty
()
method
override flash_proxy function setProperty(name:*, value:*):void
Since :
CS5
Removed :
CS5.5
Parameters
name:*
value:*
wrapReturnedHostObject
()
method
public static function wrapReturnedHostObject(rawObject:Object, expectedReturnType:Class, client:CSHostObject, propertyName:String):*
Since :
CS5
Removed :
CS5.5
Method used on static/normal get/ hostcalls
Parameters
rawObject:Object — hostobject that came back from host
expectedReturnType:Class — class that we expect to hand back return to client as