Skip to content

Commit cb7b695

Browse files
committed
Whitespace/indentation cleanup
Default Emacs indentation, untabify.
1 parent a3347f7 commit cb7b695

File tree

1 file changed

+47
-47
lines changed

1 file changed

+47
-47
lines changed

framework/one.cfc

+47-47
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
component {
22
variables._fw1_version = "4.0.0-snapshot";
3-
/*
4-
Copyright (c) 2009-2016, Sean Corfield, Marcin Szczepanski, Ryan Cogswell
3+
/*
4+
Copyright (c) 2009-2016, Sean Corfield, Marcin Szczepanski, Ryan Cogswell
55
6-
Licensed under the Apache License, Version 2.0 (the "License");
7-
you may not use this file except in compliance with the License.
8-
You may obtain a copy of the License at
6+
Licensed under the Apache License, Version 2.0 (the "License");
7+
you may not use this file except in compliance with the License.
8+
You may obtain a copy of the License at
99
10-
http://www.apache.org/licenses/LICENSE-2.0
10+
http://www.apache.org/licenses/LICENSE-2.0
1111
12-
Unless required by applicable law or agreed to in writing, software
13-
distributed under the License is distributed on an "AS IS" BASIS,
14-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15-
See the License for the specific language governing permissions and
16-
limitations under the License.
17-
*/
12+
Unless required by applicable law or agreed to in writing, software
13+
distributed under the License is distributed on an "AS IS" BASIS,
14+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
See the License for the specific language governing permissions and
16+
limitations under the License.
17+
*/
1818

1919
this.name = hash( getBaseTemplatePath() );
2020
if ( !structKeyExists( request, '_fw1' ) ) {
@@ -252,7 +252,7 @@ component {
252252

253253
if ( structKeyExists( request._fw1, 'controllerExecutionStarted' ) ) {
254254
throw( type='FW1.controllerExecutionStarted', message="Controller '#action#' may not be added at this point.",
255-
detail='The controller execution phase has already started. Controllers may not be added by other controller methods.' );
255+
detail='The controller execution phase has already started. Controllers may not be added by other controller methods.' );
256256
}
257257

258258
tuple.controller = getController( section = section, subsystem = subsystem );
@@ -392,7 +392,7 @@ component {
392392

393393
if ( variables.framework.defaultSubsystem == '' ) {
394394
throw( type='FW1.subsystemNotSpecified', message='No subsystem specified and no default configured.',
395-
detail='When using subsystems, every request should specify a subsystem or variables.framework.defaultSubsystem should be configured.' );
395+
detail='When using subsystems, every request should specify a subsystem or variables.framework.defaultSubsystem should be configured.' );
396396
}
397397

398398
return variables.framework.defaultSubsystem;
@@ -715,9 +715,9 @@ component {
715715
try {
716716
if ( !structKeyExists( variables, 'framework' ) ||
717717
!structKeyExists( variables.framework, 'version' ) ) {
718-
// error occurred before framework was initialized
719-
failure( exception, event, false, true );
720-
return;
718+
// error occurred before framework was initialized
719+
failure( exception, event, false, true );
720+
return;
721721
}
722722

723723
// record details of the exception:
@@ -1329,7 +1329,7 @@ component {
13291329
* returns the UI generated by the named view
13301330
*/
13311331
public any function view( string path, struct args = { },
1332-
any missingView = { } ) {
1332+
any missingView = { } ) {
13331333
var viewPath = parseViewOrLayoutPath( path, 'view' );
13341334
if ( cachedFileExists( viewPath ) ) {
13351335
internalFrameworkTrace( 'view( #path# ) called - rendering #viewPath#' );
@@ -1389,7 +1389,7 @@ component {
13891389
internalFrameworkTrace( 'building layout queue', subsystem, section, item );
13901390
// look for item-specific layout:
13911391
testLayout = parseViewOrLayoutPath( subsystem & variables.framework.subsystemDelimiter &
1392-
section & '/' & item, 'layout' );
1392+
section & '/' & item, 'layout' );
13931393
if ( cachedFileExists( testLayout ) ) {
13941394
internalFrameworkTrace( 'found item-specific layout #testLayout#', subsystem, section, item );
13951395
arrayAppend( request._fw1.layouts, testLayout );
@@ -1450,7 +1450,7 @@ component {
14501450
internalFrameworkTrace( 'building view queue', subsystem, section, item );
14511451
// view and layout setup - used to be in setupRequestWrapper():
14521452
request._fw1.view = parseViewOrLayoutPath( subsystem & variables.framework.subsystemDelimiter &
1453-
section & '/' & item, 'view' );
1453+
section & '/' & item, 'view' );
14541454
if ( cachedFileExists( request._fw1.view ) ) {
14551455
internalFrameworkTrace( 'found view #request._fw1.view#', subsystem, section, item );
14561456
} else {
@@ -1582,7 +1582,7 @@ component {
15821582
for ( var i = 1; i <= n; ++i ) {
15831583
var property = md.properties[ i ];
15841584
if ( implicitSetters ||
1585-
structKeyExists( property, 'setter' ) && isBoolean( property.setter ) && property.setter ) {
1585+
structKeyExists( property, 'setter' ) && isBoolean( property.setter ) && property.setter ) {
15861586
setters[ property.name ] = 'implicit';
15871587
}
15881588
}
@@ -1623,8 +1623,8 @@ component {
16231623
writeOutput( '<hr /><div id="fw1_trace" style="background: ##ccdddd; color: black; border: 1px solid; border-color: black; padding: 5px; #font#">' );
16241624
writeOutput( '<div style="#font# font-weight: bold; font-size: large; float: left;">Framework Lifecycle Trace</div><div style="clear: both;"></div>' );
16251625
var table = '<table style="border: 1px solid; border-color: black; color: black; #font#" width="100%">' &
1626-
'<tr><th style="text-align:right;" width="5%">time</th><th style="text-align:right;" width="5%">delta</th>' &
1627-
'<th style="text-align:center;">type</th><th width="10%">action</th><th>message</th></tr>';
1626+
'<tr><th style="text-align:right;" width="5%">time</th><th style="text-align:right;" width="5%">delta</th>' &
1627+
'<th style="text-align:center;">type</th><th width="10%">action</th><th>message</th></tr>';
16281628
writeOutput( table );
16291629
var colors = [ '##ccd4dd', '##ccddcc' ];
16301630
var row = 0;
@@ -1942,7 +1942,7 @@ component {
19421942
case 'view':
19431943
folder = variables.viewFolder;
19441944
break;
1945-
// else leave it alone?
1945+
// else leave it alone?
19461946
}
19471947
var pathInfo = { };
19481948
var subsystem = getSubsystem( getSubsystemSectionAndItem( path ) );
@@ -2268,10 +2268,10 @@ component {
22682268
structAppend( request.context, session[ preserveKeySessionKey ], false );
22692269
if ( variables.framework.maxNumContextsPreserved == 1 ) {
22702270
/*
2271-
When multiple contexts are preserved, the oldest context is purged
2272-
within getNextPreserveKeyAndPurgeOld once the maximum is reached.
2273-
This allows for a browser refresh after the redirect to still receive
2274-
the same context.
2271+
When multiple contexts are preserved, the oldest context is purged
2272+
within getNextPreserveKeyAndPurgeOld once the maximum is reached.
2273+
This allows for a browser refresh after the redirect to still receive
2274+
the same context.
22752275
*/
22762276
structDelete( session, preserveKeySessionKey );
22772277
}
@@ -2389,9 +2389,9 @@ component {
23892389
// this will recreate the main bean factory on a reload:
23902390
internalFrameworkTrace( 'setupApplication() called' );
23912391
setupApplication();
2392-
application[variables.framework.applicationKey] = request._fw1.theApp;
2392+
application[variables.framework.applicationKey] = request._fw1.theApp;
23932393

2394-
}
2394+
}
23952395

23962396
private void function setupFrameworkDefaults() {
23972397
if ( structKeyExists( variables, "_fw1_defaults_initialized" ) ) return;
@@ -2585,19 +2585,19 @@ component {
25852585
if ( !structKeyExists( variables.framework, 'diComponent' ) ) {
25862586
var diComponent = 'framework.ioc';
25872587
switch ( variables.framework.diEngine ) {
2588-
case 'aop1':
2589-
diComponent = 'framework.aop';
2590-
break;
2591-
case 'wirebox':
2592-
diComponent = 'framework.WireBoxAdapter';
2593-
break;
2594-
case 'custom':
2595-
throw( type="FW1.IllegalConfiguration",
2596-
message="If you specify diEngine='custom' you must specify a component path for diComponent." );
2597-
break;
2598-
default:
2599-
// assume DI/1
2600-
break;
2588+
case 'aop1':
2589+
diComponent = 'framework.aop';
2590+
break;
2591+
case 'wirebox':
2592+
diComponent = 'framework.WireBoxAdapter';
2593+
break;
2594+
case 'custom':
2595+
throw( type="FW1.IllegalConfiguration",
2596+
message="If you specify diEngine='custom' you must specify a component path for diComponent." );
2597+
break;
2598+
default:
2599+
// assume DI/1
2600+
break;
26012601
}
26022602
variables.framework.diComponent = diComponent;
26032603
}
@@ -2793,8 +2793,8 @@ component {
27932793
try {
27942794
var paramPairs = listToArray( body, "&" );
27952795
for ( var pair in paramPairs ) {
2796-
var parts = listToArray( pair, "=", true ); // handle blank values
2797-
request.context[ parts[ 1 ] ] = urlDecode( parts[ 2 ] );
2796+
var parts = listToArray( pair, "=", true ); // handle blank values
2797+
request.context[ parts[ 1 ] ] = urlDecode( parts[ 2 ] );
27982798
}
27992799
} catch ( any e ) {
28002800
throw( type = "FW1.JSONPOST",
@@ -2902,7 +2902,7 @@ component {
29022902
// check for forward and backward slash in the action - using chr() to avoid confusing TextMate (Hi Nathan!)
29032903
if ( findOneOf( chr(47) & chr(92), action ) > 0 ) {
29042904
throw( type='FW1.actionContainsSlash', message="Found a slash in the action: '#action#'.",
2905-
detail='Actions are not allowed to embed sub-directory paths.');
2905+
detail='Actions are not allowed to embed sub-directory paths.');
29062906
}
29072907
return action;
29082908
}
@@ -2913,7 +2913,7 @@ component {
29132913
// the exception we actually want to throw!
29142914
param name="request.missingView" default="<unknown.view>";
29152915
throw( type='FW1.viewNotFound', message="Unable to find a view for '#request.action#' action.",
2916-
detail="'#request.missingView#' does not exist." );
2916+
detail="'#request.missingView#' does not exist." );
29172917
}
29182918

29192919
}

0 commit comments

Comments
 (0)