Actionscript 3 - First Steps III

      FLASH 2005-10-19 23:1
//这一章不是很明白
In First Steps II we have seen, that package local functions can be defined. Now, nosy as i am, i'd really like to know, what exactly a package local function is. A new reflection function flash.util.describeType comes to rescue. It returns a xml object containing all the information available about a particular object.
package {
        import flash.util.trace;
        import flash.util.describeType;
        import flash.display.MovieClip;

        public var surname:String = "Mueller";

        public function willi(){
                trace("willi " + surname + " was here");

        }
        
        public class Test extends MovieClip {
                public function Test() {
                        trace("Test " + describeType(willi));
                }
        }
}



Take a look at the console to see all the information given. Now how great is that! :)

Cheers,
Ralf.
///////////////////////////////
因为是个人读书的笔记,所以没有进行翻译,只是对其中关键地方进行注释。如有错误欢迎指出。
原文转载自: www.helpqlodhelp.com/blog/
标签集:TAGS:
回复Comments() 点击Count()

回复Comments

{commenttime}{commentauthor}

{CommentUrl}
{commentcontent}