Packagech.capi.events
Classpublic class MassLoadEvent
InheritanceMassLoadEvent Inheritance flash.events.Event

Represents an event occuring during a massloading.



Public Properties
 PropertyDefined By
  closeEvent : Event
[read-only] Defines the event that occured when the file was closed.
MassLoadEvent
  loadedIndex : int
[read-only] Defines the index of the file in the loaded queue.
MassLoadEvent
  loadManager : ILoadManager
[read-only] Defines the ILoadManager being loaded.
MassLoadEvent
  priority : int
The priority of the file.
MassLoadEvent
  queueIndex : int
[read-only] Defines the index of the file in the loading queue.
MassLoadEvent
  staticIndex : int
Defines the index of the file.
MassLoadEvent
Public Methods
 MethodDefined By
  
MassLoadEvent(type:String, file:ILoadManager = null, closeEvent:Event = null, staticIndex:int = -1, queueIndex:int = -1, loadedIndex:int = -1, priority:int = 0)
Creates a new MassLoadEvent object.
MassLoadEvent
  
clone():Event
Creates a copy of the MassLoadEvent object and sets the value of each property to match that of the original.
MassLoadEvent
  
Retrieves the ILoadManager as ILoadableFile.
MassLoadEvent
  
isError():Boolean
Get if an error has occured during the download of the specified file.
MassLoadEvent
  
isLoadableFile():Boolean
Checks if the contained ILoadManager is a ILoadableFile.
MassLoadEvent
  
toString():String
Returns the MassLoadEvent in a String.
MassLoadEvent
Public Constants
 ConstantDefined By
  FILE_CLOSE : String = fileClose
[static] Event when the loading of a file stops.
MassLoadEvent
  FILE_OPEN : String = fileOpen
[static] Event when the loading of a file starts.
MassLoadEvent
  FILE_PROGRESS : String = fileProgress
[static] Event when the loading of a file progresses.
MassLoadEvent
Property Detail
closeEventproperty
closeEvent:Event  [read-only]

Defines the event that occured when the file was closed.


Implementation
    public function get closeEvent():Event
loadedIndexproperty 
loadedIndex:int  [read-only]

Defines the index of the file in the loaded queue. It indicates how many files have been loaded before the loadManager.


Implementation
    public function get loadedIndex():int
loadManagerproperty 
loadManager:ILoadManager  [read-only]

Defines the ILoadManager being loaded.


Implementation
    public function get loadManager():ILoadManager

See also

priorityproperty 
priority:int  [read-write]

The priority of the file. If the file wasn't loaded in a PriorityMassLoader this value will be 0.


Implementation
    public function get priority():int
    public function set priority(value:int):void
queueIndexproperty 
queueIndex:int  [read-only]

Defines the index of the file in the loading queue.


Implementation
    public function get queueIndex():int

See also

staticIndexproperty 
staticIndex:int  [read-write]

Defines the index of the file. The index is unique for a ILoadableFile in a specific IMassLoader. The file may be removed before the event is dispatched. If the index is not known, this property is -1.


Implementation
    public function get staticIndex():int
    public function set staticIndex(value:int):void

See also

Constructor Detail
MassLoadEvent()Constructor
public function MassLoadEvent(type:String, file:ILoadManager = null, closeEvent:Event = null, staticIndex:int = -1, queueIndex:int = -1, loadedIndex:int = -1, priority:int = 0)

Creates a new MassLoadEvent object.

Parameters
type:String — The type.
 
file:ILoadManager (default = null) — The file being loaded.
 
closeEvent:Event (default = null) — The Event dispatched to close the file. This event is cloned before beeing stored.
 
staticIndex:int (default = -1) — The static index of the file in the loading queue.
 
queueIndex:int (default = -1) — The index of the file in the loading queue.
 
loadedIndex:int (default = -1) — The index of the file in the loaded queue.
 
priority:int (default = 0) — The file priority.
Method Detail
clone()method
override public function clone():Event

Creates a copy of the MassLoadEvent object and sets the value of each property to match that of the original.

Returns
Event — The cloned Event.
getFile()method 
public function getFile():ILoadableFile

Retrieves the ILoadManager as ILoadableFile.

Returns
ILoadableFile — The ILoadManager as ILoadableFile.

Throws
Error If — the ILoadManager is not a ILoadableFile.

See also

isError()method 
public function isError():Boolean

Get if an error has occured during the download of the specified file. If the error event is a IOErrorEvent or a SecurityErrorEvent, then the value true is returned.

Returns
Booleantrue if there was an error. A FILE_OPEN event always return false.

See also

isLoadableFile()method 
public function isLoadableFile():Boolean

Checks if the contained ILoadManager is a ILoadableFile.

Returns
Booleantrue if the ILoadManager is a ILoadableFile.
toString()method 
override public function toString():String

Returns the MassLoadEvent in a String.

Returns
String — A String containing the MassLoadEvent properties values.
Constant Detail
FILE_CLOSEConstant
public static const FILE_CLOSE:String = fileClose

Event when the loading of a file stops.

FILE_OPENConstant 
public static const FILE_OPEN:String = fileOpen

Event when the loading of a file starts.

FILE_PROGRESSConstant 
public static const FILE_PROGRESS:String = fileProgress

Event when the loading of a file progresses.