Package | org.spicefactory.parsley.messaging |
Class | public class MessageHandler |
Inheritance | MessageHandler Object |
Method | Defined By | ||
---|---|---|---|
apply(builder:ObjectDefinitionBuilder):void
Applies this configuration to the specified definition builder. | MessageHandler | ||
forMethod(method:String):MessageHandler [static]
Creates a new builder for a message handler. | MessageHandler | ||
messageProperties(value:Array):MessageHandler
Sets the optional list of names of properties of the message that should be used as method parameters
instead passing the message itself as a parameter. | MessageHandler | ||
order(value:int):MessageHandler
Sets the execution order for this handler. | MessageHandler | ||
scope(name:String):MessageHandler
Sets the name of the scope this handler should be applied to. | MessageHandler | ||
selector(value:*):MessageHandler
Sets an optional selector value to be used in addition to selecting messages by type. | MessageHandler | ||
type(value:Class):MessageHandler
Sets the type of the messages the handler wants to handle. | MessageHandler |
apply | () | method |
public function apply(builder:ObjectDefinitionBuilder):void
Applies this configuration to the specified definition builder.
Parameters
builder:ObjectDefinitionBuilder — the builder to apply this configuration to
|
forMethod | () | method |
public static function forMethod(method:String):MessageHandler
Creates a new builder for a message handler.
Parameters
method:String — the name of the target method to invoke
|
MessageHandler — a new builder for a message handler
|
messageProperties | () | method |
public function messageProperties(value:Array):MessageHandler
Sets the optional list of names of properties of the message that should be used as method parameters instead passing the message itself as a parameter.
Parameters
value:Array — list of names of properties of the message that should be used as method parameters
|
MessageHandler — this builder for method chaining
|
order | () | method |
public function order(value:int):MessageHandler
Sets the execution order for this handler. Will be processed in ascending order.
The default is int.MAX_VALUE
.
Parameters
value:int — the execution order for this handler
|
MessageHandler — this builder instance for method chaining
|
scope | () | method |
public function scope(name:String):MessageHandler
Sets the name of the scope this handler should be applied to.
Parameters
name:String — the name of the scope this handler should be applied to
|
MessageHandler — this builder instance for method chaining
|
selector | () | method |
public function selector(value:*):MessageHandler
Sets an optional selector value to be used in addition to selecting messages by type.
Parameters
value:* — an optional selector value to be used in addition to selecting messages by type
|
MessageHandler — this builder instance for method chaining
|
type | () | method |
public function type(value:Class):MessageHandler
Sets the type of the messages the handler wants to handle.
Parameters
value:Class — the type of the messages the handler wants to handle
|
MessageHandler — this builder instance for method chaining
|