You can use Object.setPropertyisEnumerable(propName).
flash.utils.describeType() might be another way. -- Mike Keesey On 2/15/07, Matt Garland <[EMAIL PROTECTED]> wrote:
Hi, I'm converting some AS2 code to AS3. The code manipulates several big, complicated data containers to produce an animation. In AS2, the data container was a vanilla object. In AS3, for performance gains, I turned these containers into several classes. The problem is, at various points, I am transferring all the values from one container to another. The variables have the same names, but the data containers are different. For instance, in the first container, there are points. In the second container,the corresponding points are actually a subclass of points, one with more properties. Before, I could just lay the two containers side by side, then use recursive for...in loops to transfer all the values. But for...in loops don't work for class instances in AS3. Class info is baked into the compiled class, and no longer stored in a memory- and cycle- wasting object hash. What to do? Anyway I can access the compiled class info (looping through a class's properties), or is that contra the entire point of AS3? Save me from writing a long, convoluted one-off conversion function. Thanks Matt _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
_______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com