| Package | net.dmclaren.utils |
| Class | public class AsyncProcessor |
| Inheritance | AsyncProcessor flash.events.EventDispatcher |
| Property | Defined by | ||
|---|---|---|---|
| processingFunc : Function
The function which does the processing work.
| AsyncProcessor | ||
| processingTimeLimit : Number
The maximum amount of time allowed for processing during a single frame.
| AsyncProcessor | ||
| Property | Defined by | ||
|---|---|---|---|
| _processingFunc : Function | AsyncProcessor | ||
| _processingTimeLimit : Number | AsyncProcessor | ||
| Method | Defined by | ||
|---|---|---|---|
|
AsyncProcessor(processingFunc:Function = null, processingTimeLimit:Number = 300)
Creates a new asynchronous processor instance.
| AsyncProcessor | ||
|
start():void
Starts the asynchronous processing.
| AsyncProcessor | ||
| Method | Defined by | ||
|---|---|---|---|
|
startProcessing():void
Starts the asynchronous processing.
| AsyncProcessor | ||
|
stopProcessing():void
Stops the asynchronous processing.
| AsyncProcessor | ||
| _processingFunc | property |
protected var _processingFunc:Function
| processingFunc | property |
processingFunc:Function [read-write]The function which does the processing work. It should take no arguments. If processing is complete it must return true, otherwise false. The function will be called multiple times during each frame until the frame's time limit is reached or until it returns true.
Implementation public function get processingFunc():Function
public function set processingFunc(value:Function):void
| _processingTimeLimit | property |
protected var _processingTimeLimit:Number
| processingTimeLimit | property |
processingTimeLimit:Number [read-write]The maximum amount of time allowed for processing during a single frame. This value should be kept below the duration of a single frame.
Implementation public function get processingTimeLimit():Number
public function set processingTimeLimit(value:Number):void
| AsyncProcessor | () | constructor |
public function AsyncProcessor(processingFunc:Function = null, processingTimeLimit:Number = 300)Creates a new asynchronous processor instance.
ParametersprocessingFunc:Function (default = null) |
|
processingTimeLimit:Number (default = 300) |
| start | () | method |
public function start():voidStarts the asynchronous processing.
| startProcessing | () | method |
protected function startProcessing():voidStarts the asynchronous processing.
| stopProcessing | () | method |
protected function stopProcessing():voidStops the asynchronous processing.