On 17-May-04, at 21:44 Uhr, Daniel F. Savarese wrote:
[...] add static field access. Yet expression manipulation is limited to JavaBean
properties (otherwise there would be no need for the invoke tag), which makes
it seem like Jexl isn't the right place. If static field access were to
be added, why not arbitrary method invocation? Anyway, that's a long-winded
way of explaining why I do not yet understand the design guidelines that help
dictate what should go where.

Well, you would be even more lost that there's an amount of redundancy.
For example, jexl will let you invoke a method... it's ugly but works.
I presume that jelly's "design-guideline" are:
- in James Strachan's head... and who knows when this might come out (maybe this might even be dangerous)
- and a "digested" version in each and other's Jelly users' head. This may be very different for each
I think it makes a whole load of sense to discuss what one understands!
(there's this jelly IRC channel which should be good used some day... it has lost its archive)


My general rule is:
- Jexl for "function evaluation" (and variable evaluation
- Jelly tags for most, and especially for XML-structures
- My beans to quickly build a remote object
- My tags to make it more expressive...

The downside to doing that would seem to be that you may have to write a
converter for every bean? Or is there a way to do it once for all of
them, where by default Jelly would try to match unknown properties against
constants? I suppose that's where your mention of BeanUtils comes in. But
with a converter, am I correct in assuming you couldn't throw in a constant
defined in a different class?

I would have thought "dedicated" converters.
But BeanUtils should allow this in three lines... I would expect something like the following invented code:
c = converterContext.makeCaseBasedConverter("defaultCloseOperation");
c.addIntConstants(JFrame.class,JFrame.EXIT_ON_CLOSE,JFrame.DISPOSE_ON_CL OSE,..);


The interesting in such a "declarative" converters registration is that jelly-tag-documentation should then be able to use this!

Feel free to go ahead but let's start this discussion on the usages of
converters in jelly-attributes since it seems BeanUtils folks are
"eagerly expecting users" ;-->

I think I'll hold off on doing anything until the discussion runs its
course. So far, it seems there's agreement that it's useful to be able to
access static class fields, but there's more than one way to do it.

That's the amazing thing (and mess?) in Jelly, freedom and mix-and-match...
That's what ant really didn't allow and what programming languages tend to bann.


paul


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to