Tuesday, October 30, 2007

Odd JSP EL behaviour

I just discovered an oddity in JSP Expression Language. I'm a huge fan of EL and its many uses. This is hardly a problem, but is something to keep in mind because it is an unexpected behavior.

Take:

int a = 5;
int b = 2;

System.out.println(a / b);

The println statement will output 2. Thus in EL (and JSTL) in a JSP you would expect the same integer division behavior from the following:

<var="a" value="5" />
<var="b" value="2" />

${a / b}


In the above, ${a / b} yields 2.5, behaving like floating point division rather than integer division. I can see this having its uses, but it surprised me, especially since I've been working almost exclusively in Java web technologies for the past few years. For future purposes I created an EL function so I can just call the following when I want to force integer division (where f is whatever prefix is specified for the custom taglib):

${f:integerDivision(a,b)}

105 comments:

SEO Manchester said...

I think I am quite anxious about this technical meeting and I want to know the feedback of this meeting.I am sure it will be an extremely informative one and all those will attend it will be quite beneficial.

Timber Merchants Liverpool said...

You can't really say what is beautiful about a place, but the image of the place will remain vividly with you.

Roller Shutters said...

It is a very profitable post for me. I've enjoyed reading the post. It is very informative and useful post. I would like to visit the post once more its valuable content.

Online Pharmacy said...

You can't really say what is beautiful about a place, but the image of the place will remain vividly with you.

Cerrajeros en Barcelona said...

Thanks for taking the time to discuss this, I feel strongly about it and love learning more on this topic. If possible, as you gain expertise, would you mind updating your blog with more information? It is extremely helpful for me.

paul sam said...

It took us three years to build the NeXT computer. If we'd given customers what they said they wanted, we'd have built a computer they'd have been happy with a year after we spoke to them - not something they'd want now.
Buy Sleeping Pills

Fashion Shoes said...

We live in a wonderful world that is full of beauty, charm and adventure. There is no end to the adventures that we can have if only we seek them with our eyes open.

Glass Curtains Marbella said...

The deployment type you mentioned is quite interesting. While using the codes, I always lack sufficient confidence. But when it comes to rewriting the algorithm, I do it well. I am totally gonna purchase this application. Great post folks!

Buy Sleeping Tablets Online said...

The connections that you make early in your career will take you far. After 20 years it is still true for me. This has been true regarding companies I worked for and those I worked with. All you have written is excellent advice.

mical clark said...

That's been one of my mantras - focus and simplicity. Simple can be harder than complex: You have to work hard to get your thinking clean to make it simple. But it's worth it in the end because once you get there, you can move mountains.
Sleeping Tablets Online

Cialis Online said...

We want to reinvent the phone. What's the killer app? The killer app is making calls! It's amazing how hard it is to make calls on most phones. We want to let you use contacts like never before - sync your iPhone with your PC or mac.

Art Classes Manchester said...

The real sin against life is to abuse and destroy beauty, even one's own even more, one's own, for that has been put in our care and we are responsible for its well-being.

Buy Zyban Online said...

I think I am quite anxious about this technical meeting and I want to know the feedback of this meeting.I am sure it will be an extremely informative one and all those will attend it will be quite beneficial.

Buy Provigil said...

You can only perceive real beauty in a person as they get older.

Anonymous said...

Thank you for this post. Thats all I are able to say. You most absolutely have built this blog website into something speciel. You clearly know what you are working on, youve insured so many corners.thanks

Buy Diazepam said...

Thank you for this post. Thats all I are able to say. You most absolutely have built this blog website into something speciel. You clearly know what you are working on, youve insured so many corners.thanks

mical clark said...

Older people sit down and ask, 'What is it?' but the boy asks, 'What can I do with it?'.
Valium Online

Buy Zopiclone Online said...

Nice post and right to the point. I am not sure if this is actually the best place to ask but do you folks have any ideea where to hire some professional writers? Thanks in advance 

Buy Zopiclone said...

Very Useful information, this is both good reading for, have quite a few good key points and I learn some new stuff from it too.

Zopiclone Online said...

It is a very profitable post for me. I've enjoyed reading the post. It is very informative and useful post. I would like to visit the post once more its valuable content.

