Win a copy of Kotlin for Android App Development this week in the Kotlin forum!

K Bala

+ Follow
since Jul 14, 2005
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by K Bala

I have an ArrayList of Strings like this

"132 8"
"132 12"
"132 4"
"132 19"

When I sort it using Collections.sort() method, I get

132 12
132 19
132 4
132 8

I want the ArrayList to be sorted like this

132 4
132 8
132 12
132 19

How can I achieve this? Please help
11 years ago
EL handles null values in the following ways:

The logical operators treat a null value as false.

The arithmetic operators treat a null value as zero.

If you do division by zero, it returns infinity and does not throw any exception.

Hope this helps. chapter wise exams are really good. Yes, they are for SCWCD 1.3 but the objectives are almost same for SCWCD 1.4.

Something is better than nothing.
Yes, this is correct.

There are 4 mandatory things when u use FORM authentication.

The method must be POST.
The action must be "j_security_check"
The username field must be named "j_username"
The password field must be named "j_password"

Hope this helps.
Frederic, the HFSJ book indeed says "HttpSessionActivationListener must be configured in the DD" but if you check the errata, they have told - You do NOT configure session binding listeners OR SESSION ACTIVATION LISTENERS in the DD!

I will study your notes and submit any corrections that I come across.

You are doing a great job. Thanks so much.

How nice of you to share it with us!
Veena, I don't think I understand your question but I will tell you what this method does.

The setMaxInactiveInterval(int interval) specifies the time, in seconds, between client requests before the servlet container will invalidate this session.


setMaxInactiveInterval(60) invalidates the session after 60 seconds or 1 minute of no client request.

If the interval is set to zero, session is expunged immediately. If the interval is set to any negative value, say -1 or -2, the session never times out.
Fred, the document is great.

Can you please update the "Application Listeners" heading to reflect that both HttpSessionBindingListeners and HttpSessionActivationListeners are not configured in the DD?

[ March 06, 2006: Message edited by: K Bala ]
Thanks so much for sharing your notes with us. It is very good and will be very helpful for us. I am taking my exam this Saturday. I will let you know how it goes.
There is no jsp implicit object that is a reference to the HttpServlet object.

"page" implicit object corresponds to the Object API.

Pls. correct me if I am wrong.

Originally posted by Patrick Williams:
While studying, I am starting to grow a strong dislike towards custom tags and EL as well. Good luck!

OMG! Is that so? I just finished EL and agree that it is a lengthy topic and you have to remember so much stuff. My Next chapter is on Custom Tags and I read here that it is a very important topic for the exam.

I am new to JSP - so I assumed its taking me time to learn the concepts. But looks like its the same experience with many here.

Alright, wish me good luck too!
Congrats, Sunil!

I like your quote.
I am trying to do the exercise given in pg 379 - compose the EL for this output.

When I try to run the code, I am getting java.lang.StackOverflowError. I commented the EL code in my JSP and just put a template text and still got the same error.

What am I doing wrong? Pls. help.

I have the following code.


ELresult.jsp - You can see that I have commented the EL code and just put a template text for testing.



You have to take the SCWCD exam for the J2EE 1.4 version. The exam # is CX310-081.

You can find the exam objectives, books to buy etc in the "Links" Section.
You have to take the SCWCD 1.4 exam - CX310-081.

You can print the exam objectives from sun's website.

I am using the book "Head First Servlets & JSP" written by Kathy Sierra, Bert Bates and Bryan Basham. I have not read any other book for Servlets & JSP yet, so I cannot recommend/comment on any other book.

The HFSJ book is good. I like it very much. You can buy it for less than US $30 at for free shipping).

You just have to concentrate and study deeply. You should also have the "Servlet & JSP" API and specs and use them for exam preparation.

The exam covers the following specs:

Servlets 2.4
JSP 2.0
JSTL 1.1

You can find the links to download these in the SCWCD Links section.

Hope this helps. Good Luck!

[ January 13, 2006: Message edited by: K Bala ]
[ January 13, 2006: Message edited by: K Bala ]