Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-24 Thread John Patterson
Is this standard going to be followed for every attribute?  Currently, it
seems that certain attributes are exempt and it is difficult to predict
which.  For example, when setting params with ww:param on the BeanTag the
name is evaluated whereas on the URLTag it is not.  This is due to the
ParamTag not evaluating the 'name' attribute but leaving it to the
ParametisedTag to override the addParam() method.

ie
public void addParam(String key, Object value) {

OgnlUtil.setProperty(findString(key), value, bean, getStack().getContext());

}

If it is decided that all attributes are to be evaluated then this should be
made consistent by moving the evaluation code into the ParamTag.  Otherwise,
if this selective evaluation is to be kept then I suggest some naming
standard is used and well documented.

Personally I had no problems with the old WW2 practice of not evaluating
'name' attributes.  I have to struggle to think of a situation where
evaluating any 'name' attribute is useful.  But I can understand those who
think that this practice was inconsistent.

John.

- Original Message - 
From: Jason Carreira [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, November 24, 2003 4:36 AM
Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes


ww:property value='firstHalf' + secondHalf/

I have to agree that the ${} syntax makes this easier Especially where
you want to put in single quotes (see the indexed property example I just
added tonight) and yet... It's too much to change.

 -Original Message-
 From: Drew McAuliffe [mailto:[EMAIL PROTECTED]
 Sent: Sunday, November 23, 2003 11:30 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes


 What about

 ww:property value=firstHalf${secondHalf}/

 ? The advantage of the velocity-style escaped syntax is that
 it allows for more flexibility, so that the whole thing
 doesn't have to get evaluated.

 Also, what about tags where what could be displayed might be
 evaluated in some cases, but might not in others? How can you
 build that logic into the framework so it knows whether to be
 evaluated or not? I think the question is not whether we
 should always evaluate or not, because that question has been
 answered already by use of the triple-quoting; it has been
 decided that it is more flexible to allow for values to be
 passed into tag attributes that _can_ be evaluated against
 the stack but don't always have to be. I agree with that
 approach. The question I'm raising is regarding the way the
 syntax of those values is structured. I just don't like the
 triple-quote approach.

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On
 Behalf Of boxed
 Sent: Sunday, November 23, 2003 2:02 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

 Drew McAuliffe wrote:

 I agree, and I think that it should be the ${} syntax. The reason I
 like the optional syntax is solely for backwards compatibility.
 
 
 I don't see why you are using java if you prefer that way of
 writing personally.

 Let's compare the alternaitves:
 ww:property value=name/
 ww:property value=${name}/

 Am I wrong in assuming that simple usage of the variables is
 the most common thing in the WW EL? Because if it is then
 implementing a more verbose syntax for it is
 counterproductive. The rule of thumb is to make the most
 common actions simple and intuitive and there is nothing
 intuitive about the ${} syntax.

 Anders Hovmöller




 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it
 help you create better code?  SHARE THE LOVE, and help us
 help YOU!  Click Here: http://sourceforge.net/donate/
 ___
 Opensymphony-webwork mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-24 Thread Patrick Lightbody
I've had situations where resolving the name dynamically has been VERY
important (think of a generic configuration editor -- say, something
that edits a .properties file).

As for inconsistencies, those should be addressed. Could you compile a
list of the ones you've found and open a bug?

-Pat

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
John Patterson
Sent: Monday, November 24, 2003 2:17 AM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

Is this standard going to be followed for every attribute?  Currently,
it
seems that certain attributes are exempt and it is difficult to predict
which.  For example, when setting params with ww:param on the BeanTag
the
name is evaluated whereas on the URLTag it is not.  This is due to the
ParamTag not evaluating the 'name' attribute but leaving it to the
ParametisedTag to override the addParam() method.

ie
public void addParam(String key, Object value) {

OgnlUtil.setProperty(findString(key), value, bean,
getStack().getContext());

}

If it is decided that all attributes are to be evaluated then this
should be
made consistent by moving the evaluation code into the ParamTag.
Otherwise,
if this selective evaluation is to be kept then I suggest some naming
standard is used and well documented.

Personally I had no problems with the old WW2 practice of not evaluating
'name' attributes.  I have to struggle to think of a situation where
evaluating any 'name' attribute is useful.  But I can understand those
who
think that this practice was inconsistent.

John.

- Original Message - 
From: Jason Carreira [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, November 24, 2003 4:36 AM
Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes


ww:property value='firstHalf' + secondHalf/

I have to agree that the ${} syntax makes this easier Especially
where
you want to put in single quotes (see the indexed property example I
just
added tonight) and yet... It's too much to change.

 -Original Message-
 From: Drew McAuliffe [mailto:[EMAIL PROTECTED]
 Sent: Sunday, November 23, 2003 11:30 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes


 What about

 ww:property value=firstHalf${secondHalf}/

 ? The advantage of the velocity-style escaped syntax is that
 it allows for more flexibility, so that the whole thing
 doesn't have to get evaluated.

 Also, what about tags where what could be displayed might be
 evaluated in some cases, but might not in others? How can you
 build that logic into the framework so it knows whether to be
 evaluated or not? I think the question is not whether we
 should always evaluate or not, because that question has been
 answered already by use of the triple-quoting; it has been
 decided that it is more flexible to allow for values to be
 passed into tag attributes that _can_ be evaluated against
 the stack but don't always have to be. I agree with that
 approach. The question I'm raising is regarding the way the
 syntax of those values is structured. I just don't like the
 triple-quote approach.

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On
 Behalf Of boxed
 Sent: Sunday, November 23, 2003 2:02 PM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

 Drew McAuliffe wrote:

 I agree, and I think that it should be the ${} syntax. The reason I
 like the optional syntax is solely for backwards compatibility.
 
 
 I don't see why you are using java if you prefer that way of
 writing personally.

 Let's compare the alternaitves:
 ww:property value=name/
 ww:property value=${name}/

 Am I wrong in assuming that simple usage of the variables is
 the most common thing in the WW EL? Because if it is then
 implementing a more verbose syntax for it is
 counterproductive. The rule of thumb is to make the most
 common actions simple and intuitive and there is nothing
 intuitive about the ${} syntax.

 Anders Hovmöller




 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it
 help you create better code?  SHARE THE LOVE, and help us
 help YOU!  Click Here: http://sourceforge.net/donate/
 ___
 Opensymphony-webwork mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork

Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread boxed
Patrick Lightbody wrote:

Hmm this is pretty interesting. Id like to hear the opinion from the 
1.4 guys on this as well.

I for one dispise the ${} JSTL/whatever syntax above all else. It's just 
plain retarded. Now, I realize that having to put ' around strings can 
be seen as annoying (although I find the term tripleqouting to be 
somewhat misleading), but a way around that could be to introduce a more 
obvious syntax like String(my literal string). This is to me much better 
than the JSTL way where I have to put ${} around all variables. 
Introducing the JSTL syntax will lead to MORE typing, not less.

Maybe the EL parser should be more intelligent with this though. If you 
write: ww:property value=foo bar/ it is obvious that this is not a 
valid variable name, so the page could just return a big and obvious 
error message. This later approach is also backwards compatible.

Anders Hovmller

---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Drew McAuliffe
I suppose retarded is in the eye of the beholder...:)

I don't know about it from a JSTL point of view, but velocity uses this
syntax, as does the evaluation that goes on in the xwork config file, as
does Ant, etc. I find it to be very clear. In brackets led by a $, this is
a variable that should be evaluated. As for your suggestion, I'm not sure,
as I can see how certain things can be obvious to a person, but not easy to
make obvious for a machine. 

I do like the idea of allowing the user to determine which method to use,
though. 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of boxed
Sent: Sunday, November 23, 2003 8:24 AM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

Patrick Lightbody wrote:

 Hmm… this is pretty interesting. I’d like to hear the opinion from the
 1.4 guys on this as well.

I for one dispise the ${} JSTL/whatever syntax above all else. It's just
plain retarded. Now, I realize that having to put ' around strings can be
seen as annoying (although I find the term tripleqouting to be somewhat
misleading), but a way around that could be to introduce a more obvious
syntax like String(my literal string). This is to me much better than the
JSTL way where I have to put ${} around all variables. 
Introducing the JSTL syntax will lead to MORE typing, not less.

Maybe the EL parser should be more intelligent with this though. If you
write: ww:property value=foo bar/ it is obvious that this is not a valid
variable name, so the page could just return a big and obvious error
message. This later approach is also backwards compatible.

Anders Hovmöller




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Jason Carreira
I really dislike the option of which syntax to use... Lets choose one and use it...

 -Original Message-
 From: Drew McAuliffe [mailto:[EMAIL PROTECTED] 
 Sent: Sunday, November 23, 2003 2:14 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes
 
 
 I suppose retarded is in the eye of the beholder...:)
 
 I don't know about it from a JSTL point of view, but velocity 
 uses this syntax, as does the evaluation that goes on in the 
 xwork config file, as does Ant, etc. I find it to be very 
 clear. In brackets led by a $, this is a variable that 
 should be evaluated. As for your suggestion, I'm not sure, 
 as I can see how certain things can be obvious to a person, 
 but not easy to make obvious for a machine. 
 
 I do like the idea of allowing the user to determine which 
 method to use, though. 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of boxed
 Sent: Sunday, November 23, 2003 8:24 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes
 
 Patrick Lightbody wrote:
 
  Hmm... this is pretty interesting. I'd like to hear the 
 opinion from the 
  1.4 guys on this as well.
 
 I for one dispise the ${} JSTL/whatever syntax above all 
 else. It's just plain retarded. Now, I realize that having to 
 put ' around strings can be seen as annoying (although I find 
 the term tripleqouting to be somewhat misleading), but a 
 way around that could be to introduce a more obvious syntax 
 like String(my literal string). This is to me much better 
 than the JSTL way where I have to put ${} around all variables. 
 Introducing the JSTL syntax will lead to MORE typing, not less.
 
 Maybe the EL parser should be more intelligent with this 
 though. If you
 write: ww:property value=foo bar/ it is obvious that this 
 is not a valid variable name, so the page could just return a 
 big and obvious error message. This later approach is also 
 backwards compatible.
 
 Anders Hovmöller
 
 
 
 
 ---
 This SF.net email is sponsored by: SF.net Giveback Program. 
 Does SourceForge.net help you be more productive?  Does it 
 help you create better code?  SHARE THE LOVE, and help us 
 help YOU!  Click Here: http://sourceforge.net/donate/ 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Rickard Öberg
Jason Carreira wrote:

I really dislike the option of which syntax to use... Lets choose one and use it...
Definitely agree.

Think about the case where many components/projects using WebWork needs 
to be merged into one big app. Oh that won't work because we used 
optional method Foo, whereas you used Bar is NOT a good situation.

Said it before, and will say it again:
What makes a framework powerful is not what it allows, but what it does 
not allow.

This is one of those cases where this is really important to remember.

/Rickard



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Joseph Ottinger
What would be realy nice is if the JSTL's EL had ben written with
extensibility in mind to begin with, a lot like what Joe Walnes ended up
putting into the FormTags project. What worked there is that you had a
ww: prefix to specify that the formtags were to use the expression
language for webwork, and other prefixes could have been supported as
well. I tried to get the JSTL to work this way, but it didn't quite work
out the way I wanted (i.e., they decided that nobody needed such a
feature, and handed it off to you guys.)

It still might be workable from webwork's perspective to use that kind of
prefix idea.

On Sun, 23 Nov 2003, [ISO-8859-1] Rickard Öberg wrote:

 Jason Carreira wrote:

  I really dislike the option of which syntax to use... Lets choose one and use it...

 Definitely agree.

 Think about the case where many components/projects using WebWork needs
 to be merged into one big app. Oh that won't work because we used
 optional method Foo, whereas you used Bar is NOT a good situation.

 Said it before, and will say it again:
 What makes a framework powerful is not what it allows, but what it does
 not allow.

 This is one of those cases where this is really important to remember.

 /Rickard




 ---
 This SF.net email is sponsored by: SF.net Giveback Program.
 Does SourceForge.net help you be more productive?  Does it
 help you create better code?  SHARE THE LOVE, and help us help
 YOU!  Click Here: http://sourceforge.net/donate/
 ___
 Opensymphony-webwork mailing list
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


---
Joseph B. Ottinger http://enigmastation.com
IT Consultant[EMAIL PROTECTED]
J2EE Editor - Java Developer's Journal   [EMAIL PROTECTED]



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Drew McAuliffe
I agree, and I think that it should be the ${} syntax. The reason I like the
optional syntax is solely for backwards compatibility. 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Rickard Öberg
Sent: Sunday, November 23, 2003 11:34 AM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

Jason Carreira wrote:

 I really dislike the option of which syntax to use... Lets choose one and
use it...

Definitely agree.

Think about the case where many components/projects using WebWork needs to
be merged into one big app. Oh that won't work because we used optional
method Foo, whereas you used Bar is NOT a good situation.

Said it before, and will say it again:
What makes a framework powerful is not what it allows, but what it does not
allow.

This is one of those cases where this is really important to remember.

/Rickard






---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread boxed
Drew McAuliffe wrote:

I agree, and I think that it should be the ${} syntax. The reason I like the
optional syntax is solely for backwards compatibility. 
 

I don't see why you are using java if you prefer that way of writing 
personally.

Let's compare the alternaitves:
ww:property value=name/
ww:property value=${name}/
Am I wrong in assuming that simple usage of the variables is the most 
common thing in the WW EL? Because if it is then implementing a more 
verbose syntax for it is counterproductive. The rule of thumb is to make 
the most common actions simple and intuitive and there is nothing 
intuitive about the ${} syntax.

Anders Hovmöller

---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


Re: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Rickard Öberg
boxed wrote:
Drew McAuliffe wrote:

I agree, and I think that it should be the ${} syntax. The reason I 
like the
optional syntax is solely for backwards compatibility.  

I don't see why you are using java if you prefer that way of writing 
personally.

Let's compare the alternaitves:
ww:property value=name/
ww:property value=${name}/
Am I wrong in assuming that simple usage of the variables is the most 
common thing in the WW EL? Because if it is then implementing a more 
verbose syntax for it is counterproductive. The rule of thumb is to make 
the most common actions simple and intuitive and there is nothing 
intuitive about the ${} syntax.
Right. In Velocity the other way makes sense because the $ is used in 
plain HTML, i.e. comparing:
ww:property value=name/
${name}
--
But when comparing between the alternatives as above, I think it's 
better to use the non-$ approach.

/Rickard



---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Jason Carreira
Well, I would be with you on that (as it's more apparent what you're expecting to be 
evaluated) but it won't fly for backward compatibility

 -Original Message-
 From: Drew McAuliffe [mailto:[EMAIL PROTECTED] 
 Sent: Sunday, November 23, 2003 4:25 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes
 
 
 I agree, and I think that it should be the ${} syntax. The 
 reason I like the optional syntax is solely for backwards 
 compatibility. 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Rickard Öberg
 Sent: Sunday, November 23, 2003 11:34 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes
 
 Jason Carreira wrote:
 
  I really dislike the option of which syntax to use... Lets 
 choose one 
  and
 use it...
 
 Definitely agree.
 
 Think about the case where many components/projects using 
 WebWork needs to be merged into one big app. Oh that won't 
 work because we used optional method Foo, whereas you used 
 Bar is NOT a good situation.
 
 Said it before, and will say it again:
 What makes a framework powerful is not what it allows, but 
 what it does not allow.
 
 This is one of those cases where this is really important to remember.
 
 /Rickard
 
 
 
 
 
 
 ---
 This SF.net email is sponsored by: SF.net Giveback Program. 
 Does SourceForge.net help you be more productive?  Does it 
 help you create better code?  SHARE THE LOVE, and help us 
 help YOU!  Click Here: http://sourceforge.net/donate/ 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Patrick Lightbody
OK -- let's just end this discussion. It's not going to change for the
2.0 release :P

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Jason Carreira
Sent: Sunday, November 23, 2003 2:31 PM
To: [EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes

Well, I would be with you on that (as it's more apparent what you're
expecting to be evaluated) but it won't fly for backward compatibility

 -Original Message-
 From: Drew McAuliffe [mailto:[EMAIL PROTECTED] 
 Sent: Sunday, November 23, 2003 4:25 PM
 To: [EMAIL PROTECTED]
 Subject: RE: [OS-webwork] OGNL madness - evaluated tag attributes
 
 
 I agree, and I think that it should be the ${} syntax. The 
 reason I like the optional syntax is solely for backwards 
 compatibility. 
 
 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On 
 Behalf Of Rickard Öberg
 Sent: Sunday, November 23, 2003 11:34 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes
 
 Jason Carreira wrote:
 
  I really dislike the option of which syntax to use... Lets 
 choose one 
  and
 use it...
 
 Definitely agree.
 
 Think about the case where many components/projects using 
 WebWork needs to be merged into one big app. Oh that won't 
 work because we used optional method Foo, whereas you used 
 Bar is NOT a good situation.
 
 Said it before, and will say it again:
 What makes a framework powerful is not what it allows, but 
 what it does not allow.
 
 This is one of those cases where this is really important to remember.
 
 /Rickard
 
 
 
 
 
 
 ---
 This SF.net email is sponsored by: SF.net Giveback Program. 
 Does SourceForge.net help you be more productive?  Does it 
 help you create better code?  SHARE THE LOVE, and help us 
 help YOU!  Click Here: http://sourceforge.net/donate/ 
 ___
 Opensymphony-webwork mailing list 
 [EMAIL PROTECTED]
 https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
 


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-23 Thread Drew McAuliffe
What about 

ww:property value=firstHalf${secondHalf}/

? The advantage of the velocity-style escaped syntax is that it allows for
more flexibility, so that the whole thing doesn't have to get evaluated.

Also, what about tags where what could be displayed might be evaluated in
some cases, but might not in others? How can you build that logic into the
framework so it knows whether to be evaluated or not? I think the question
is not whether we should always evaluate or not, because that question has
been answered already by use of the triple-quoting; it has been decided
that it is more flexible to allow for values to be passed into tag
attributes that _can_ be evaluated against the stack but don't always have
to be. I agree with that approach. The question I'm raising is regarding the
way the syntax of those values is structured. I just don't like the
triple-quote approach.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of boxed
Sent: Sunday, November 23, 2003 2:02 PM
To: [EMAIL PROTECTED]
Subject: Re: [OS-webwork] OGNL madness - evaluated tag attributes

Drew McAuliffe wrote:

I agree, and I think that it should be the ${} syntax. The reason I 
like the optional syntax is solely for backwards compatibility.
  

I don't see why you are using java if you prefer that way of writing
personally.

Let's compare the alternaitves:
ww:property value=name/
ww:property value=${name}/

Am I wrong in assuming that simple usage of the variables is the most common
thing in the WW EL? Because if it is then implementing a more verbose syntax
for it is counterproductive. The rule of thumb is to make the most common
actions simple and intuitive and there is nothing intuitive about the ${}
syntax.

Anders Hovmöller




---
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
___
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-22 Thread Patrick Lightbody









Hmm this is pretty interesting. Id
like to hear the opinion from the 1.4 guys on this as well.



-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Drew McAuliffe
Sent: Friday, November 21, 2003
11:32 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes



One thing to keep in mind
is that a velocity-style syntax to represent what will be evaluated is
consistent with how stack evaluations are performed against data in the xwork
config file. In that file, if you want the action result or result path to be dynamic,
you do the ${dynamicValue} trick. It would be REALLY nice if the tags and
velocity stuff worked the same way, so that the same syntax is used throughout
the framework. Perhaps the manner in which evaluation is performed could be
switched via a webwork.properties setting, so that with one setting, you do it
with the triple-quote (for backwards compatibility) and another way, you do it
with velocity-style ${} syntax.









From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Patrick Lightbody
Sent: Friday, November 21, 2003
5:16 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes

Well, this is to be
compatible with 1.x so I think the 1.x guys should get involved in the
discussion at this point



-Original Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Robert Douglass
Sent: Friday, November 21, 2003
1:32 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes





I
couldn't agree more. I've always found the triple-quoting ugly... makes my brain
go all scrambled eggs.





-Original
Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]On Behalf Of Drew McAuliffe
Sent: Friday, November 21, 2003
8:05 PM
To: [EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes

I kind
of agree. I think triple-quoting simple parameters like name is
kind of silly. In fact, I've never really liked the triple-quoting much at all
(it seems unwieldy to me), though I understand the need for it. To me, it might
be easier to just ditch the whole triple-quote thing and do the evaluation
velocity style, with a ${} combination indicating something that should be
evaluated (e.g., name=someName value=${evaluateThis}).
Though of course I'd expect that to be controversial













From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of John Patterson
Sent: Friday, November 21, 2003
6:38 AM
To: Webwork
Subject: [OS-webwork] OGNL madness
- evaluated tag attributes



Hi,











I have just run my app with the
release candidate and am in the process of changing many (but not all) of the
tag attributes to use single quotes for literals. I am thinking that in
many instances, evaluating the attribute tag is not really very helpful.
For example, the Bean tag has an attribute 'name' for the name of the class to
instantiate. This is now treated as an OGNL _expression_ and evaluated to
derive the name of the class to use. OGNL madness!











In 99% of cases it seems that this
attribute does not need to be evaluated. Forcing the developer to
triple quote values most of the time will lead to annoying, hard to
spot, errors (and already has for me). What may have been a step forward
for compatibility has IMHO been a large step backwards in usability.











So what I am suggesting is that we
only evaluate attributes where that would be the expected common usage.
Wewould need touse a standard way of naming literal expressions
that areNOT treated as OGNL expressions. For example, attributes
called 'name' could be treated as literals but passed through the TextUtil
thing (so you can use name=${first}-${second}).











Attributes called value
on the other hand are often variant and therefore would make sense to evaluate
them. You would then have to triple quote them to use a
literal. For those who think that this would break consistency, consider
that not all attributes are currently evaluated (eg Iterator status, Set
name). So in fact, introducing such a naming standard would increase
consistency (maybe at the expense of backward compatibility)











John












[OS-webwork] OGNL madness - evaluated tag attributes

2003-11-21 Thread John Patterson



Hi,

I have just run my app with the release candidate 
and am in the process of changing many (but not all) of the tag attributes to 
use single quotes for literals. I am thinking that in many instances, 
evaluating the attribute tag is not really very helpful. For example, the 
Bean tag has an attribute 'name' for the name of the class to instantiate. 
This is now treated as an OGNL _expression_ and evaluated to derive the name of 
the class to use. OGNL madness!

In 99% of cases it seems that this attribute does 
not need to be evaluated. Forcing the developer to "triple quote" values 
most of the time will lead to annoying, hard to spot, errors (and already has 
for me). What may have been a step forward for compatibility has IMHO been 
a large step backwards in usability.

So what I am suggesting is that we only evaluate 
attributes where that would be the expected common usage. Wewould need touse a standard way of naming 
literal expressions that areNOT treated as OGNL expressions. For 
example, attributes called 'name' could be treated as literals but passed 
through the TextUtil thing (so you can use 
name="${first}-${second}").

Attributes called "value" on the other hand are 
often variant and therefore would make sense to evaluate them. You would 
then have to "triple quote" them to use a literal. For those who think 
that this would break consistency, consider that not all attributes are 
currently evaluated (eg Iterator status, Set name). So in fact, 
introducing such a naming standard would increase consistency (maybe at the 
expense of backward compatibility)

John


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-21 Thread Drew McAuliffe



I kind of agree. I think triple-quoting simple parameters 
like "name" is kind of silly. In fact, I've never really liked the 
triple-quoting much at all (it seems unwieldy to me), though I understand the 
need for it. To me, it might be easier to just ditch the whole triple-quote 
thing and do the evaluation velocity style, with a ${} combination indicating 
something that should be evaluated (e.g., name="someName" 
value="${evaluateThis}"). Though of course I'd expect that to be 
controversial


From: 
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] On Behalf Of 
John PattersonSent: Friday, November 21, 2003 6:38 
AMTo: WebworkSubject: [OS-webwork] OGNL madness - 
evaluated tag attributes

Hi,

I have just run my app with the release candidate 
and am in the process of changing many (but not all) of the tag attributes to 
use single quotes for literals. I am thinking that in many instances, 
evaluating the attribute tag is not really very helpful. For example, the 
Bean tag has an attribute 'name' for the name of the class to instantiate. 
This is now treated as an OGNL _expression_ and evaluated to derive the name of 
the class to use. OGNL madness!

In 99% of cases it seems that this attribute does 
not need to be evaluated. Forcing the developer to "triple quote" values 
most of the time will lead to annoying, hard to spot, errors (and already has 
for me). What may have been a step forward for compatibility has IMHO been 
a large step backwards in usability.

So what I am suggesting is that we only evaluate 
attributes where that would be the expected common usage. Wewould need touse a standard way of naming 
literal expressions that areNOT treated as OGNL expressions. For 
example, attributes called 'name' could be treated as literals but passed 
through the TextUtil thing (so you can use 
name="${first}-${second}").

Attributes called "value" on the other hand are 
often variant and therefore would make sense to evaluate them. You would 
then have to "triple quote" them to use a literal. For those who think 
that this would break consistency, consider that not all attributes are 
currently evaluated (eg Iterator status, Set name). So in fact, 
introducing such a naming standard would increase consistency (maybe at the 
expense of backward compatibility)

John


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-21 Thread Robert Douglass



I 
couldn't agree more. I've always found the triple-quoting ugly... makes my brain 
go all scrambled eggs.

  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]On Behalf Of 
  Drew McAuliffeSent: Friday, November 21, 2003 8:05 
  PMTo: [EMAIL PROTECTED]Subject: 
  RE: [OS-webwork] OGNL madness - evaluated tag attributes
  I kind of agree. I think triple-quoting simple parameters 
  like "name" is kind of silly. In fact, I've never really liked the 
  triple-quoting much at all (it seems unwieldy to me), though I understand the 
  need for it. To me, it might be easier to just ditch the whole triple-quote 
  thing and do the evaluation velocity style, with a ${} combination indicating 
  something that should be evaluated (e.g., name="someName" 
  value="${evaluateThis}"). Though of course I'd expect that to be 
  controversial
  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  John PattersonSent: Friday, November 21, 2003 6:38 
  AMTo: WebworkSubject: [OS-webwork] OGNL madness - 
  evaluated tag attributes
  
  Hi,
  
  I have just run my app with the release candidate 
  and am in the process of changing many (but not all) of the tag attributes to 
  use single quotes for literals. I am thinking that in many instances, 
  evaluating the attribute tag is not really very helpful. For example, 
  the Bean tag has an attribute 'name' for the name of the class to 
  instantiate. This is now treated as an OGNL _expression_ and evaluated to 
  derive the name of the class to use. OGNL madness!
  
  In 99% of cases it seems that this attribute does 
  not need to be evaluated. Forcing the developer to "triple quote" values 
  most of the time will lead to annoying, hard to spot, errors (and already has 
  for me). What may have been a step forward for compatibility has IMHO 
  been a large step backwards in usability.
  
  So what I am suggesting is that we only evaluate 
  attributes where that would be the expected common usage. Wewould need touse a standard way of naming 
  literal expressions that areNOT treated as OGNL expressions. For 
  example, attributes called 'name' could be treated as literals but passed 
  through the TextUtil thing (so you can use 
  name="${first}-${second}").
  
  Attributes called "value" on the other hand are 
  often variant and therefore would make sense to evaluate them. You would 
  then have to "triple quote" them to use a literal. For those who think 
  that this would break consistency, consider that not all attributes are 
  currently evaluated (eg Iterator status, Set name). So in fact, 
  introducing such a naming standard would increase consistency (maybe at the 
  expense of backward compatibility)
  
  John


RE: [OS-webwork] OGNL madness - evaluated tag attributes

2003-11-21 Thread Patrick Lightbody









Well, this is to be compatible with 1.x
so I think the 1.x guys should get involved in the discussion at this point



-Original Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Robert Douglass
Sent: Friday, November 21, 2003
1:32 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes





I couldn't agree more.
I've always found the triple-quoting ugly... makes my brain go all scrambled
eggs.





-Original
Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]On Behalf Of Drew McAuliffe
Sent: Friday, November 21, 2003
8:05 PM
To:
[EMAIL PROTECTED]
Subject: RE: [OS-webwork] OGNL
madness - evaluated tag attributes

I kind of agree. I think
triple-quoting simple parameters like name is kind of silly. In
fact, I've never really liked the triple-quoting much at all (it seems unwieldy
to me), though I understand the need for it. To me, it might be easier to just
ditch the whole triple-quote thing and do the evaluation velocity style, with a
${} combination indicating something that should be evaluated (e.g.,
name=someName value=${evaluateThis}). Though of course
I'd expect that to be controversial









From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of John Patterson
Sent: Friday, November 21, 2003
6:38 AM
To: Webwork
Subject: [OS-webwork] OGNL madness
- evaluated tag attributes



Hi,











I have just run my app with the
release candidate and am in the process of changing many (but not all) of the
tag attributes to use single quotes for literals. I am thinking that in
many instances, evaluating the attribute tag is not really very helpful.
For example, the Bean tag has an attribute 'name' for the name of the class to
instantiate. This is now treated as an OGNL _expression_ and evaluated to
derive the name of the class to use. OGNL madness!











In 99% of cases it seems that this
attribute does not need to be evaluated. Forcing the developer to
triple quote values most of the time will lead to annoying, hard to
spot, errors (and already has for me). What may have been a step forward
for compatibility has IMHO been a large step backwards in usability.











So what I am suggesting is that we
only evaluate attributes where that would be the expected common usage.
Wewould need touse a standard way of naming literal expressions
that areNOT treated as OGNL expressions. For example, attributes
called 'name' could be treated as literals but passed through the TextUtil
thing (so you can use name=${first}-${second}).











Attributes called value
on the other hand are often variant and therefore would make sense to evaluate
them. You would then have to triple quote them to use a
literal. For those who think that this would break consistency, consider
that not all attributes are currently evaluated (eg Iterator status, Set
name). So in fact, introducing such a naming standard would increase
consistency (maybe at the expense of backward compatibility)











John