| Package | org.springextensions.actionscript.ioc.factory.xml.parser.support |
| SVN browsing | XMLObjectDefinitionsParser.as |
| Fisheye | XMLObjectDefinitionsParser.as |
| Class | public class XMLObjectDefinitionsParser |
| Subclasses | FlexXMLObjectDefinitionsParser |
| Property | Defined by | ||
|---|---|---|---|
| applicationContext : IApplicationContext
The objectFactory currently in use
| XMLObjectDefinitionsParser | ||
| nodeParsers : Array [read-only]
Returns all registered implementations of
INodeParser. | XMLObjectDefinitionsParser | ||
| Method | Defined by | ||
|---|---|---|---|
|
XMLObjectDefinitionsParser(applicationContext:IApplicationContext = null)
Constructs a new
XmlObjectDefinitionsParser. | XMLObjectDefinitionsParser | ||
|
addNamespaceHandler(handler:INamespaceHandler):void
Adds a namespace handler.
| XMLObjectDefinitionsParser | ||
|
addNodeParser(parser:INodeParser):void
Adds a NodeParser to the parser.
| XMLObjectDefinitionsParser | ||
|
addPreprocessor(preprocessor:IXMLObjectDefinitionsPreprocessor):void
Adds a preprocessor to the parser.
| XMLObjectDefinitionsParser | ||
|
generateObjectName(definition:IObjectDefinition):String
Generates an object name for the given object definition.
| XMLObjectDefinitionsParser | ||
|
parse(xml:XML):IApplicationContext
Parses all object definitions and returns the objectFactory that contains
the parsed results.
| XMLObjectDefinitionsParser | ||
|
parseAndRegisterObjectDefinition(node:XML):String
Parses and registers an object definition.
| XMLObjectDefinitionsParser | ||
|
parseNode(node:XML):void
| XMLObjectDefinitionsParser | ||
|
Parses the given object definition node into an implementation of IObjectDefinition.
| XMLObjectDefinitionsParser | ||
|
parseProperty(node:XML):Object
Will parse the given property node.
| XMLObjectDefinitionsParser | ||
|
parsePropertyValue(node:XML):Object
Will parse the given property value using the node parsers.
| XMLObjectDefinitionsParser | ||
|
registerObjectDefinition(objectName:String, objectDefinition:IObjectDefinition):void
Registers an object definition in the internal object factory.
| XMLObjectDefinitionsParser | ||
| Method | Defined by | ||
|---|---|---|---|
|
isDefaultNamespace(qname:QName):Boolean
| XMLObjectDefinitionsParser | ||
|
parseAttributes(objectDefinition:IObjectDefinition, xml:XML):void
Parses the attributes of an object node into an object definition.
| XMLObjectDefinitionsParser | ||
|
parseConstructorArguments(objectDefinition:IObjectDefinition, xml:XML):void
Will retrieve the constructor arguments and parses them as if they were property nodes.
| XMLObjectDefinitionsParser | ||
|
parseCustomNode(node:XML):void
| XMLObjectDefinitionsParser | ||
|
parseDefaultNode(node:XML):void
| XMLObjectDefinitionsParser | ||
|
parseMethodInvocation(node:XML):MethodInvocation
| XMLObjectDefinitionsParser | ||
|
parseMethodInvocations(objectDefinition:IObjectDefinition, xml:XML):void
Parses the method invocations of the given definition.
| XMLObjectDefinitionsParser | ||
|
parseObjectDefinitions(xml:XML):void
| XMLObjectDefinitionsParser | ||
|
parseProperties(objectDefinition:IObjectDefinition, xml:XML):void
Parses the properties of the given definition.
| XMLObjectDefinitionsParser | ||
|
preProcessXML(xml:XML):void
Pre process the xml data before parsing.
| XMLObjectDefinitionsParser | ||
|
processObjectDefinition(node:XML):void
Process the given node as an object definition.
| XMLObjectDefinitionsParser | ||
| Constant | Defined by | ||
|---|---|---|---|
| ABSTRACT_ATTRIBUTE : String = "abstract" [static]
| XMLObjectDefinitionsParser | ||
| ARRAY_COLLECTION_ELEMENT : String = "array-collection" [static] Constant value 'array-collection'
| XMLObjectDefinitionsParser | ||
| ARRAY_ELEMENT : String = "array" [static] Constant value 'array'
| XMLObjectDefinitionsParser | ||
| AUTOWIRE_CANDIDATE_ATTRIBUTE : String = "autowire-candidate" [static]
| XMLObjectDefinitionsParser | ||
| AUTOWIRE_MODE_ATTRIBUTE : String = "autowire" [static]
| XMLObjectDefinitionsParser | ||
| AUTOWIRE_PRIMARY_CANDIDATE_ATTRIBUTE : String = "primary" [static]
| XMLObjectDefinitionsParser | ||
| CLASS_ATTRIBUTE : String = "class" [static]
| XMLObjectDefinitionsParser | ||
| CONSTRUCTOR_ARG_ELEMENT : String = "constructor-arg" [static] Constant value 'constructor-arg'
| XMLObjectDefinitionsParser | ||
| DEPENDENCY_CHECK_ATTRIBUTE : String = "dependency-check" [static]
| XMLObjectDefinitionsParser | ||
| DEPENDS_ON_ATTRIBUTE : String = "depends-on" [static]
| XMLObjectDefinitionsParser | ||
| DESTROY_METHOD_ATTRIBUTE : String = "destroy-method" [static]
| XMLObjectDefinitionsParser | ||
| DICTIONARY_ELEMENT : String = "dictionary" [static] Constant value 'dictionary'
| XMLObjectDefinitionsParser | ||
| ENTRY_ELEMENENT : String = "entry" [static] Constant value 'entry'
| XMLObjectDefinitionsParser | ||
| FACTORY_METHOD_ATTRIBUTE : String = "factory-method" [static]
| XMLObjectDefinitionsParser | ||
| FACTORY_OBJECT_ATTRIBUTE : String = "factory-object" [static]
| XMLObjectDefinitionsParser | ||
| ID_ATTRIBUTE : String = "id" [static]
| XMLObjectDefinitionsParser | ||
| INIT_METHOD_ATTRIBUTE : String = "init-method" [static]
| XMLObjectDefinitionsParser | ||
| KEY_ATTRIBUTE : String = "key" [static]
| XMLObjectDefinitionsParser | ||
| KEY_ELEMENT : String = "key" [static] Constant value 'key'
| XMLObjectDefinitionsParser | ||
| LAZY_INIT_ATTRIBUTE : String = "lazy-init" [static]
| XMLObjectDefinitionsParser | ||
| LIST_ELEMENT : String = "list" [static] Constant value 'list'
| XMLObjectDefinitionsParser | ||
| MAP_ELEMENT : String = "map" [static] Constant value 'map'
| XMLObjectDefinitionsParser | ||
| METHOD_INVOCATION : String = "method-invocation" [static] Constant value 'method-invocation'
| XMLObjectDefinitionsParser | ||
| NULL_ELEMENT : String = "null" [static] Constant value 'null'
| XMLObjectDefinitionsParser | ||
| OBJECT_ELEMENT : String = "object" [static] Constant value 'object'
| XMLObjectDefinitionsParser | ||
| OBJECT_NAME_DELIMITERS : String = ",; " [static]
| XMLObjectDefinitionsParser | ||
| PROPERTY_ELEMENT : String = "property" [static] Constant value 'property'
| XMLObjectDefinitionsParser | ||
| REF_ATTRIBUTE : String = "ref" [static]
| XMLObjectDefinitionsParser | ||
| REF_ELEMENT : String = "ref" [static] Constant value 'ref'
| XMLObjectDefinitionsParser | ||
| SCOPE_ATTRIBUTE : String = "scope" [static]
| XMLObjectDefinitionsParser | ||
| SKIP_METADATA : String = "skip-metadata" [static] Constant value 'method-invocation'
| XMLObjectDefinitionsParser | ||
| SKIP_POSTPROCESSORS : String = "skip-postprocessors" [static] Constant value 'skip-postprocessors'
| XMLObjectDefinitionsParser | ||
| TEMPLATE_ELEMENT : String = "template" [static] Constant value 'template'
| XMLObjectDefinitionsParser | ||
| VALUE_ATTRIBUTE : String = "value" [static]
| XMLObjectDefinitionsParser | ||
| VALUE_ELEMENT : String = "value" [static] Constant value 'value'
| XMLObjectDefinitionsParser | ||
| VECTOR_ELEMENT : String = "vector" [static] Constant value 'vector'
| XMLObjectDefinitionsParser | ||
| applicationContext | property |
applicationContext:IApplicationContext [read-write]The objectFactory currently in use
The default value is an instance of XMLObjectFactory.
public function get applicationContext():IApplicationContext
public function set applicationContext(value:IApplicationContext):void
See also
| nodeParsers | property |
nodeParsers:Array [read-only]
Returns all registered implementations of INodeParser. Node parsers can
be added using the addNodeParser method.
public function get nodeParsers():Array
See also
| XMLObjectDefinitionsParser | () | constructor |
public function XMLObjectDefinitionsParser(applicationContext:IApplicationContext = null)
Constructs a new XmlObjectDefinitionsParser.
An optional objectFactory can be passed to store the definitions. If no
container is passed then a new instance will be created of type XMLObjectFactory.
applicationContext:IApplicationContext (default = null) — the objectFactory where the object definitions will be stored
|
See also
| addNamespaceHandler | () | method |
public function addNamespaceHandler(handler:INamespaceHandler):voidAdds a namespace handler.
Parametershandler:INamespaceHandler |
| addNodeParser | () | method |
public function addNodeParser(parser:INodeParser):voidAdds a NodeParser to the parser.
Parametersparser:INodeParser — The implementation of INodeParser that will be added
|
| addPreprocessor | () | method |
public function addPreprocessor(preprocessor:IXMLObjectDefinitionsPreprocessor):voidAdds a preprocessor to the parser.
Parameterspreprocessor:IXMLObjectDefinitionsPreprocessor — The implementation of IXMLObjectDefinitionsPreprocessor that will be added
|
| generateObjectName | () | method |
public function generateObjectName(definition:IObjectDefinition):StringGenerates an object name for the given object definition.
Parametersdefinition:IObjectDefinition |
String |
| isDefaultNamespace | () | method |
protected function isDefaultNamespace(qname:QName):BooleanParameters
qname:QName |
Boolean |
| parse | () | method |
public function parse(xml:XML):IApplicationContextParses all object definitions and returns the objectFactory that contains the parsed results.
Parametersxml:XML — the xml object with the object definitions
|
IApplicationContext —
the objectFactory with the parsed object definitions
|
| parseAndRegisterObjectDefinition | () | method |
public function parseAndRegisterObjectDefinition(node:XML):StringParses and registers an object definition.
Parametersnode:XML — The xml node to create an object definition from.
|
String |
| parseAttributes | () | method |
protected function parseAttributes(objectDefinition:IObjectDefinition, xml:XML):voidParses the attributes of an object node into an object definition.
ParametersobjectDefinition:IObjectDefinition |
|
xml:XML |
| parseConstructorArguments | () | method |
protected function parseConstructorArguments(objectDefinition:IObjectDefinition, xml:XML):voidWill retrieve the constructor arguments and parses them as if they were property nodes.
ParametersobjectDefinition:IObjectDefinition — The xml to check for nodes
|
|
xml:XML |
See also
| parseCustomNode | () | method |
protected function parseCustomNode(node:XML):voidParameters
node:XML |
| parseDefaultNode | () | method |
protected function parseDefaultNode(node:XML):voidParameters
node:XML |
| parseMethodInvocation | () | method |
protected function parseMethodInvocation(node:XML):MethodInvocationParameters
node:XML |
MethodInvocation |
| parseMethodInvocations | () | method |
protected function parseMethodInvocations(objectDefinition:IObjectDefinition, xml:XML):voidParses the method invocations of the given definition.
ParametersobjectDefinition:IObjectDefinition |
|
xml:XML |
| parseNode | () | method |
public function parseNode(node:XML):voidParameters
node:XML |
| parseObjectDefinition | () | method |
public function parseObjectDefinition(xml:XML, objectDefinition:IObjectDefinition = null):IObjectDefinitionParses the given object definition node into an implementation of IObjectDefinition.
Parametersxml:XML — The object definition node
|
|
objectDefinition:IObjectDefinition (default = null) |
IObjectDefinition —
an implementation of IObjectDefinition
|
| parseObjectDefinitions | () | method |
protected function parseObjectDefinitions(xml:XML):voidParameters
xml:XML |
| parseProperties | () | method |
protected function parseProperties(objectDefinition:IObjectDefinition, xml:XML):voidParses the properties of the given definition.
ParametersobjectDefinition:IObjectDefinition |
|
xml:XML |
| parseProperty | () | method |
public function parseProperty(node:XML):ObjectWill parse the given property node. If the given property does not contain a value attribute, the first childNode will be used as value else the value of the property will be parsed and returned using the parsePropertyValue method.
Parametersnode:XML — The property node to be parsed
|
Object — the value of the parsed node
|
See also
| parsePropertyValue | () | method |
public function parsePropertyValue(node:XML):ObjectWill parse the given property value using the node parsers.
Will loop through the node parsers in the order that they have been added. The first parser able to parse the node is used to retrieve the value. Parametersnode:XML — The property value node to be parsed
|
Object — the value of the node after parsing
|
| preProcessXML | () | method |
protected function preProcessXML(xml:XML):voidPre process the xml data before parsing.
Parametersxml:XML |
| processObjectDefinition | () | method |
protected function processObjectDefinition(node:XML):voidProcess the given node as an object definition.
Parametersnode:XML |
| registerObjectDefinition | () | method |
public function registerObjectDefinition(objectName:String, objectDefinition:IObjectDefinition):voidRegisters an object definition in the internal object factory.
ParametersobjectName:String — the name of the object
|
|
objectDefinition:IObjectDefinition — the object definition
|
| ABSTRACT_ATTRIBUTE | constant |
public static const ABSTRACT_ATTRIBUTE:String = "abstract"
| ARRAY_COLLECTION_ELEMENT | constant |
public static const ARRAY_COLLECTION_ELEMENT:String = "array-collection"Constant value 'array-collection'
| ARRAY_ELEMENT | constant |
public static const ARRAY_ELEMENT:String = "array"Constant value 'array'
| AUTOWIRE_CANDIDATE_ATTRIBUTE | constant |
public static const AUTOWIRE_CANDIDATE_ATTRIBUTE:String = "autowire-candidate"
| AUTOWIRE_MODE_ATTRIBUTE | constant |
public static const AUTOWIRE_MODE_ATTRIBUTE:String = "autowire"
| AUTOWIRE_PRIMARY_CANDIDATE_ATTRIBUTE | constant |
public static const AUTOWIRE_PRIMARY_CANDIDATE_ATTRIBUTE:String = "primary"
| CLASS_ATTRIBUTE | constant |
public static const CLASS_ATTRIBUTE:String = "class"
| CONSTRUCTOR_ARG_ELEMENT | constant |
public static const CONSTRUCTOR_ARG_ELEMENT:String = "constructor-arg"Constant value 'constructor-arg'
| DEPENDENCY_CHECK_ATTRIBUTE | constant |
public static const DEPENDENCY_CHECK_ATTRIBUTE:String = "dependency-check"
| DEPENDS_ON_ATTRIBUTE | constant |
public static const DEPENDS_ON_ATTRIBUTE:String = "depends-on"
| DESTROY_METHOD_ATTRIBUTE | constant |
public static const DESTROY_METHOD_ATTRIBUTE:String = "destroy-method"
| DICTIONARY_ELEMENT | constant |
public static const DICTIONARY_ELEMENT:String = "dictionary"Constant value 'dictionary'
| ENTRY_ELEMENENT | constant |
public static const ENTRY_ELEMENENT:String = "entry"Constant value 'entry'
| FACTORY_METHOD_ATTRIBUTE | constant |
public static const FACTORY_METHOD_ATTRIBUTE:String = "factory-method"
| FACTORY_OBJECT_ATTRIBUTE | constant |
public static const FACTORY_OBJECT_ATTRIBUTE:String = "factory-object"
| ID_ATTRIBUTE | constant |
public static const ID_ATTRIBUTE:String = "id"
| INIT_METHOD_ATTRIBUTE | constant |
public static const INIT_METHOD_ATTRIBUTE:String = "init-method"
| KEY_ATTRIBUTE | constant |
public static const KEY_ATTRIBUTE:String = "key"
| KEY_ELEMENT | constant |
public static const KEY_ELEMENT:String = "key"Constant value 'key'
| LAZY_INIT_ATTRIBUTE | constant |
public static const LAZY_INIT_ATTRIBUTE:String = "lazy-init"
| LIST_ELEMENT | constant |
public static const LIST_ELEMENT:String = "list"Constant value 'list'
| MAP_ELEMENT | constant |
public static const MAP_ELEMENT:String = "map"Constant value 'map'
| METHOD_INVOCATION | constant |
public static const METHOD_INVOCATION:String = "method-invocation"Constant value 'method-invocation'
| NULL_ELEMENT | constant |
public static const NULL_ELEMENT:String = "null"Constant value 'null'
| OBJECT_ELEMENT | constant |
public static const OBJECT_ELEMENT:String = "object"Constant value 'object'
| OBJECT_NAME_DELIMITERS | constant |
public static const OBJECT_NAME_DELIMITERS:String = ",; "
| PROPERTY_ELEMENT | constant |
public static const PROPERTY_ELEMENT:String = "property"Constant value 'property'
| REF_ATTRIBUTE | constant |
public static const REF_ATTRIBUTE:String = "ref"
| REF_ELEMENT | constant |
public static const REF_ELEMENT:String = "ref"Constant value 'ref'
| SCOPE_ATTRIBUTE | constant |
public static const SCOPE_ATTRIBUTE:String = "scope"
| SKIP_METADATA | constant |
public static const SKIP_METADATA:String = "skip-metadata"Constant value 'method-invocation'
| SKIP_POSTPROCESSORS | constant |
public static const SKIP_POSTPROCESSORS:String = "skip-postprocessors"Constant value 'skip-postprocessors'
| TEMPLATE_ELEMENT | constant |
public static const TEMPLATE_ELEMENT:String = "template"Constant value 'template'
| VALUE_ATTRIBUTE | constant |
public static const VALUE_ATTRIBUTE:String = "value"
| VALUE_ELEMENT | constant |
public static const VALUE_ELEMENT:String = "value"Constant value 'value'
| VECTOR_ELEMENT | constant |
public static const VECTOR_ELEMENT:String = "vector"Constant value 'vector'