Packagecom.addicted2flash.data.loader
Classpublic class LoaderQueue
ImplementsIDataServiceObserver

This class represents a FIFO implementation of IDataServices. With this class it is possible to create and process services application wide in a queue. Also it is possible to pause, stop and resume the process.



Public Properties
 PropertyDefined by
  state : String
[static][read-only] Returns the state of LoaderQueue.
LoaderQueue
Public Methods
 MethodDefined by
  
create(loader:ILoader, request:URLRequest, context:LoaderContext = null, attachment:int = null, priority:* = 0):IDataService
[static] Creates and returns IDataService.
LoaderQueue
  
group(... services):IDataServiceGroup
[static] Creates and returns a IDataServiceGroup that handles a list of IDataServices simultaneously.
LoaderQueue
  
pause():void
[static] Pauses the loading progress of active services.
LoaderQueue
  
remove(service:IDataService):void
[static] Removes specific IDataService from the queue and stop the process of the specific service that is running.
LoaderQueue
  
resume():void
[static] Resumes the loading progress of active services.
LoaderQueue
  
stop():void
[static] Stopps the loading progress of active services and remove all IDataServices from the queue.
LoaderQueue
Property detail
stateproperty
state:String  [read-only]

Returns the state of LoaderQueue.

Implementation
    public static function get state():String
Method detail
create()method
public static function create(loader:ILoader, request:URLRequest, context:LoaderContext = null, attachment:int = null, priority:* = 0):IDataService

Creates and returns IDataService.

Parameters
loader:ILoaderILoader for different loading procedures (f.e. bitmaps or xml)
 
request:URLRequestURLRequest
 
context:LoaderContext (default = null) — loader context
 
attachment:int (default = null) — any data (f.e. data binded to the request)
 
priority:* (default = 0) — priority

Returns
IDataService — data service
group()method 
public static function group(... services):IDataServiceGroup

Creates and returns a IDataServiceGroup that handles a list of IDataServices simultaneously.

Parameters
... services — list of services

Returns
IDataServiceGroup — a IDataServiceGroup that handles a list of IDataServices simultaneously
pause()method 
public static function pause():void

Pauses the loading progress of active services.

remove()method 
public static function remove(service:IDataService):void

Removes specific IDataService from the queue and stop the process of the specific service that is running.

Parameters
service:IDataService — queued IDataService
resume()method 
public static function resume():void

Resumes the loading progress of active services.

stop()method 
public static function stop():void

Stopps the loading progress of active services and remove all IDataServices from the queue.