ColdBox Platform - WireBox Version 1.0.0

wirebox.system.ioc.config
Class Mapping

WEB-INF.cftags.component
        extended by wirebox.system.ioc.config.Mapping

public class Mapping
extends WEB-INF.cftags.component

I model a WireBox object mapping in all of its glory and splendour


Constructor Summary
init(any name)
          Constructor
 
Method Summary
 any addDIConstructorArgument([any name], [any ref], [any dsl], [any value], [any javaCast], [any required='true'])
          Add a new constructor argument to this mapping
 any addDIMethodArgument([any name], [any ref], [any dsl], [any value], [any javaCast], [any required='true'])
          Add a new method argument to this mapping
 any addDIProperty(any name, [any ref], [any dsl], [any value], [any javaCast], [any scope='variables'])
          Add a new cfproperty definition
 any addDISetter(any name, [any ref], [any dsl], [any value], [any javaCast])
          Add a new DI setter definition
 any addProviderMethod(any method, any mapping)
          Add a new provider method to this mapping
 any<Array> getAlias()
          Get the mapping aliases array
 any<struct> getCacheProperties()
          Get this mappings cache properties structure
 any getConstructor()
          Get the name of the constructor method
 any<array> getDIConstructorArguments()
          Get all the constructor argument definitions array
private any<wirebox.system.ioc.config.structure> getDIDefinition()
          Get a new DI definition structure
 any<array> getDIMethodArguments()
          Get all the method argument definitions array
 any<Array> getDIProperties()
          Get all the DI property definitions array
 any<array> getDISetters()
          Get all the DI setter definitions array
 any getDSL()
          Get the construction DSL
 any<struct> getMemento()
          Get the instance memento structure
 any getMetadata()
          Get the internal mapping metadata of the object
 any getMethod()
          Get the method that this mapping needs to execute from a mapping factory
 any getName()
          Get the mapping name
 any<array> getOnDIComplete()
          Get all the DI complete methods array
 any getPath()
          Get the path to this mapping
 any<Array> getProviderMethods()
          Get the discovered provider methods array
 any getScope()
          Get the visibility scope
 any getType()
          Get the mapping type
 any getValue()
          Get the mapping value (if any)
 any<Boolean> isAutoInit()
          Using auto init of mapping target or not as boolean
 any<Boolean> isAutowire()
          Flag describing if you are using autowire or not as Boolean
 any<boolean> isDSL()
          Does this mapping have a DSL construction element or not as Boolean
 any<Boolean> isDiscovered()
          Checks if this mapping has already been processed or not
 any<Boolean> isEagerInit()
          Is this mapping eager initialized or not as Boolean
 any process(any binder, any injector, [any metadata])
          Process a mapping for metadata discovery and more
private void processDIMetadata(any binder, any metadata, [any dependencies='[runtime expression]'])
          Process methods/properties for dependency injection
 any processMemento(any<struct> memento)
          Process a mapping memento
 any setAlias(any<Array> alias)
          Set the mapping aliases
 any setAutoInit(any autoInit)
          Set autoInit property
 any setAutowire(any<Boolean> autowire)
          Set autowire property
 any setCacheProperties(any key, [any timeout=''], [any lastAccessTimeout=''], [any provider='default'])
          Set the cache properties for this mapping (Needs cachebox integration)
 any setConstructor(any constructor)
          Override the name of the constructor method
 any setDSL(any dsl)
          Set the construction DSL
 any setDiscovered()
          Flag this mapping as discovered
 any setEagerInit(any eagerInit)
          Set the eager init flag
 any setMetadata(any metadata)
          Set the mappings CFC target metadata
 any setMethod(any method)
          Set the method used for getting this mapping from a factory
 any setName(string name)
          Name the mapping
 any setOnDIComplete(any DIComplete)
          Set the DI Complete method array
 any setPath(any path)
          Set the path to this mapping
 any setScope(any scope)
          Set the visibility scope
 any setType(any type)
          Set the mapping type
 any setValue(any value)
          Set the mapping value
private any<Boolean> stopClassRecursion(any classname, any binder)
          Should we stop recursion or not due to class name found: Boolean
 
Methods inherited from class WEB-INF.cftags.component
 

Constructor Detail

init

public init(any name)
Constructor

Parameters:
name - The mapping name
Method Detail

addDIConstructorArgument

public any addDIConstructorArgument([any name], [any ref], [any dsl], [any value], [any javaCast], [any required='true'])
Add a new constructor argument to this mapping

Parameters:
name - The name of the constructor argument (Not used for: JAVA,WEBSERVICE)
ref - The reference mapping id this constructor argument maps to
dsl - The construction dsl this argument references. If used, the name value must be used.
value - The explicit value of the constructor argument, if passed.
javaCast - The type of javaCast() to use on the value of the argument. Only used if using dsl or ref arguments
required - If the argument is required or not, by default we assume required DI arguments.

addDIMethodArgument

public any addDIMethodArgument([any name], [any ref], [any dsl], [any value], [any javaCast], [any required='true'])
Add a new method argument to this mapping

Parameters:
name - The name of the method argument (Not used for: JAVA,WEBSERVICE)
ref - The reference mapping id this method argument maps to
dsl - The construction dsl this argument references. If used, the name value must be used.
value - The explicit value of the method argument, if passed.
javaCast - The type of javaCast() to use on the value of the argument. Only used if using dsl or ref arguments
required - If the argument is required or not, by default we assume required DI arguments.

addDIProperty

public any addDIProperty(any name, [any ref], [any dsl], [any value], [any javaCast], [any scope='variables'])
Add a new cfproperty definition

