Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using EL in non-JSP code

 
Alok Pota
Ranch Hand
Posts: 185
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can the EL (expression language) that ships with JSP 2.0 and JSTL be used
in non-JSP context, like in a regular Java class?
 
Kishore Dandu
Ranch Hand
Posts: 1934
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can not answer that specific question.
Can you explain why you want to do that.
But, I have one comment for you.
Nice book(your .net for java developers).
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64843
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Only if it is passed an instance of a JspContext or PageContext, since you need this context to obtain an instance of javax.servlet.jsp.el.ExpressionEvaluator.
Of course, you could always implement your own concrete classes for the abstract classes and interfaces in javax.servlet.jsp.el and roll your own.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic