Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Question on EL

 
Parvathi G
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which of the following will produce compilation Error .

1. ${1+'1'}
2. ${varDoesntExist+1}
3 ${sessionScope*2}
4. ${2/varDoesntExists}
5. ${varDoesntExists1 <varDoesntExists2}
6. ${!true-!false}

I am thinking 4 and 5 will produce compilation error.
Please correct me if i am wrong.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
3 ${sessionScope*2} should nbot work, because sessionScope is an implicit object

6. ${!true-!false} should not work either.

JSP.2.3.5.1 Binary operators - A {+,-,*} B
� Otherwise coerce both A and B to Long and apply operator
� If operator results in exception, error

The others should be fine
[ January 23, 2006: Message edited by: Satou kurinosuke ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic