ColdBox Platform Version 2.6.4

coldbox.system.plugins
Class IOC

WEB-INF.cftags.component
        extended by coldbox.system.FrameworkSupertype
            extended by coldbox.system.Plugin
                extended by coldbox.system.plugins.IOC

public class IOC
extends Plugin

An Inversion Of Control plugin that interfaces with major ColdFusion IoC/DI frameworks such as ColdSpring and LightWire


Constructor Summary
init(any controller)
          Constructor
 
Method Summary
 void configure()
          Configure or Re-Configure the IoC Plugin
private any createColdspring()
          Creates the coldspring factory and configures it
private any createLightwire()
          Creates the lightwire factory and configures it
private any createLightwireConfigBean()
          Creates the lightwire config bean
 any getBean(string beanName)
          Get a Bean from the loaded object factory
 string getCOLDSPRING_FACTORY()
          Get COLDSPRING_FACTORY
 string getExpandedIOCDefinitionFile()
          Get the full expanded path of the configuration file, only used for coldspring
 string getIOCDefinitionFile()
          Get the definition file configured for this plugin
 string getIOCFramework()
          Gets the IoC Framework string used: lightwire or coldspring
 any getIoCFactory()
          Returns the IoC Factory in use
 string getLIGHTWIRE_FACTORY()
          Get LIGHTWIRE_FACTORY
 void reloadDefinitionFile()
          Reloads the IoC factory with the Definition File or Object
 void setCOLDSPRING_FACTORY(string COLDSPRING_FACTORY)
          Set the instantiation path for ColdSpring
 void setExpandedIOCDefinitionFile(string ExpandedIOCDefinitionFile)
          Set the full expanded path of the definition file
 void setIOCDefinitionFile(string IOCDefinitionFile)
          Set the definition file configured for this plugin
 void setIOCFramework(string IOCFramework)
          Set the IoC Framework used: lightwire or coldspring
 void setIoCFactory(any IoCFactory)
          Override and set the IoCFactory the plugin will interface with
 void setLIGHTWIRE_FACTORY(string LIGHTWIRE_FACTORY)
          Set the instantiation path for LightWire
private void validateDefinitionFile()
          Validate the IoC Definition File
 
Methods inherited from class coldbox.system.Plugin
getPluginDescription, getPluginName, getPluginVersion, getRequestCollection, getRequestContext, getpluginAuthor, getpluginAuthorURL, getpluginPath, setPluginDescription, setPluginName, setPluginVersion, setpluginAuthor, setpluginAuthorURL
 
Methods inherited from class coldbox.system.FrameworkSupertype
$abort, $dump, $htmlhead, $include, $rethrow, $throw, addAsset, announceInterception, getColdboxOCM, getController, getDatasource, getDebugMode, getHash, getInstance, getInterceptor, getMailSettings, getModel, getModuleSettings, getMyPlugin, getPlugin, getResource, getSetting, getSettingStructure, getSettingsBean, getfwLocale, includeUDF, locateDirectoryPath, locateFilePath, persistVariables, populateModel, relocate, renderExternalView, renderView, runEvent, setDebugMode, setNextEvent, setNextRoute, setSetting, setfwLocale, settingExists
 
Methods inherited from class WEB-INF.cftags.component
 

Constructor Detail

init

public init(any controller)
Constructor

Parameters:
controller - coldbox.system.web.Controller
Method Detail

configure

public void configure()
Configure or Re-Configure the IoC Plugin. Loads the chosen IoC Factory and configures it for usage


createColdspring

private any createColdspring()
Creates the coldspring factory and configures it


createLightwire

private any createLightwire()
Creates the lightwire factory and configures it


createLightwireConfigBean

private any createLightwireConfigBean()
Creates the lightwire config bean


getBean

public any getBean(string beanName)
Get a Bean from the loaded object factory

Parameters:
beanName - The bean name to retrieve from the object factory

getCOLDSPRING_FACTORY

public string getCOLDSPRING_FACTORY()
Get COLDSPRING_FACTORY. This is the instantiation path for coldspring


getExpandedIOCDefinitionFile

public string getExpandedIOCDefinitionFile()
Get the full expanded path of the configuration file, only used for coldspring


getIOCDefinitionFile

public string getIOCDefinitionFile()
Get the definition file configured for this plugin


getIOCFramework

public string getIOCFramework()
Gets the IoC Framework string used: lightwire or coldspring


getIoCFactory

public any getIoCFactory()
Returns the IoC Factory in use.


getLIGHTWIRE_FACTORY

public string getLIGHTWIRE_FACTORY()
Get LIGHTWIRE_FACTORY. This is the instantiation path for lightwire


reloadDefinitionFile

public void reloadDefinitionFile()
Reloads the IoC factory with the Definition File or Object


setCOLDSPRING_FACTORY

public void setCOLDSPRING_FACTORY(string COLDSPRING_FACTORY)
Set the instantiation path for ColdSpring.

Parameters:
COLDSPRING_FACTORY - The instantiation path for coldspring

setExpandedIOCDefinitionFile

public void setExpandedIOCDefinitionFile(string ExpandedIOCDefinitionFile)
Set the full expanded path of the definition file

Parameters:
ExpandedIOCDefinitionFile - The expanded path of the main coldspring xml file

setIOCDefinitionFile

public void setIOCDefinitionFile(string IOCDefinitionFile)
Set the definition file configured for this plugin

Parameters:
IOCDefinitionFile - The relative or absolute location of the coldspring main xml file.

setIOCFramework

public void setIOCFramework(string IOCFramework)
Set the IoC Framework used: lightwire or coldspring

Parameters:
IOCFramework

setIoCFactory

public void setIoCFactory(any IoCFactory)
Override and set the IoCFactory the plugin will interface with

Parameters:
IoCFactory

setLIGHTWIRE_FACTORY

public void setLIGHTWIRE_FACTORY(string LIGHTWIRE_FACTORY)
Set the instantiation path for LightWire

Parameters:
LIGHTWIRE_FACTORY - This is the instantiation path for lightwire

validateDefinitionFile

private void validateDefinitionFile()
Validate the IoC Definition File. Called internally to verify the file location and get the correct path to it.


ColdBox Platform Version 2.6.4