Packageaway3d.loaders.parsers
Classpublic class AWD2Parser
InheritanceAWD2Parser Inheritance ParserBase Inheritance flash.events.EventDispatcher

AWDParser provides a parser for the AWD data type.



Public Properties
 PropertyDefined By
 InheriteddataFormat : String
[read-only] The data format of the file data to be parsed.
ParserBase
 Inheriteddependencies : Vector.<ResourceDependency>
[read-only] A list of dependencies that need to be loaded and resolved for the object being parsed.
ParserBase
 InheritedparsingComplete : Boolean
[read-only]
ParserBase
 InheritedparsingFailure : Boolean
ParserBase
 InheritedparsingPaused : Boolean
[read-only]
ParserBase
Protected Properties
 PropertyDefined By
 Inherited_data : *
ParserBase
 Inherited_dataFormat : String
ParserBase
 Inherited_frameLimit : Number
ParserBase
 Inherited_lastFrameTime : Number
ParserBase
Public Methods
 MethodDefined By
  
Creates a new AWDParser object.
AWD2Parser
 Inherited
isBitmapDataValid(bitmapData:BitmapData):Boolean
Validates a bitmapData loaded before assigning to a default BitmapMaterial
ParserBase
 Inherited
parseAsync(data:*, frameLimit:Number = 30):void
Parse data (possibly containing bytearry, plain text or BitmapAsset) asynchronously, meaning that the parser will periodically stop parsing so that the AVM may proceed to the next frame.
ParserBase
  
supportsData(data:*):Boolean
[static] Tests whether a data block can be parsed by the parser.
AWD2Parser
  
supportsType(extension:String):Boolean
[static] Indicates whether or not a given file extension is supported by the parser.
AWD2Parser
Protected Methods
 MethodDefined By
 Inherited
addDependency(id:String, req:URLRequest, retrieveAsRawData:Boolean = false, data:* = null, suppressErrorEvents:Boolean = false):void
ParserBase
 Inherited
constructSubGeometries(verts:Vector.<Number>, indices:Vector.<uint>, uvs:Vector.<Number>, normals:Vector.<Number>, tangents:Vector.<Number>, weights:Vector.<Number>, jointIndices:Vector.<Number>):Vector.<SubGeometry>
Build a list of sub-geometries from raw data vectors, splitting them up in such a way that they won't exceed buffer length limits.
ParserBase
 Inherited
constructSubGeometry(verts:Vector.<Number>, indices:Vector.<uint>, uvs:Vector.<Number>, normals:Vector.<Number>, tangents:Vector.<Number>, weights:Vector.<Number>, jointIndices:Vector.<Number>):SubGeometry
Build a sub-geometry from data vectors.
ParserBase
 Inherited
dieWithError(message:String = Unknown parsing error):void
ParserBase
 Inherited
finalizeAsset(asset:IAsset, name:String = null):void
ParserBase
 Inherited
Finish parsing the data.
ParserBase
 Inherited
getByteData():ByteArray
ParserBase
 Inherited
getTextData():String
ParserBase
 Inherited
hasTime():Boolean
Tests whether or not there is still time left for parsing within the maximum allowed time frame per session.
ParserBase
 Inherited
onInterval(event:TimerEvent = null):void
Called when the parsing pause interval has passed and parsing can proceed.
ParserBase
 Inherited
ParserBase
  
proceedParsing():Boolean
[override] Parse the next block of data.
AWD2Parser
Events
 Event Summary Defined By
 InheritedDispatched when an animation node has been constructed from a resource.ParserBase
 InheritedDispatched when an animation set has been constructed from a group of animation state resources.ParserBase
 InheritedDispatched when an animation state has been constructed from a group of animation node resources.ParserBase
 InheritedDispatched when a animator asset has been constructed from a resource.ParserBase
 InheritedDispatched when any asset finishes parsing.ParserBase
 InheritedDispatched when a container asset has been constructed from a resource.ParserBase
 InheritedDispatched when a geometry asset has been constructed from a resource.ParserBase
 InheritedDispatched when a material asset has been constructed from a resource.ParserBase
 InheritedDispatched when the parsing finishes.ParserBase
 InheritedDispatched if an error was caught during parsing.ParserBase
 InheritedDispatched when parser pauses to wait for dependencies, used internally to trigger loading of dependencies which are then returned to the parser through it's interface in the arcane namespace.ParserBase
 InheritedDispatched when a skeleton asset has been constructed from a resource.ParserBase
 InheritedDispatched when a skeleton pose asset has been constructed from a resource.ParserBase
 InheritedDispatched when an animation state transition has been constructed from a group of animation node resources.ParserBase
 InheritedDispatched when a texture asset has been constructed from a resource.ParserBase
Public Constants
 ConstantDefined By
  AWD_FIELD_BADDR : uint = 23
[static]
AWD2Parser
  AWD_FIELD_BOOL : uint = 21
[static]
AWD2Parser
  AWD_FIELD_BYTEARRAY : uint = 32
[static]
AWD2Parser
  AWD_FIELD_COLOR : uint = 22
[static]
AWD2Parser
  AWD_FIELD_FLOAT32 : uint = 7
[static]
AWD2Parser
  AWD_FIELD_FLOAT64 : uint = 8
[static]
AWD2Parser
  AWD_FIELD_INT16 : uint = 2
[static]
AWD2Parser
  AWD_FIELD_INT32 : uint = 3
[static]
AWD2Parser
  AWD_FIELD_INT8 : uint = 1