Parameters:
name - The name of the cfproperty to inject
ref - The reference mapping id this property maps to
dsl - The construction dsl this property references. If used, the name value must be used.
value - The value of the property, if passed.
javaCast - The type of javaCast() to use on the value of the property. Only used if using dsl or ref arguments
scope - The scope in the CFC to inject the property to. By default it will inject it to the variables scope

addDISetter

public any addDISetter(any name, [any ref], [any dsl], [any value], [any javaCast])
Add a new DI setter definition

Parameters:
name - The name of the setter method.
ref - The reference mapping id this setter argument maps to
dsl - The construction dsl this argument references. If used, the name value must be used.
value - The value of the setter argument, if passed.
javaCast - The type of javaCast() to use on the value of the argument. Only used if using dsl or ref arguments

addProviderMethod

public any addProviderMethod(any method, any mapping)
Add a new provider method to this mapping

Parameters:
method - The provided method to override as a provider
mapping - The mapping to provide via the selected method

getAlias

public any<Array> getAlias()
Get the mapping aliases array


getCacheProperties

public any<struct> getCacheProperties()
Get this mappings cache properties structure


getConstructor

public any getConstructor()
Get the name of the constructor method


getDIConstructorArguments

public any<array> getDIConstructorArguments()
Get all the constructor argument definitions array


getDIDefinition

private any<wirebox.system.ioc.config.structure> getDIDefinition()
Get a new DI definition structure


getDIMethodArguments

public any<array> getDIMethodArguments()
Get all the method argument definitions array


getDIProperties

public any<Array> getDIProperties()
Get all the DI property definitions array


getDISetters

public any<array> getDISetters()
Get all the DI setter definitions array


getDSL

public any getDSL()
Get the construction DSL


getMemento

public any<struct> getMemento()
Get the instance memento structure


getMetadata

public any getMetadata()
Get the internal mapping metadata of the object


getMethod

public any getMethod()
Get the method that this mapping needs to execute from a mapping factory


getName

public any getName()
Get the mapping name


getOnDIComplete

public any<array> getOnDIComplete()
Get all the DI complete methods array


getPath

public any getPath()
Get the path to this mapping


getProviderMethods

public any<Array> getProviderMethods()
Get the discovered provider methods array


getScope

public any getScope()
Get the visibility scope


getType

public any getType()
Get the mapping type


getValue

public any getValue()
Get the mapping value (if any)


isAutoInit

public any<Boolean> isAutoInit()
Using auto init of mapping target or not as boolean


isAutowire

public any<Boolean> isAutowire()
Flag describing if you are using autowire or not as Boolean


isDSL

public any<boolean> isDSL()
Does this mapping have a DSL construction element or not as Boolean


isDiscovered

public any<Boolean> isDiscovered()
Checks if this mapping has already been processed or not


isEagerInit

public any<Boolean> isEagerInit()
Is this mapping eager initialized or not as Boolean


process

public any process(any binder, any injector, [any metadata])
Process a mapping for metadata discovery and more

Parameters:
binder - The binder requesting the processing
injector - The calling injector processing the mappping
metadata - The metadata of an a-la-carte processing, use instead of retrieveing again

processDIMetadata

private void processDIMetadata(any binder, any metadata, [any dependencies='[runtime expression]'])
Process methods/properties for dependency injection

Parameters:
binder - The binder requesting the processing
metadata - The metadata to process
dependencies - The dependencies structure

processMemento

public any processMemento(any<struct> memento)
Process a mapping memento

Parameters:
memento - The data memento to process

setAlias

public any setAlias(any<Array> alias)
Set the mapping aliases

Parameters:
alias

setAutoInit

public any setAutoInit(any autoInit)
Set autoInit property

Parameters:
autoInit

setAutowire

public any setAutowire(any<Boolean> autowire)
Set autowire property

Parameters:
autowire

setCacheProperties

public any setCacheProperties(any key, [any timeout=''], [any lastAccessTimeout=''], [any provider='default'])
Set the cache properties for this mapping (Needs cachebox integration)

Parameters:
key - Cache key to use
timeout - Object Timeout
lastAccessTimeout - Object Last Access Timeout
provider - The Cache Provider to use

setConstructor

public any setConstructor(any constructor)
Override the name of the constructor method

Parameters:
constructor

setDSL

public any setDSL(any dsl)
Set the construction DSL

Parameters:
dsl

setDiscovered

public any setDiscovered()
Flag this mapping as discovered


setEagerInit

public any setEagerInit(any eagerInit)
Set the eager init flag

Parameters:
eagerInit - Set the eager init flag

setMetadata

public any setMetadata(any metadata)
Set the mappings CFC target metadata

Parameters:
metadata - Target CFC metadata

setMethod

public any setMethod(any method)
Set the method used for getting this mapping from a factory

Parameters:
method

setName

public any setName(string name)
Name the mapping

Parameters:
name

setOnDIComplete

public any setOnDIComplete(any DIComplete)
Set the DI Complete method array

Parameters:
DIComplete - The method array to set

setPath

public any setPath(any path)
Set the path to this mapping

Parameters:
path

setScope

public any setScope(any scope)
Set the visibility scope

Parameters:
scope

setType

public any setType(any type)
Set the mapping type

Parameters:
type

setValue

public any setValue(any value)
Set the mapping value

Parameters:
value

stopClassRecursion

private any<Boolean> stopClassRecursion(any classname, any binder)
Should we stop recursion or not due to class name found: Boolean

Parameters:
classname - The class name to check
binder - The binder requesting the processing

ColdBox Platform - WireBox Version 1.0.0