| Package | com.bourre.commands |
| Class | public class ASyncBatch |
| Inheritance | ASyncBatch AbstractSyncCommand AbstractCommand |
| Implements | ASyncCommandListener, MacroCommand |
| Subclasses | ASyncQueue |
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
onCommandEnd event.
The Event object received in the execute is passed
to each commands contained in this batch.
The ASyncBatch class extends AbstractSyncCommand
and so, dispatch an onCommandEnd event at the execution end
of all commands.
| Property | Defined by | ||
|---|---|---|---|
| _aCommands : Array
Contains all commands currently in this macro command
| ASyncBatch | ||
![]() | _bIsRunning : Boolean
A boolean value which indicates if this command is currently
processing.
| AbstractSyncCommand | |
| _eEvent : Event
Event received by the batch and redispatched to
the internal commands execute method.
| ASyncBatch | ||
![]() | _eOnCommandEnd : BasicEvent
An event instance used as event object when dispatching
the
onCommandEnd event to its listener. | AbstractSyncCommand | |
| _nIndex : Number
Store the index of the currently executed command.
| ASyncBatch | ||
![]() | _oEB : EventBroadcaster
The internal event broadcaster.
| AbstractSyncCommand | |
| _oLastCommand : ASyncCommand
Last executed command
| ASyncBatch | ||
![]() | _owner : Plugin
A reference to the plugin owner of this command.
| AbstractCommand | |
| Method | Defined by | ||
|---|---|---|---|
|
Creates a new asynchronous batch object.
| ASyncBatch | ||
![]() |
addASyncCommandListener(listener:ASyncCommandListener, ... rest):Boolean
Adds the passed-in listener as listener for the
onCommandEnd
event of this command. | AbstractSyncCommand | |
|
addCommand(command:Command):Boolean
Adds the passed-in command to this macro command.
| ASyncBatch | ||
|
execute(e:Event = null):void
Starts the execution of the batch.
| ASyncBatch | ||
![]() |
fireCommandEndEvent():void
Fires the
onCommandEnd event to the listeners
of this command. | AbstractSyncCommand | |
![]() |
Returns the exclusive logger object owned by the plugin.
| AbstractCommand | |
![]() |
getModel(key:String):AbstractModel
Returns a reference to the model
AbstractModel. | AbstractCommand | |
![]() |
Returns a reference to the owner of this command.
| AbstractCommand | |
![]() |
getView(key:String):AbstractView
Returns a reference to the view
AbstractView. | AbstractCommand | |
![]() |
isModelRegistered(key:String):Boolean
Check if a model
AbstractModel is registered
with passed key in owner's ModelLocator. | AbstractCommand | |
![]() |
isRunning():Boolean
Returns
true if this command is currently
processing. | AbstractSyncCommand | |
![]() |
isViewRegistered(key:String):Boolean
Check if a view
AbstractView is registered
with passed key in owner's ViewLocator. | AbstractCommand | |
|
onCommandEnd(e:Event):void
Receive events from its internal asynchronous commands.
| ASyncBatch | ||
![]() |
removeASyncCommandListener(listener:ASyncCommandListener):Boolean
Removes the passed-in listener for listening
the
onCommandEnd event of this command. | AbstractSyncCommand | |
|
removeCommand(command:Command):Boolean
Removes the passed-in command from this macro command.
| ASyncBatch | ||
![]() |
run():void
Implementation of the
Runnable interface,
a call to run() is equivalent to a call to
execute without argument. | AbstractSyncCommand | |
|
Defines the plugin owner of this command.
| ASyncBatch | ||
![]() |
toString():String
Returns the string representation of the object.
| AbstractSyncCommand | |
| Method | Defined by | ||
|---|---|---|---|
|
_hasNext():Boolean
Returns
true if there is a command
to execute. | ASyncBatch | ||
|
Returns the next command to execute.
| ASyncBatch | ||
![]() |
firePrivateEvent(e:Event):void
Fires a private event directly on this command's owner.
| AbstractCommand | |
| _aCommands | property |
protected var _aCommands:Array
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Contains all commands currently in this macro command
| _eEvent | property |
protected var _eEvent:Event
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Event received by the batch and redispatched to the internal commands execute method.
| _nIndex | property |
protected var _nIndex:Number
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Store the index of the currently executed command.
| _oLastCommand | property |
protected var _oLastCommand:ASyncCommand
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Last executed command
| ASyncBatch | () | constructor |
public function ASyncBatch()
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Creates a new asynchronous batch object.
| _hasNext | () | method |
protected function _hasNext():Boolean
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Returns true if there is a command
to execute.
Boolean — true if there is a command
to execute
|
| _next | () | method |
protected function _next():ASyncCommand
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Returns the next command to execute.
ReturnsASyncCommand —
the next command to execute
|
| addCommand | () | method |
public function addCommand(command:Command):Boolean
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Adds the passed-in command to this macro command.
Parameterscommand:Command — command to add in this macro command
|
Boolean — true if the command have been
succesfully added. The addCommand
ensure that the command exist in the macro
command at the end of the call
|
| execute | () | method |
public override function execute(e:Event = null):void
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Starts the execution of the batch. The received event is registered and then passed to sub commands.
Parameterse:Event (default = null) |
| onCommandEnd | () | method |
public function onCommandEnd(e:Event):void
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Receive events from its internal asynchronous commands.
Parameterse:Event |
| removeCommand | () | method |
public function removeCommand(command:Command):Boolean
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Removes the passed-in command from this macro command.
Parameterscommand:Command — command to remove from this macro command
|
Boolean — true if the command have been
succesfully removed
|
| setOwner | () | method |
public override function setOwner(owner:Plugin):void
| Player version: | Flash Player 9.0 |
| Language version: | ActionScript 3.0 |
Defines the plugin owner of this command.
Generally the owner is defined by the
FrontController of a plugin when
it instantiate a command.
owner:Plugin — plugin which will own the command
|