[static]
AWD2Parser
  AWD_FIELD_MTX3x2 : uint = 44
[static]
AWD2Parser
  AWD_FIELD_MTX3x3 : uint = 45
[static]
AWD2Parser
  AWD_FIELD_MTX4x3 : uint = 46
[static]
AWD2Parser
  AWD_FIELD_MTX4x4 : uint = 47
[static]
AWD2Parser
  AWD_FIELD_STRING : uint = 31
[static]
AWD2Parser
  AWD_FIELD_UINT16 : uint = 5
[static]
AWD2Parser
  AWD_FIELD_UINT32 : uint = 6
[static]
AWD2Parser
  AWD_FIELD_UINT8 : uint = 4
[static]
AWD2Parser
  AWD_FIELD_VECTOR2x1 : uint = 41
[static]
AWD2Parser
  AWD_FIELD_VECTOR3x1 : uint = 42
[static]
AWD2Parser
  AWD_FIELD_VECTOR4x1 : uint = 43
[static]
AWD2Parser
  DEFLATE : uint = 1
[static]
AWD2Parser
  LZMA : uint = 2
[static]
AWD2Parser
  UNCOMPRESSED : uint = 0
[static]
AWD2Parser
Protected Constants
 ConstantDefined By
 InheritedMORE_TO_PARSE : Boolean = false
[static] Returned by proceedParsing to indicate more parsing is needed, allowing asynchronous parsing.
ParserBase
 InheritedPARSING_DONE : Boolean = true
[static] Returned by proceedParsing to indicate no more parsing is needed.
ParserBase
Constructor Detail
AWD2Parser()Constructor
public function AWD2Parser()

Creates a new AWDParser object.

Method Detail
proceedParsing()method
override protected function proceedParsing():Boolean

Parse the next block of data.

Returns
Boolean — Whether or not more data needs to be parsed. Can be ParserBase.PARSING_DONE or ParserBase.MORE_TO_PARSE.
resolveDependency()method 
override arcane function resolveDependency(resourceDependency:ResourceDependency):void

Resolve a dependency when it's loaded. For example, a dependency containing an ImageResource would be assigned to a Mesh instance as a BitmapMaterial, a scene graph object would be added to its intended parent. The dependency should be a member of the dependencies property.

Parameters

resourceDependency:ResourceDependency — The dependency to be resolved.

resolveDependencyFailure()method 
override arcane function resolveDependencyFailure(resourceDependency:ResourceDependency):void

Resolve a dependency loading failure. Used by parser to eventually provide a default map

Parameters

resourceDependency:ResourceDependency — The dependency to be resolved.

supportsData()method 
public static function supportsData(data:*):Boolean

Tests whether a data block can be parsed by the parser.

Parameters

data:* — The data block to potentially be parsed.

Returns
Boolean — Whether or not the given data is supported.
supportsType()method 
public static function supportsType(extension:String):Boolean

Indicates whether or not a given file extension is supported by the parser.

Parameters

extension:String — The file extension of a potential file to be parsed.

Returns
Boolean — Whether or not the given file type is supported.
Constant Detail
AWD_FIELD_BADDRConstant
public static const AWD_FIELD_BADDR:uint = 23

AWD_FIELD_BOOLConstant 
public static const AWD_FIELD_BOOL:uint = 21

AWD_FIELD_BYTEARRAYConstant 
public static const AWD_FIELD_BYTEARRAY:uint = 32

AWD_FIELD_COLORConstant 
public static const AWD_FIELD_COLOR:uint = 22

AWD_FIELD_FLOAT32Constant 
public static const AWD_FIELD_FLOAT32:uint = 7

AWD_FIELD_FLOAT64Constant 
public static const AWD_FIELD_FLOAT64:uint = 8

AWD_FIELD_INT16Constant 
public static const AWD_FIELD_INT16:uint = 2

AWD_FIELD_INT32Constant 
public static const AWD_FIELD_INT32:uint = 3

AWD_FIELD_INT8Constant 
public static const AWD_FIELD_INT8:uint = 1

AWD_FIELD_MTX3x2Constant 
public static const AWD_FIELD_MTX3x2:uint = 44

AWD_FIELD_MTX3x3Constant 
public static const AWD_FIELD_MTX3x3:uint = 45

AWD_FIELD_MTX4x3Constant 
public static const AWD_FIELD_MTX4x3:uint = 46

AWD_FIELD_MTX4x4Constant 
public static const AWD_FIELD_MTX4x4:uint = 47

AWD_FIELD_STRINGConstant 
public static const AWD_FIELD_STRING:uint = 31

AWD_FIELD_UINT16Constant 
public static const AWD_FIELD_UINT16:uint = 5

AWD_FIELD_UINT32Constant 
public static const AWD_FIELD_UINT32:uint = 6

AWD_FIELD_UINT8Constant 
public static const AWD_FIELD_UINT8:uint = 4

AWD_FIELD_VECTOR2x1Constant 
public static const AWD_FIELD_VECTOR2x1:uint = 41

AWD_FIELD_VECTOR3x1Constant 
public static const AWD_FIELD_VECTOR3x1:uint = 42

AWD_FIELD_VECTOR4x1Constant 
public static const AWD_FIELD_VECTOR4x1:uint = 43

DEFLATEConstant 
public static const DEFLATE:uint = 1

LZMAConstant 
public static const LZMA:uint = 2

UNCOMPRESSEDConstant 
public static const UNCOMPRESSED:uint = 0