Follow Flex After Dark on Twitter

Object Oriented MXML Components

MXML are just a different way of defining ActionScript classes. Thus, an MXML Component can also make use of ActionScript's Object Orientation.

Inheritance

Extending another component...

<mynamespace:MyComponent ...
   xmlns:mynamespace="my.package.*"
>
   ...
</mynamespace:MyCompontent>

Implements (Interfaces)

An MXML component can also declare itself as implementing one or more interfaces. The implements attribute is used for this.

<mynamespace:MyComponent ...
   implements="my.package.MyInterface"
   xmlns:mynamespace="my.package.*"
>
   ...
</mynamespace:MyCompontent>

Multiple interfaces may be listed as a comma-delimeted list.

Related Links:

Related Docs
  • Object-Oriented ActionScript ActionScript is a full-featured Object-Oriented language with support for classes, interfaces, encapsulation, polymorphism, and inheritance.
Recent Docs
Random Docs
  • ActionScript Dynamic Objects Dynamic objects in ActionScript can be created with arbitrary properties and functions at run-time.
  • Flex Validators Flex Validators are used for validating user-input data.
  • Flex HTTP Service Flex provides an HTTP Service in its RPC (Remoting) package for standard HTTP operations.
  • Flex Common Controls Overview of common Flex controls, including: Button, ComboBox, List, and TextArea.
  • MXML Language Overview of the MXML programming language used by Flex.