Packageorg.spicefactory.parsley.comobserver
Classpublic class CommandResult
InheritanceCommandResult Inheritance Object

API for configuring methods which should be invoked when the result of a matching asynchronous command execution has been received.



Public Methods
 MethodDefined By
  
Applies this configuration to the specified definition builder.
CommandResult
  
forMethod(method:String):CommandResult
[static] Creates a new builder for a command result handler.
CommandResult
  
immediate(value:Boolean):CommandResult
Indicates whether the result should be processed immediately after the command finished executing (when set to true) or after the entire sequence or flow finished (when set to false - the default).
CommandResult
  
order(value:int):CommandResult
Sets the execution order for this message receiver.
CommandResult
  
scope(name:String):CommandResult
Sets the name of the scope this message receiver should be applied to.
CommandResult
  
Sets an optional selector value to be used in addition to selecting messages by type.
CommandResult
  
type(value:Class):CommandResult
Sets the type of the messages the message receiver wants to handle.
CommandResult
Method Detail
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):CommandResult

Creates a new builder for a command result handler.

Parameters

method:String — the method that handles the result

Returns
CommandResult — a new builder for a command result handler
immediate()method 
public function immediate(value:Boolean):CommandResult

Indicates whether the result should be processed immediately after the command finished executing (when set to true) or after the entire sequence or flow finished (when set to false - the default). Has no effect on the execution of a single command that is not a sequence or flow.

Parameters

value:Boolean — indicates whether the result should be processed immediately

Returns
CommandResult — this builder instance for method chaining
order()method 
public function order(value:int):CommandResult

Sets the execution order for this message receiver. Will be processed in ascending order. The default is int.MAX_VALUE.

Parameters

value:int — the execution order for this message receiver

Returns
CommandResult — this builder instance for method chaining
scope()method 
public function scope(name:String):CommandResult

Sets the name of the scope this message receiver should be applied to.

Parameters

name:String — the name of the scope this message receiver should be applied to

Returns
CommandResult — this builder instance for method chaining
selector()method 
public function selector(value:*):CommandResult

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

Returns
CommandResult — this builder instance for method chaining
type()method 
public function type(value:Class):CommandResult

Sets the type of the messages the message receiver wants to handle.

Parameters

value:Class — the type of the messages the message receiver wants to handle

Returns
CommandResult — this builder instance for method chaining