Created
November 6, 2012 10:42
-
-
Save amowu/4023972 to your computer and use it in GitHub Desktop.
Looping over properties of a Class (property enumeration)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Get an XML description of this class | |
//and return the variable types as XMLList with e4x | |
var varList:XMLList = flash.utils.describeType(VO)..variable; | |
for(var i:int; i < varList.length(); i++){ | |
//Show the name and the value | |
trace(varList[i].@name+':'+ VO[varList[i].@name]); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment