Luis Majano Forums Notification: Post to Depricated RC scope

Title: RE: Depricated RC scope
Thread: Depricated RC scope
Forum: Bugs (ColdBox)
Conference: ColdBox
User: puc

RESULTS OF FURTHER INVESTIGATION

1] If you set a variable using setValue and
retrieve it using getValue - OK - variable in event scope!!

e.g
HANDLER :
event.setValue(myVar,"myValue");
VIEW: #event.getValue(myVar)#

2] If
you set rc = event.getCollection() and then assign value to rc and retrieve it
using dot notation - OK - variable in event scope!!

e.g
HANDLER : rc.myVar =
"myValue";
VIEW: #rc.myVar#

3] BUT...if you set variable using dot
notation on event scope - NOT OK - variable NOT in event scope - BUT CAN BE
REFERENCED AND DISPLAYED!!

e.g
HANDLER : event.myVar = "myValue";
VIEW: #event.myVar#

DISPLYS OK!!!!

4]ALSO !!! if I set variable using dot
notation on variable NOT called "event" I can never get to it.

e.g
HANDLER : jelly.myVar = "myValue";
VIEW: #jelly.myVar#

VARIABLE not
found!!

CONCLUSION:
The event.someVar notation is "special" but
acting wierdly, as you can assign stuff to it using dot notation but variable
NOT in event scope!!

This is really confusing as the behaviour of the 'event'
is not consistent.

http://www.luismajano.com/forums/index.cfm?event=ehMessages.dspMessages&threadid=4C4AEEF0-123F-6116-429DF123C83D1664