Buy Lorazepam Online said...

There is no question that instantaneous water heaters are good options to trust in terms of their water heating services. However, you need to know that not all kinds of this water heater will work best for you.

mical clark said...

The difference between a successful person and others is not a lack of strength, not a lack of knowledge, but rather a lack of will.
Car Accident Lawyers Barrie
tholatf

mical clark said...

You can't connect the dots looking forward; you can only connect them looking backwards. So you have to trust that the dots will somehow connect in your future. You have to trust in something - your gut, destiny, life, karma, whatever. This approach has never let me down, and it has made all the difference in my life.
Personal injury lawyer Etobicoke

mical clark said...

When you're a carpenter making a beautiful chest of drawers, you're not going to use a piece of plywood on the back, even though it faces the wall and nobody will ever see it. You'll know it's there, so you're going to use a beautiful piece of wood on the back.
Accident Lawyer Mississauga

buy valium online said...

I think I am quite anxious about this technical meeting and I want to know the feedback of this meeting.I am sure it will be an extremely informative one and all those will attend it will be quite beneficial.

mical clark said...

Design is not just what it looks like and feels like. Design is how it works.
agyevents

Buy Ultram Online said...

I like your all activities because children who participating in these activities will surely learn the necessary thing which helps to live healthy.

Koop Slaaptabletten said...

Very Useful information, this is both good reading for, have quite a few good key points and I learn some new stuff from it too.

Slaaptabletten kopen op Internet said...

The real sin against life is to abuse and destroy beauty, even one's own even more, one's own, for that has been put in our care and we are responsible for its well-being.

buy valium said...

It is a very profitable post for me. I've enjoyed reading the post. It is very informative and useful post. I would like to visit the post once more its valuable content.

buy valium online cheap said...

It is a very profitable post for me. I've enjoyed reading the post. It is very informative and useful post. I would like to visit the post once more its valuable content.

how to order valium online said...

I admire the valuable advice you make available in your expertly written content. I want to thank you for this informative read; I really appreciate sharing this great.

jhoney said...

valium for sale online
Thank you for this post. Thats all I are able to say. You most absolutely have built this blog website into something speciel. You clearly know what you are working on, youve insured so many corners.thanks

valium on line said...

When virtue and modesty enlighten her charms, the lustre of a beautiful woman is brighter than the stars of heaven, and the influence of her power it is in vain to resist.

valium online buy said...

This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion.

kiranjee17 said...

A lot of companies have chosen to downsize, and maybe that was the right thing for them. We chose a different path. Our belief was that if we kept putting great products in front of customers, they would continue to open their wallets.
location villa toscane

buy real diazepam said...

Nice post and right to the point. I am not sure if this is actually the best place to ask but do you folks have any ideea where to hire some professional writers? Thanks in advance 

Anonymous said...

Wow!! What a great writing, really I appreciate such kind of topics. I am very happy to get this post and comment here.

Kiran Jee said...

Keep up the good work , I read few posts on this web site and I conceive that your blog is very interesting and has sets of fantastic information.
own online casino

where can I buy diazepam online said...

Thanks for the facts. You supplied meals for believed. Thanks for sharing the data. All of the best to you.

Regalos Originales said...

Thank you for this post. Thats all I are able to say. You most absolutely have built this blog website into something speciel. You clearly know what you are working on, youve insured so many corners.thanks

jhoney said...

I think I am quite anxious about this technical meeting and I want to know the feedback of this meeting.I am sure it will be an extremely informative one and all those will attend it will be quite beneficial.
HayCompras

Rebajas said...

Productos hasta 85% de Descuento. Envío en 24-48h. Productos de Cocina, Electrónica y Electrodomésticos, Hogar, Perfumes y Cosmética, Regalos, Salud y Belleza, Fitness y Deportes

Regalos said...

Productos hasta 85% de Descuento. Envío en 24-48h. Productos de Cocina, Electrónica y Electrodomésticos, Hogar, Perfumes y Cosmética, Regalos, Salud y Belleza, Fitness y Deportes

mical3211 said...

Productos hasta 85% de Descuento. Envío en 24-48h. Productos de Cocina, Electrónica y Electrodomésticos, Hogar, Perfumes y Cosmética, Regalos, Salud y Belleza, Fitness y Deportes
Rebajas Online

Tayyba Batool said...

zolpidem online
Ive been meaning to read this and just never acquired a chance. Its an issue that Im very interested in, I just started reading and Im glad I did. Youre a good blogger, one of the finest that Ive seen. This blog absolutely has some details on topic that I just wasnt aware of. Thanks for bringing this things to light.

jhoney said...

We want to reinvent the phone. What's the killer app? The killer app is making calls! It's amazing how hard it is to make calls on most phones. We want to let you use contacts like never before - sync your iPhone with your PC or mac.
Buy Facebook Fans

Tayyba Batool said...

Education aims to give you a boost up the ladder of knowledge. Too often, it just gives you a cramp on one of its rungs. You Can Visit us to
zopiclone online

Tayyba Batool said...

Other than the sightings and testimonials, there have been many circumstances of human beings who were kidnapped by aliens from their spaceships.
Buy Sleeping Tablets Online

mical3211 said...

Some good benefits associated with EPOC will be the raised using energy after exercise along with surplus fat stores/fatty acids tend to be oxidized to become energy. With less complicated phrases to understand, your program begins removing fats to make use of.
Buy Sleeping Tablets

mical3211 said...

Ladies and Gentlemen, allow me to pay tribute to our exhibitors, from as far as Mauritius and our neighbours South Africa, for gracing this event.
Buy Facebook Likes

Lan Linh said...

Great! Thanks for sharing the information. That is very helpful for increasing my knowledge in this field.
pacman
happy wheels
my little pony games
hulk games
mickey mouse games
car games
bike games
fun games

mical3211 said...

When someone writes an piece of writing he/she maintains the image of a user in his/her mind that how a user can know it. So thats why this paragraph is great. Thanks!
Buy Facebook Likes

buy ativan online said...

What is success? I think it is a mixture of having a flair for the thing that you are doing; knowing that it is not enough, that you have got to have hard work and a certain sense of purpose.

kiranjee17 said...

stilnox where to buy
This is a nice post in an interesting line of content.Thanks for sharing this article, great way of bring this topic to discussion.

shams jee said...

Thanks you very much for sharing these links. Will definitely check this out..
fashion shows

happy wheels said...

Thank you very much for your post, it makes us have more and more discs in our life, So kind for you, I also hope you will make more and more excellent post and let’s more and more talk, thank you very much, dear.
happy wheels| friv|monster high| shooting games| tetris| 8 ball pool
cool math games| barbie games| friv4school| agario| fighting games

fairy Jee said...

Oh, this is a magical post. It’s life the most majestic post there is on this planet right now. This is really good work from your side. I strongly recommend you keep doing this kind of work.
buy stilnoct online with no prescription

jhoney said...

rn pins
Spot on with this write-up, I actually believe that this web site needs a great deal more attention. Ill probably be back again to read more, thanks for the information!

Phoebe Vuong said...

Thank you so much for this article. I've been looking for it :) It will helps me much. I hope to see more and more posts of yours in the future :)
happy wheels unblocked | starcraft | starcraft html5 | starcraft online | starcraft web | happy wheels unblocked | happy wheels demo | car games | car games for kids

Bao An said...

I am very happy to discover your post as it will become on top in my collection of favorite blogs to visit.
Friv 4
Friv 5
Friv 100
Happy Wheels

hhaniya said...

floral mehndi collection
Useful information.I am actual blessed to read this article.thanks for giving us this advantageous information.I acknowledge this post.and I would like bookmark this post.Thanks

kiranjee17 said...

I've found this very interesting and has a good stuff for the readers and designers. I would be glad to recommend the post for its quality content. Nice post.
floral mehndi collection

Hieu Nguyen said...

When you see the stress in work, life, friv could well be a good site to try.
Thanks you for sharing
Friv Games, Friv Online, Friv.com, Friv

hhaniya said...

attractive mehndi designs
You must know by now, your article goes to the nitty-gritty of the subject. Your clarity leaves me wanting to know more. Just so you know, i will immediately grab your feed to keep up to date with your online blog. Sounding Out thanks is simply my little

Love KidsTV said...

Thanks for your post. Click to play Plants vs Zombies , Solitaire,Tom And Jerry Games, Brain Games, Happy Wheels , Five Nights At Freddy's

Love KidsTV said...

Truyen ngon tinh hay la the loai truyen tinh cam
Truyen teen hay la nhung truyen tinh yeu tuoi teen
Don doc tai trang doc truyen online.

sewa mobil surabaya said...

been accurate apropos companies I formed for and those I formed with. All you accept accounting is accompl

Kungfukangda said...

Thank you for giving posts and articles were very amazing. I really liked as a part of the article. With a nice and interesting topics.
Friv 1000

Friv Games said...

Play free Friv games flash online games flash.
Thanks you for sharing
Friv Games | Friv Online

El Taufan said...

Thanks for Sharing That... Sucses for You

findaunionprinter

findaunionprinter

getoifile

getdriversforpc

offlineinstallerfilehippo

theprinterdriver

esoftpedia

filehorse

thesoftpedia

caranddriver

Anonymous said...

Nice read. Very good post for fun and some time pass. Thanks for sharing.
Kizi 2
Friv 2

Yepi 4 said...

You need to kill time, you need entertainment. Refer to our website. hope you get the most comfort.
Thanks you for sharing!
Friv
Friv Games
Yepi 4
Kizi 4

Friv 10 said...

you'd have time to look these kids active. Please visit our website and let us play the game interesting.
Thanks for sharing !
Friv 10
Kizi 10
Yepi 2

Mai Lân said...

I just want to say : why you do not click to play
puzzle games | mario games | brain games | tetris | happy wheels | agario | super mario | abcya | happy wheels the game free | happy wheels

Friv5 said...

You need to kill time, you'd have time to look these kids active. Refer to our website. Hope you get the most comfort.
Thanks for sharing !
Friv 5
Kizi 1
Yepi 3

agario games said...

I just want to say : why you do not click to play
brain games | puzzle games | tetris | happy wheels | agario | abcya | fnaf 4 | super mario games

Le Bens said...

I would very much like to agree with the previous commenter! I find this blog really useful for my uni project. I hope to add more useful posts later.
Friv
Kizi 4
Friv Games

ane semprul said...

I like the post format as you create user engagement in the complete article. It seems round up of all published posts. Thanks for gauging the informative posts.
obat aborsi
cara menggugurkan kandungan
obat telat datang bulan
obat penggugur kandungan
cara menggugurkan kandungan

Kelly Anni said...

I want you to thank for your time of this wonderful read!!! I definately enjoy every little bit of it and I have you bookmarked to check out new stuff of your blog a must read blog!
Science Kombat | Science Kombat Game | slither io | wings io | wingsio | Tank trouble | Tank trouble 2 | Tank trouble 3 | Tank trouble 4

Kizi200 said...

Play the Best Free Games! We've picked out the racing games, cooking games, candy crush, games shooting, fashion games, ...
Thanks for sharing !
Kizi 200
Friv 1
Y88
Y9

Lopez Alexander said...

This content is written very well. Your use of formatting when making your points makes your observations very clear and easy to understand. Thank you.
- usps tracking
- iphone 7 release date
- excel

Five Nights At Freddy's said...

Thanks for giving me the useful information. I think I need it!
Happy Wheels , FNAF World , Five Nights At Freddy's

Ka Sa said...

Beautiful post just there, and i've bookmarked this blog too & keep up the great job.
Friv
Friv

Anonymous said...

Please visit our website and play exciting games,thank you verry much
Friv 2|
Friv 1000|
HappyWheels

lee anh nuooi said...

invites you to play games for a chance to win cars Corolla Altis car


Friv Games
Kizi 100
Games2Win
Kizi 5

xjd7410@gmail.com said...

insanity workout
louis vuitton outlet stores
adidas originals
michael kors outlet
coach factory outlet
replica watches
toms shoes
gucci handbags
louis vuitton handbags
coach outlet store online
timberland outlet
louis vuitton handbags
kate spade outlet
oakley sunglasses
oakley sunglasses
cheap jordans
oakley vault
burberry bags
air jordans
coach outlet store online clearances
beats solo 2
lebron james shoes
coach outlet store online
tory burch outlet
adidas ultra boost
cheap ray ban sunglasses
hollister shirts
ralph lauren polo
coach outlet store online clearances
chenyingying20160806

