Senthil Nathan.s

+ Follow
since Jan 04, 2006
Merit badge: grant badges
For More
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 Senthil Nathan.s

I have one doubt in JAVAbeans from HFSJ book in scriptfree pages chapter.
This question occcurs inbetween the chapter.

Question:<jsp:useBean id="person" type="Foo.Employee">

<jsp:setProperty name="person" property="name" value="fred"/>
Name is :<jsp:getproperty name= "person" property="name"/>

Now what will happen if this jsp page comes after following servlet

i)Foo.Person=new Foo.Employee();

ii) foo.Employee p= new Foo.Employee();

Employee is the concrete class and it inherits Person class.Person is an abstract class.

Now the answer given in the book is
i)will not evaluate because the attribute is in request scope but the useBean tag searches in the page scope.

ii)This works fine.

I can understand the first answer but i expect the same answer for the ii) one also but why does it evaluates fine.Can anyone explain me this.....
I think because simple tags are going to handle the contents of the body as JSP Fragments since scripting is not allowed in JSPFragments it is not allowed in simple tags.But in Classic tags bodycontent object is used to handle the contents so i think JSP is allowed in classic tags.

Please correct me If I am wrong.
please specify the location and the mail id where we should mail the resume
17 years ago
Hai I have one year experience in java.I have done my SCJP last month.Currently I am preparing for SCWCD and I will be cetified by the month of march.I passed my B-tech(ece) from ANNA UNIVERSITY(MADRAS INSTITUTE OF TECHNOLOGY)with 9.2 CGPA.
I am working with TCS for the past one year in mumbai.I am preffering chennai as my work location.I .If there is any requirement please send me a personal mail to

with regards
18 years ago
Hai I am I year experienced in JAVA and passed SCJP with(90%).Currently I am preapring for SCWCD and I will get certified by March.Now i am in Mumbai and I like to work in Chennai.I have an excellent academic record.So if there is any job offerings please send me a personal mail to
18 years ago
Ramesh you please look into the tricky question posted by me.I also have the same doubt and we have a very good explanation over there.
Thanks for your explanation Murali.I understood the concept very well.
In both the cases s is stored on the stack and in the firstcase hello is stored on the string pool and in the second case hello is stored on both the heap and the string pool.
Thanks krishnan for your reply but anyhow the contents of i must be incremented by one know .You mean that the contents of i wont get incremented at all ,is it so.......
int i=10;

I expect the answer to be 12 but the answer is 11.Can anyone explain me how this happens

Thanks and regards