root / framework / trunk / extensions / lexicon / orm / reactor / init.cfm

Revision 336, 0.8 kB (checked in by scorfield, 2 years ago)

Shuffled all the sample lexicons into the new extensions directory and added the assertions
plugin. This is in preparation for the Fusebox 6 theme are extending through extensibility.
Note that the release script has not been updated so this is a stable BER.

Line 
1<cfscript>
2        // usage:
3        //              <reactor:init
4        //                              configuration="/config/reactor.xml" />
5        if (fb_.verbInfo.executionMode is "start") {
6                // validate attributes
7                // configuration - string (path)
8                if (not structKeyExists(fb_.verbInfo.attributes,"configuration")) {
9                        fb_throw("fusebox.badGrammar.requiredAttributeMissing",
10                                                "Required attribute is missing",
11                                                "The attribute 'configuration' is required, for a 'init' verb in fuseaction #fb_.verbInfo.circuit#.#fb_.verbInfo.fuseaction#.");
12                }
13                // generate code:
14                fb_appendLine('<cfset myFusebox.getApplication().getApplicationData().reactorFactory = ' &
15                                'createObject("component","reactor.reactorFactory")' &
16                                        '.init(expandPath("#fb_.verbInfo.attributes.configuration#")) />');
17                fb_appendLine('<cfset myFusebox.trace("Reactor","Created ReactorFactory") />');
18        } else {
19        }
20</cfscript>
Note: See TracBrowser for help on using the browser.