RE: [EL] Docs ?

2005-07-01 Thread Jörg Schaible
Michael Rasmussen wrote on Thursday, June 30, 2005 10:47 PM:

 Sorry,
   it is not my intention to split hairs here.  I am just
 saying that if you want to support the same syntax as the
 JSTL-EL you will nto be able to do it with JEXL.  You are
 however more likely to be able to continue to support a JSTL
 syntax, as it evolves, by using the taglibs project.  JEXL
 will not accomplish this.  The original posters requirement
 was to cater to users who were familiar with the JSTL syntax.
 
   Your point about JSTL-EL not existing outside the Servlet
 container is well taken, and it deserves to be made clear.
 So thank you.
 
 Michael

Thanks to both of you for clarifying this.

- Jörg

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



RE: [EL] Docs ?

2005-06-30 Thread Tim O'Brien
Right, to go back to the EL.  

commons-el supports EL as defined in the original JSTL spec and the JSP 2.0 
specifications.  For you to claim to support EL you are going to have to 
reference either one of those specs, I'm fairly certain that EL was never 
defined as anything that could live outside of either of these J2EE-specific 
specifications.  

So, in other words, you couldn't claim to support EL outside of a servlet 
environment, but you could claim to support something similar to EL, and that 
would be JEXL.

Tim O'Brien
[EMAIL PROTECTED]

 -Original Message-
 From: Jörg Schaible [mailto:[EMAIL PROTECTED] 
 Sent: Monday, June 27, 2005 2:23 AM
 To: Jakarta Commons Users List
 Subject: RE: [EL] Docs ?
 
 Hi Tim,
 
 Tim O'Brien wrote on Sunday, June 26, 2005 1:05 AM:
 
  EL is meant to be used in a JSP 2.0 environment. 
 
 That's what I wanted to find out for commons-el, wheter it 
 can be used standalone or not. I write a component, that 
 others with EL experiance will have to use.
 
  You can get
  everything you need form Commons JEXL.
 
 [snip]
 
 Well, may I cite from the JEXl homepage:
 
 cite
 It must be noted that JEXL is not a compatibile 
 implementation of EL as defined in JSTL 1.1 (JSR-052) or JSP 
 2.0 (JSR-152). For a compatible implementation of these 
 specifications, see the  Commons EL  project.
 /cite
 
 If I release a component that claims to have EL support, any 
 problem with it will cause maintenance effort on my side.
 
 - Jörg
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



RE: [EL] Docs ?

2005-06-30 Thread Michael Rasmussen
So, in other words, you couldn't claim to support EL outside of a =
servlet environment, but you could claim to support something similar to =
EL, and that would be JEXL.

That's not really true.  I use the JSTL EL outside of servlets all the
time.  If you get the standard.jar from the jakarta-taglibs project
you will find the ELEvaluator which uses JSTL style expressions.

the fully qualified name in the jar is
org.apache.taglibs.standard.lang.jstl.ELEvaluator

If you want to claim to support EL you should get that jar.  It may
use commons EL as its underlying implementation, but i don't have a
commons-el jar on my classpath, so I don't think it has any
dependencies.  Some of the taglibs guys could answer that better than
I could.

Michael

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



RE: [EL] Docs ?

2005-06-30 Thread Tim O'Brien
 -Original Message-
 From: Michael Rasmussen [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, June 30, 2005 3:13 PM
 To: commons-user@jakarta.apache.org
 Subject: RE: [EL] Docs ?
 
 So, in other words, you couldn't claim to support EL outside of a =
 servlet environment, but you could claim to support 
 something similar to =
 EL, and that would be JEXL.
 
 That's not really true.  I use the JSTL EL outside of servlets all the
 time.  If you get the standard.jar from the jakarta-taglibs project
 you will find the ELEvaluator which uses JSTL style expressions.
 
 the fully qualified name in the jar is
 org.apache.taglibs.standard.lang.jstl.ELEvaluator
 
 If you want to claim to support EL you should get that jar.  It may
 use commons EL as its underlying implementation, but i don't have a
 commons-el jar on my classpath, so I don't think it has any
 dependencies.  Some of the taglibs guys could answer that better than
 I could.

Yes, but more word mincing, you can't claim to support EL outside of a
JSTL or JSP context because it is an intimate part of those two
specifications.  As of standard-1.1 I believe reliance of PageContext
was removed from ELEvaluator so you can include a JSP taglibrary in your
path if you want to provide support for EL. (But, really you are just
providing support for EL-like syntax.)

BTW, this is another one of those terrible situations where one codebase
seems to have been split long ago, one incarnation lives in commons-el
and another in standard.

Tim

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



Re: [EL] Docs ?

2005-06-30 Thread Michael Rasmussen
Sorry,
  it is not my intention to split hairs here.  I am just saying that
if you want to support the same syntax as the JSTL-EL you will nto be
able to do it with JEXL.  You are however more likely to be able to
continue to support a JSTL syntax, as it evolves, by using the taglibs
project.  JEXL will not accomplish this.  The original posters
requirement was to cater to users who were familiar with the JSTL
syntax.

  Your point about JSTL-EL not existing outside the Servlet container
is well taken, and it deserves to be made clear.  So thank you.

Michael

On 6/30/05, Tim O'Brien [EMAIL PROTECTED] wrote:
  -Original Message-
  From: Michael Rasmussen [mailto:[EMAIL PROTECTED]
  Sent: Thursday, June 30, 2005 3:13 PM
  To: commons-user@jakarta.apache.org
  Subject: RE: [EL] Docs ?
 
  So, in other words, you couldn't claim to support EL outside of a =
  servlet environment, but you could claim to support
  something similar to =
  EL, and that would be JEXL.
 
  That's not really true.  I use the JSTL EL outside of servlets all the
  time.  If you get the standard.jar from the jakarta-taglibs project
  you will find the ELEvaluator which uses JSTL style expressions.
 
  the fully qualified name in the jar is
  org.apache.taglibs.standard.lang.jstl.ELEvaluator
 
  If you want to claim to support EL you should get that jar.  It may
  use commons EL as its underlying implementation, but i don't have a
  commons-el jar on my classpath, so I don't think it has any
  dependencies.  Some of the taglibs guys could answer that better than
  I could.
 
 Yes, but more word mincing, you can't claim to support EL outside of a
 JSTL or JSP context because it is an intimate part of those two
 specifications.  As of standard-1.1 I believe reliance of PageContext
 was removed from ELEvaluator so you can include a JSP taglibrary in your
 path if you want to provide support for EL. (But, really you are just
 providing support for EL-like syntax.)
 
 BTW, this is another one of those terrible situations where one codebase
 seems to have been split long ago, one incarnation lives in commons-el
 and another in standard.
 
 Tim


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



RE: [EL] Docs ?

2005-06-27 Thread Jörg Schaible
Hi Tim,

Tim O'Brien wrote on Sunday, June 26, 2005 1:05 AM:

 EL is meant to be used in a JSP 2.0 environment. 

That's what I wanted to find out for commons-el, wheter it can be used 
standalone or not. I write a component, that others with EL experiance will 
have to use.

 You can get
 everything you need form Commons JEXL.

[snip]

Well, may I cite from the JEXl homepage:

cite
It must be noted that JEXL is not a compatibile implementation of EL as defined 
in JSTL 1.1 (JSR-052) or JSP 2.0 (JSR-152). For a compatible implementation of 
these specifications, see the  Commons EL  project.
/cite

If I release a component that claims to have EL support, any problem with it 
will cause maintenance effort on my side.

- Jörg

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



RE: [EL] Docs ?

2005-06-25 Thread Tim O'Brien
EL is meant to be used in a JSP 2.0 environment.  You can get everything you 
need form Commons JEXL.  

Here is some code for you:

import org.apache.commons.jexl.Expression;
import org.apache.commons.jexl.ExpressionFactory;
import org.apache.commons.jexl.JexlContext;
import org.apache.commons.jexl.JexlHelper;

SomeObject thingy = new SomeObject();
thingy.setFoo( Blah );

String expr = 
JEXL let's you do everything you'd do with EL. ${thingy.foo};

Expression e = ExpressionFactory.createExpression( expr );
JexlContext jc = JexlHelper.createContext( );
jc.getVars( ).put(thingy, thingy);
String message = (String) e.evaluate(jc);

System.out.println( message );


Does that help?


-
Tim O'Brien
[EMAIL PROTECTED]
(847) 863-7045  

 -Original Message-
 From: Jörg Schaible [mailto:[EMAIL PROTECTED] 
 Sent: Friday, June 24, 2005 11:51 AM
 To: Jakarta Commons Users List
 Subject: [EL] Docs ?
 
 Hi folks,
 
 looking at commons-el I wonder, how I can use it in a 
 standalone app. Unfortunately there are no docs how to 
 inialialize anything. In particular, the particularly 
 mensioned package overview does also not contain any 
 addtitional docs, in the repository is no package.html. Also 
 I cannot see any examples.
 
 How to proceed?
 
 - Jörg
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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