Struts2 Online Quiz



Following quiz provides Multiple Choice Questions (MCQs) related to Struts2 Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Answer : A

Explanation

Model - The lowest level of the pattern which is responsible for maintaining data.

Answer : A

Explanation

The dispatcher result type is the default type and is used if no other result type is specified.

Answer : C

Explanation

It calls the standard response.sendRedirect() method, causing the browser to create a new request to the given location.

Q 5 - Which class of struts is responsible to converts data types from string?

A - StrutsTypeConverter

B - StringTypeConverter

C - Both of the above.

D - None of the above.

Answer : A

Explanation

StrutsTypeConverter class tells Struts how to convert Environment to a String and vice versa by overriding two methods convertFromString() and convertToString().

Answer : A

Explanation

This annotation sets the CreateIfNull for type conversion. The CreateIfNull annotation must be applied at field or method level.

Answer : D

Explanation

This annotation sets the KeyProperty for type conversion. The KeyProperty annotation must be applied at field or method level.

Q 9 - Which of the following tag is used to push value on stack for simplified usage?

A - date tag

B - param tag

C - property tag

D - push tag

Answer : D

Explanation

The push tag is used to push value on stack for simplified usage.

Q 10 - The web.xml configuration file is a J2EE configuration file that determines how elements of the HTTP request are processed by the servlet container.

A - false

B - true

Answer : B

Explanation

The web.xml configuration file is a J2EE configuration file that determines how elements of the HTTP request are processed by the servlet container.

struts_questions_answers.htm
Advertisements