Code, Know Thyself: Using ActionScript Metadata

Ever wondered how FlexBuilder knows that contains DataGrid tags or that child tags of a VBox belong to its children array? Maybe you would like other Flex developers working with components you've developed to see particular properties organised into categories in the properties panel, or allow them to annotate their own classes to work with a runtime framework you're developing. All this and more can be achieved using metadata.

  • Difficulty: Experienced
  • Prerequisites: Some Flex development experience.
  • Session Track: Flex,RIA,Frameworks

Session Detail

With ActionScript 3 Adobe has introduced a powerful, extensible metadata capability to the language, allowing you to annotate your classes, properties and methods with additional information accessible to FlexBuilder, the compiler and runtime code. Understanding how metadata is used by the SDK and how to use it in your own code is one of the keys to becoming a "power" Flex developer.

In this session Robin will show you how to add metadata to your classes for code type-ahead and introspection support in Flex Builder, making your code easier to reuse. Robin will also show you how metadata can be included in compiled byte code, allowing runtime retrieval of metadata properties through the reflection API.

Speakers

Robin Hilliard (Sydney, Australia)

Robin Hilliard is founder and CEO of RocketBoots, a business community of independent RIA experts. More...