xjd7410@gmail.com said...

polo ralph lauren
true religion outlet
burberry outlet
nfl jerseys wholesale
kobe bryant shoes
coach factory outlet
kobe 10 shoes
vans shoes sale
true religion jeans sale
instyler max
oakley sunglasses
gucci belts
michael kors outlet clearance
louis vuitton outlet
jordan 11 concord
coach outlet online
toms outlet
toms shoes
jordan 3 white cenment
kevin durant shoes 7
jordan retro
polo outlet
gucci outlet
cheap air jordans
jordan 4 toro
coach outlet
ray ban sunglasses
jordan 3
gucci handbags
chenyingying20160806

Friv100 said...

You want to relax after a stressful working hours. Refer to our website. hope you get the most comfort.
Thanks for sharing !
Friv 100
Friv 8
Friv 2

huong duong said...

Today I will send the music lover a gift, I believe you will love it. Try it and send me a comment
baixar musicas gratis , baixar musicas , baixar musicas gratis

huong duong said...

You have seen the usual boring chat with friends through social networks yet? If you got bored then try this one, a friend recently introduced me. It was really fun
snapchat , snapchat baixar , baixar snapchat , snapchat download , download snapchat

hường lê said...

Such a very useful article. Very interesting to read this article.I would like to thank you for the efforts you had made for writing this awesome article.

Discover our website bounty of free online games now!
Our website has the biggest collection of free online games. Totally new games are added every day!

age of war 2
gold Miner 2
unfair Mario 2
cubefield 2
tanki Online 2

Friv 1000 said...

Please visit top best include online funny for kid. Top Flsh 3D, 4D, 5D Juegos 2017.
Kizi 1000 | Kizi | Y8 Dress Up | Friv yoob | Twizl

Alice Denny said...

The blog or and best that is extremely useful to keep I can share the ideas. Age Of War 2
Big Farm | Slitherio | Tank Trouble
Of the future as this is really what I was looking for, I am very comfortable and pleased to come here. Thank you very much.
Happy Wheels | Goodgeme Empire | Slither.io


94 hằng said...

You need to have time to take care of the active. It in fact was a amusement account it. Look advanced to far added agreeable from you.
banana kong ,
banana kong baixar ,
baixar banana kong ,
download banana kong ,
banana kong

94 hằng said...

Life becomes more interesting and wonderful when you share your memorable moments with friends and family through unique photographs. You can create your own unique style impressed with image editing software. And after hours of work stress you can also
dr driving, dr driving baixar ,download dr driving, dr driving

94 hằng said...

Mostly people have all the same things when they are writing academic task or any other writing, especially light music most people like during the writing.
dream league soccer download , dream league soccer apk , download dream league soccer , dream league soccer

angelina jolie said...

I’m glad you enjoyed it. Those are great habits! Thank you for sharing.
Y8Y8Y8

cara menggugurkan kandungan said...

It's actually a great and helpful piece of information. I am satisfied that you just shared this useful information for us.
Thanks for sharing.
obat aborsi
obat penggugur kandungan
obat aborsi
obat penggugur kandungan
tanda tanda kehamilan
cara menggugurkan kandungan

starfall said...

Thanks for sharing the information. It is very useful for my future. keep sharing
barney | abcya

Viagra asli said...


good ...?????
Vimax
Viagra
Obat Kuat
Obat Pembesar Penis
Klg

Malia Obama said...

Thanks for the sharing of such information we will pass it on to our readers.
Friv.com
Friv
Friv Online

Latest Vehicle Review said...

nice post

Vehicle News
Vehicle Notify
Vehicle Blog
Future Vehicle News

Janvi said...

Welcome, your blog is great. It's very interesting and meaningful
Kizi 1
Kizi
Gahe

minecraft said...

Very nice. Posts shared useful information and meaningful life, I'm glad to be reading this article and hope to soon learn the next article. thank you
minecraft
a10 games
g9g games
4223 games
yoob games
hopy games
huz 10 games
kizi hot
kizi new games
yepi games