I agree.

Like you, I see the potential benefit, but I'd prefer the more
self-documenting method of listing the xe values explicitly.

Not that it'd probably have any _significant_ impact, but it would also mean
loading every 'xe' value defined in MG.xml into _each_ rendered view.  There
may be a way to cache 'em, but even so... seems like more overhead than
would be worthwhile?


On Tue, Jul 28, 2009 at 6:07 PM, Dan Wilson <[email protected]> wrote:

>
> Interesting shortcut idea. I can see why you want it, but i'm not totally
> sold.
>
> One of the key principle of good software is readablity. Used
> properly, copyToScope leads to very readable code. I'm not sure the
> wild card idea promotes good software practices.
>
> How would any developer know what XEs were valid?
>
> Listing the desired values gives a sense of what will be in scope.
>
>
> Thoughts?
>
> Dan
>
> On 7/28/09, Dennis Clark <[email protected]> wrote:
> > What about adding wildcard support to copyToScope()? I think it'd be nice
> if
> > I could do the following in a view:
> >
> > <cfset event.copyToScope(variables,"xe.*") />
> >
> > That way I could get all the exit event values into a single structure
> > without having to list them all out.
> >
> >
> > On Tue, Jul 28, 2009 at 4:16 PM, Andy Jarrett <[email protected]
> >wrote:
> >
> >>
> >> Even in MG 3 im using XE's then on the top of most of my views I
> >> generally have a <cfscript> block like:
> >>
> >> <cfscript>
> >>        xe.link1 = viewState.getValue('xe.link1');
> >>        xe.link2 = viewState.getValue('xe.link2');
> >> </cfscript>
> >>
> >> That way they are set for the whole of the view and keeps my
> >> event.linkTo() links cleaner.
> >>
> >> <a href="#event.linkTo(xe.link1)#">Link 1</a>
> >>
> >>
> >>
> >> On Jul 24, 8:35 am, Sean Corfield <[email protected]> wrote:
> >> > Why not:
> >> >
> >> > <a href="#event.linkTo( event.getValue('xe.forgotPassword') )#">Forgot
> >> > Password?</a>
> >> > --
> >> > Sean A Corfield -- (904) 302-SEAN
> >> > Railo Technologies US --http://getrailo.com/
> >> > An Architect's View --http://corfield.org/
> >> >
> >> > "If you're not annoying somebody, you're not really alive."
> >> > -- Margaret Atwood
> >> >
> >>
> >
> > >
> >
>
>
> --
> “Come to the edge, he said. They said: We are afraid. Come to the
> edge, he said. They came. He pushed them and they flew.”
>
>  Guillaume Apollinaire quotes
>
> >
>


-- 
I have failed as much as I have succeeded. But I love my life. I love my
wife. And I wish you my kind of success.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en

For more about Model-Glue, check http://www.model-glue.com .
-~----------~----~----~----~------~----~------~--~---

Reply via email to