ValidateThis API Documentation

ValidateThis.util
Class LightWire

WEB-INF.cftags.component
        extended by ValidateThis.util.LightWire

public class LightWire
extends WEB-INF.cftags.component

I am the LightWire factory that creates all singleton and transient objects, injecting them with all of their necessary dependencies as defined in the configuration file.


Constructor Summary
init(any ConfigBean)
          I initialize the LightWire object factory
 
Method Summary
 boolean containsBean(string beanName)
          returns true if the BeanFactory contains a bean definition that matches the given name
private any createNewObject(string ObjectName, string ObjectType)
          I create a object
 any getBean(string ObjectName)
          I return a bean with all of its dependencies loaded
private string getDependentObjectList(string ObjectName)
          I return a comma delimited list of all of the dependencies that have not been created yet for an object - n-levels down
private any getObject(string ObjectName, string ObjectType)
          I return a LightWire scoped object (Singleton or Transient) with all of its dependencies loaded
 any getSingleton(string ObjectName)
          I return a LightWire scoped Singleton with all of its dependencies loaded
 any getTransient(string ObjectName)
          I return a transient object
 string lightwireGetAnnotations()
          I return the comma delimited list of beans to mixin based on variables
 void lightwireMixin(string ElementName, any ElementValue)
          I add the passed elements to the variables scope within this object
private any setterandMixinInject(string ObjectName, any Object)
          I handle
 
Methods inherited from class WEB-INF.cftags.component
 

Constructor Detail

init

public init(any ConfigBean)
I initialize the LightWire object factory.

Parameters:
ConfigBean - I am the initialized config bean.
Method Detail

containsBean

public boolean containsBean(string beanName)
returns true if the BeanFactory contains a bean definition that matches the given name

Parameters:
beanName - name of bean to look for

createNewObject

private any createNewObject(string ObjectName, string ObjectType)
I create a object.

Parameters:
ObjectName - I am the name of the object to create.
ObjectType - I am the type of object to create. Singleton or Transient.

getBean

public any getBean(string ObjectName)
I return a bean with all of its dependencies loaded.

Parameters:
ObjectName - I am the name of the object to generate.

getDependentObjectList

private string getDependentObjectList(string ObjectName)
I return a comma delimited list of all of the dependencies that have not been created yet for an object - n-levels down.

Parameters:
ObjectName - I am the name of the object to get the dependencies for.

getObject

private any getObject(string ObjectName, string ObjectType)
I return a LightWire scoped object (Singleton or Transient) with all of its dependencies loaded.

Parameters:
ObjectName - I am the name of the object to return.
ObjectType - I am the type of object to return (Singleton or Transient).

getSingleton

public any getSingleton(string ObjectName)
I return a LightWire scoped Singleton with all of its dependencies loaded.

Parameters:
ObjectName - I am the name of the object to generate.

getTransient

public any getTransient(string ObjectName)
I return a transient object.

Parameters:
ObjectName - I am the name of the object to create.

lightwireGetAnnotations

public string lightwireGetAnnotations()
I return the comma delimited list of beans to mixin based on variables.MixinObjectNameList if it was set in the init().


lightwireMixin

public void lightwireMixin(string ElementName, any ElementValue)
I add the passed elements to the variables scope within this object. I am mixed in by LightWire to support mixin injection of dependencies and properties.

Parameters:
ElementName - I am the name of the element to mix in.
ElementValue - I am the value of the element to mix in.

setterandMixinInject

private any setterandMixinInject(string ObjectName, any Object)
I handle.

Parameters:
ObjectName - I am the name of the object to inject dependencies into.
Object - I am the object to inject dependencies into.

ValidateThis API Documentation