• Post Reply Bookmark Topic Watch Topic
  • New Topic

<jsp:useBean> K&B Standard Action Question on page 358.

 
Marcelo DeOliveira
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
page 358 of HeadFirst S&J states:

There is a concrete Employee Class {int getEmp(), void setEmp()} that implements an abstract class Person {String getName(), void setName()}



Question?
What happens if the code below forwards the request to the jsp above?



The answer on page 420 states that it will FAIL at request.
If the Bean exists on the request scope with value "Evan" why does it fail?
I am missing something but I don't know where.
Thanks,

 
chandan kumar mitwaa
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The answer on page 420 states that it will FAIL at request.
If the Bean exists on the request scope with value "Evan" why does it fail?
I am missing something but I don't know where.

I have tried above code but it does not fail. I think you too should try once.
 
Marcelo DeOliveira
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is the answer on the HFSJ2.0 wrong on the book. Is there an errata for it that i missed?
 
Marcelo DeOliveira
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks,
I found the ERRATA for this question:
http://oreilly.com/catalog/errata.csp?isbn=9780596516680
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!