File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes HFSJ Chapter 11 mock  Q 8  doubt Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Reply Bookmark "HFSJ Chapter 11 mock  Q 8  doubt " Watch "HFSJ Chapter 11 mock  Q 8  doubt " New topic
Author

HFSJ Chapter 11 mock Q 8 doubt

Reshma Shanbhag
Ranch Hand

Joined: Sep 17, 2002
Posts: 202
Hi,

Which statemets about the <init-param> DD elements are true?

a.) They are used to declare initialization parameters for a specific servlet.

b.) They are used to declare initialization parameters for entire web app.

c.) The method that retrives these parameters returns an object.

d.)The method that retrives these parameters takes a String.

Given answers are A & D

Why is C not considered correct???as it says returns an object and not returns Object, String is object .... cant it be thought of this way .. ??


It would be helpful if one of you could help.

Thanks,
Reshma


SCJP 1.4, SCWCD 1.4
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14669
    
  11

c would be right if they'd say :
c.) The method that retrives these parameters returns a String.

You're being picky here


[My Blog]
All roads lead to JavaRanch
Harpreet Hira
Ranch Hand

Joined: Sep 27, 2001
Posts: 72
java.lang.String getInitParameter(java.lang.String name)
Returns a String containing the value of the named initialization parameter, or null if the parameter does not exist.
Bookmark this API
Reshma Shanbhag
Ranch Hand

Joined: Sep 17, 2002
Posts: 202
Yes i know that getInitParameters(String) returns a String, my intension of asking this question was to know how to analyze the options.
ludoviko azuaje
Ranch Hand

Joined: Jun 07, 2005
Posts: 46
i guess it is a typo error:

it should be:

c.) The method that retrives these parameters returns an Object.

bye.


SCJP 1.4, SCJP 5.0, SCWCD 1.4, Oracle SQL Expert Exam 1Z0-047
IBM Test 255, IBM Test 730, IBM Test 142, ScrumManager® Certified.
Selvaraj Subramanian
Ranch Hand

Joined: Jul 15, 2005
Posts: 37
Yes, check errata...

www.oreilly.com/catalog/headservletsjsp/errata/


Selvaraj.S<br />SCJP 1.4 -83%<br />SCWCD 1.4 - 85%<br />SCEA 4 Part 1(310-051) - 89%
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: HFSJ Chapter 11 mock Q 8 doubt
 
Similar Threads
HFSJ - Web App Deployment - Question 8 (Page 613)
mock question regarding dynamic attribute
JSP Init Parameter - Answer Reqd.
How do you pre initialize servlets in a webcontainer?
Static Variables Compilation