| Package | org.springextensions.actionscript.context.support.mxml |
| SVN browsing | MXMLObjectDefinition.as |
| Fisheye | MXMLObjectDefinition.as |
| Class | public class MXMLObjectDefinition |
| Implements | IApplicationDomainAware, mx.core.IMXMLObject |
| Subclasses | Interface |
MXML representation of an ObjectDefinition object. This non-visual component must be declared as
a child component of a MXMLApplicationContext component.
Describes an object that can populate an IObjectDefinition instance with properties defined in MXML.
Default MXML PropertychildContent
See also
Documentation reference: composing mxml based configuration metadata
| Property | Defined by | ||
|---|---|---|---|
| abstract : Boolean | MXMLObjectDefinition | ||
| applicationDomain : ApplicationDomain | MXMLObjectDefinition | ||
| autoWireMode : String
Defines the way an object will be autowired (configured).
| MXMLObjectDefinition | ||
| childContent : Array
Placeholder for all MXML child content of the current
ObjectDefinition
| MXMLObjectDefinition | ||
| className : String
The classname of the object that the current
ObjectDefinition describes. | MXMLObjectDefinition | ||
| clazz : Class
The
Class of the object that the current ObjectDefinition describes. | MXMLObjectDefinition | ||
| constructorArguments : Array
An array of arguments that will be passed to the constructor of the object.
| MXMLObjectDefinition | ||
| defaultedProperties : Dictionary [read-only]
A dictionary of property names that have not been explicitly set through MXML markup.
| MXMLObjectDefinition | ||
| definition : IObjectDefinition
[read-only]
The
IObjectDefinition that is populated by the current MXML ObjectDefinition
| MXMLObjectDefinition | ||
| dependsOn : Array | MXMLObjectDefinition | ||
| explicitProperties : Dictionary [read-only]
A dictionary of property names that have been explicitly set through MXML markup.
| MXMLObjectDefinition | ||
| factoryMethod : String
The name of method responsible for the creation of the object.
| MXMLObjectDefinition | ||
| factoryObject : MXMLObjectDefinition
The ObjectDefinition for the factory object responsible for the creation of the object.
| MXMLObjectDefinition | ||
| factoryObjectName : String
The name of the factory object responsible for the creation of the object.
| MXMLObjectDefinition | ||
| id : String
The unique id for the current
ObjectDefinition as defined in the MXML markup. | MXMLObjectDefinition | ||
| initMethod : String
The name of a method on the class defined by the className property or clazz property that will be called immediately after the object has been configured.
| MXMLObjectDefinition | ||
| isAutoWireCandidate : Boolean
True if this object can be used as a value used by the container when it autowires an object by type.
| MXMLObjectDefinition | ||
| isInitialized : Boolean [read-only]
| MXMLObjectDefinition | ||
isLazyInit : BooleanTrue if the object does not need to be eagerly pre-instantiated by the container. | MXMLObjectDefinition | ||
| isSingleton : Boolean
True if only one instance of this object needs to be created by the container, i.e.
| MXMLObjectDefinition | ||
| methodDefinitions : Dictionary [read-only]
A dictionary of
MethodInvocation objects
| MXMLObjectDefinition | ||
| methodInvocations : Array
An array of ObjectDefinitions describing the methods that need to be called after object creation.
| MXMLObjectDefinition | ||
| params : Dictionary [read-only]
A dictionary of
Param objects
| MXMLObjectDefinition | ||
| parentObject : MXMLObjectDefinition
If not null the specified ObjectDefinition will be used to populate the current ObjectDefinition
| MXMLObjectDefinition | ||
| primary : Boolean
True if this object needs to be used as the primary autowire candidate when the container is autowiring by type.
| MXMLObjectDefinition | ||
| properties : Object
An anonymous object whose property values will be injected into the created object, the property names on this object are the same as on the created object.
| MXMLObjectDefinition | ||
| propertyObjectDefinitions : Array [read-only]
An array of
Property objects that have been added to the current ObjectDefinition
| MXMLObjectDefinition | ||
| scope : String
Defines the scope of the object, the object is either a singleton or a prototype object.
| MXMLObjectDefinition | ||
| skipMetadata : Boolean | MXMLObjectDefinition | ||
| skipPostProcessors : Boolean | MXMLObjectDefinition | ||
| template : Template
If not null the specified Template will be used to populate the current ObjectDefinition
| MXMLObjectDefinition | ||
| Property | Defined by | ||
|---|---|---|---|
| _isInitialized : Boolean = false | MXMLObjectDefinition | ||
| Method | Defined by | ||
|---|---|---|---|
|
Creates a new
ObjectDefinition instance
| MXMLObjectDefinition | ||
|
addConstructorArg(arg:ConstructorArg):void
Adds the specified
ConstructorArg resolved value to the constructorArguments array. | MXMLObjectDefinition | ||
|
addProperty(property:Property):void
Adds the specified
Property to the properties dictionary and resolves its value by invoking resolveValue(). | MXMLObjectDefinition | ||
|
initializeComponent():void
After
FlexEvent.CREATION_COMPLETE has been dispatched the processChildContent() method is invoked. | MXMLObjectDefinition | ||
|
initialized(document:Object, id:String):void
| MXMLObjectDefinition | ||
|
parse():void
Parses the MXML object definition.
| MXMLObjectDefinition | ||
| Method | Defined by | ||
|---|---|---|---|
|
Adds the specified
Param to the params dictionary. | MXMLObjectDefinition | ||
|
getApplicationDomain():ApplicationDomain
| MXMLObjectDefinition | ||
|
initMXMLObjectDefinition():void
| MXMLObjectDefinition | ||
|
resolveValue(arg:Arg):*
Returns a
RuntimeObjectReference instance if the specified Arg has a ref property assigned, returns a Class instance
if the Arg has a type property of "class" and a string as value, returns a RuntimeObjectReference if the property value is a ObjectDefinition
and adds this instance to the propertyObjectDefinitions list, in all other cases it just returns the value of the specified Arg. | MXMLObjectDefinition | ||
| Constant | Defined by | ||
|---|---|---|---|
| ANON_OBJECT_PREFIX : String = "anonref_" [static]
Prefix added to
ObjectDefinitions without an explicit context id, this prefix is needed
by the MXMLUtils serializer
| MXMLObjectDefinition | ||
| abstract | property |
abstract:Boolean [read-write]Implementation
public function get abstract():Boolean
public function set abstract(value:Boolean):void
| applicationDomain | property |
applicationDomain:ApplicationDomain [read-write]Implementation
public function get applicationDomain():ApplicationDomain
public function set applicationDomain(value:ApplicationDomain):void
| autoWireMode | property |
autoWireMode:String [read-write]Defines the way an object will be autowired (configured). This can be the following values: no,byName,byType,constructor,autodetect
Implementation public function get autoWireMode():String
public function set autoWireMode(value:String):void
| childContent | property |
childContent:Array [read-write]
Placeholder for all MXML child content of the current ObjectDefinition
public function get childContent():Array
public function set childContent(value:Array):void
| className | property |
className:String [read-write]
The classname of the object that the current ObjectDefinition describes.
public function get className():String
public function set className(value:String):void
| clazz | property |
clazz:Class [read-write]
The Class of the object that the current ObjectDefinition describes.
public function get clazz():Class
public function set clazz(value:Class):void
| constructorArguments | property |
constructorArguments:Array [read-write]An array of arguments that will be passed to the constructor of the object.
Implementation public function get constructorArguments():Array
public function set constructorArguments(value:Array):void
| defaultedProperties | property |
defaultedProperties:Dictionary [read-only]
A dictionary of property names that have not been explicitly set through MXML markup.
When the current ObjectDefinition is configured by a Template or parent definition
only the properties present in this dictionary will be copied from the source definition.
public function get defaultedProperties():Dictionary
See also
| definition | property |
definition:IObjectDefinition [read-only]
The IObjectDefinition that is populated by the current MXML ObjectDefinition
public function get definition():IObjectDefinition
| dependsOn | property |
dependsOn:Array [read-write]Implementation
public function get dependsOn():Array
public function set dependsOn(value:Array):void
| explicitProperties | property |
explicitProperties:Dictionary [read-only]A dictionary of property names that have been explicitly set through MXML markup.
Implementation public function get explicitProperties():Dictionary
| factoryMethod | property |
factoryMethod:String [read-write]The name of method responsible for the creation of the object.
Implementation public function get factoryMethod():String
public function set factoryMethod(value:String):void
| factoryObject | property |
factoryObject:MXMLObjectDefinition [read-write]The ObjectDefinition for the factory object responsible for the creation of the object.
Implementation public function get factoryObject():MXMLObjectDefinition
public function set factoryObject(value:MXMLObjectDefinition):void
| factoryObjectName | property |
factoryObjectName:String [read-write]The name of the factory object responsible for the creation of the object.
Implementation public function get factoryObjectName():String
public function set factoryObjectName(value:String):void
| id | property |
id:String [read-write]
The unique id for the current ObjectDefinition as defined in the MXML markup. This id will
also be used to register as the name of the IObjectDefinition instance.
public function get id():String
public function set id(value:String):void
See also
| initMethod | property |
initMethod:String [read-write]The name of a method on the class defined by the className property or clazz property that will be called immediately after the object has been configured.
Implementation public function get initMethod():String
public function set initMethod(value:String):void
| isAutoWireCandidate | property |
isAutoWireCandidate:Boolean [read-write]True if this object can be used as a value used by the container when it autowires an object by type.
Implementation public function get isAutoWireCandidate():Boolean
public function set isAutoWireCandidate(value:Boolean):void
| _isInitialized | property |
protected var _isInitialized:Boolean = false
| isInitialized | property |
isInitialized:Boolean [read-only]Implementation
public function get isInitialized():Boolean
| isLazyInit | property |
isLazyInit:Boolean [read-write]
True if the object does not need to be eagerly pre-instantiated by the container. I.e. the object will be created after the first call to the getObject() method.
public function get isLazyInit():Boolean
public function set isLazyInit(value:Boolean):void
| isSingleton | property |
isSingleton:Boolean [read-write]True if only one instance of this object needs to be created by the container, i.e. every subsequent call to the getObject() method will return the same instance.
Implementation public function get isSingleton():Boolean
public function set isSingleton(value:Boolean):void
| methodDefinitions | property |
methodDefinitions:Dictionary [read-only]
A dictionary of MethodInvocation objects
public function get methodDefinitions():Dictionary
See also
| methodInvocations | property |
methodInvocations:Array [read-write]An array of ObjectDefinitions describing the methods that need to be called after object creation.
Implementation public function get methodInvocations():Array
public function set methodInvocations(value:Array):void
| params | property |
params:Dictionary [read-only]
A dictionary of Param objects
public function get params():Dictionary
See also
| parentObject | property |
parentObject:MXMLObjectDefinition [read-write]If not null the specified ObjectDefinition will be used to populate the current ObjectDefinition
Implementation public function get parentObject():MXMLObjectDefinition
public function set parentObject(value:MXMLObjectDefinition):void
| primary | property |
primary:Boolean [read-write]True if this object needs to be used as the primary autowire candidate when the container is autowiring by type. This means that if multiple objects are found of the same type, the object marked as 'primary' will become the autowire candidate.
Implementation public function get primary():Boolean
public function set primary(value:Boolean):void
| properties | property |
properties:Object [read-write]An anonymous object whose property values will be injected into the created object, the property names on this object are the same as on the created object.
Implementation public function get properties():Object
public function set properties(value:Object):void
| propertyObjectDefinitions | property |
propertyObjectDefinitions:Array [read-only]
An array of Property objects that have been added to the current ObjectDefinition
public function get propertyObjectDefinitions():Array
See also
| scope | property |
scope:String [read-write]Defines the scope of the object, the object is either a singleton or a prototype object.
Implementation public function get scope():String
public function set scope(value:String):void
| skipMetadata | property |
skipMetadata:Boolean [read-write]Implementation
public function get skipMetadata():Boolean
public function set skipMetadata(value:Boolean):void
| skipPostProcessors | property |
skipPostProcessors:Boolean [read-write]Implementation
public function get skipPostProcessors():Boolean
public function set skipPostProcessors(value:Boolean):void
| template | property |
template:Template [read-write]If not null the specified Template will be used to populate the current ObjectDefinition
Implementation public function get template():Template
public function set template(value:Template):void
| MXMLObjectDefinition | () | constructor |
public function MXMLObjectDefinition()
Creates a new ObjectDefinition instance
| addConstructorArg | () | method |
public function addConstructorArg(arg:ConstructorArg):void
Adds the specified ConstructorArg resolved value to the constructorArguments array.
arg:ConstructorArg — The specified ConstructorArg instance.
|
| addParam | () | method |
protected function addParam(param:Param):void
Adds the specified Param to the params dictionary.
param:Param — The specified Param instance.
|
| addProperty | () | method |
public function addProperty(property:Property):void
Adds the specified Property to the properties dictionary and resolves its value by invoking resolveValue().
property:Property — The specified Property instance.
|
| getApplicationDomain | () | method |
protected function getApplicationDomain():ApplicationDomain
Returns
ApplicationDomain |
| initializeComponent | () | method |
public function initializeComponent():void
After FlexEvent.CREATION_COMPLETE has been dispatched the processChildContent() method is invoked.
| initialized | () | method |
public function initialized(document:Object, id:String):voidParameters
document:Object |
|
id:String |
| initMXMLObjectDefinition | () | method |
protected function initMXMLObjectDefinition():void
| parse | () | method |
public function parse():voidParses the MXML object definition.
| resolveValue | () | method |
protected function resolveValue(arg:Arg):*
Returns a RuntimeObjectReference instance if the specified Arg has a ref property assigned, returns a Class instance
if the Arg has a type property of "class" and a string as value, returns a RuntimeObjectReference if the property value is a ObjectDefinition
and adds this instance to the propertyObjectDefinitions list, in all other cases it just returns the value of the specified Arg.
arg:Arg — The specified Arg
|
* — The actual value of the Arg
|
See also
| ANON_OBJECT_PREFIX | constant |
public static const ANON_OBJECT_PREFIX:String = "anonref_"
Prefix added to ObjectDefinitions without an explicit context id, this prefix is needed
by the MXMLUtils serializer
See also