RelayResponder2 Class
Class com.probertson.rpc.RelayResponder2
Inheritance
>
RelayResponder2
Implements mx.rpc.Responder
An alternative to mx.rpc.RelayResponder, with stricter type safety and better scope
control because the result function and fault function are typed as Function
rather than String (as in the original).
| Constructor Summary |
|---|
| | Creates a RelayResponder2 instance. |
| Method Summary |
|---|
| Void | Part of the mx.rpc.Responder implementation. |
| Void | Part of the mx.rpc.Responder implementation. |
RelayResponder2
public function RelayResponder2(scopeObj:Object, resultFunc:Function, faultFunc:Function)
Creates a RelayResponder2 instance.
Parameters:
scopeObj- The object in whose scope the result and fault functions will be
executed (the object that will be represented by "this" in those
functions).
resultFunc- The function to be called when a remote method call returns a result.
That function can accept a single mx.rpc.ResultEvent argument.
faultFunc- The function to be called when a remote method call raises an error.
That function can accept a single mx.rpc.FaultEvent argument.
onFault
public function onFault(fault:FaultEvent):Void
Part of the mx.rpc.Responder implementation. This method will be called when a remote
method call raises an error, and forwards that call on to the function specified in the
constructor's faultFunc argument.
onResult
public function onResult(result:ResultEvent):Void
Part of the mx.rpc.Responder implementation. This method will be called when a remote
method call successfully returns a result, and forwards that call on to the function specified in the
constructor's resultFunc argument.
Documentation generated by BLDoc Community Edition from B-Line Express.