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

Q 1 - Which of the following is not a part of Struts architecture?

A - MDBs

B - Results / Result types

C - Value Stack / OGNL

D - View technologies

Answer : C

Explanation

MDBs are not a part of Struts architecture.

Answer : C

Explanation

Both of the above statements are correct.

Answer : A

Explanation

There are various temporary objects which are created during execution of a page. For example the current iteration value for a collection being looped over in a JSP tag.

Q 4 - What should be the name of xml file used for validation in struts?

A - '[action-class]'-validation.xml

B - validation.xml

C - Both of the above.

D - None of the above.

Answer : A

Explanation

The xml file needs to be named '[action-class]'-validation.xml.

Q 5 - Which of the following theme represents minimal theme with no "bells and whistles".?

A - simple theme

B - xhtml theme

C - css_xhtml theme

D - complex theme.

Answer : A

Explanation

simple theme - A minimal theme with no "bells and whistles". For example, the textfield tag renders the HTML tag without a label, validation, error reporting, or any other formatting or functionality.

Answer : B

Explanation

If you want to use several annotations of the same type, these annotation must be nested within the @Validations() annotation.

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 will allow you to format a Date in a quick and easy way?

A - date tag

B - param tag

C - property tag

D - push tag

Answer : A

Explanation

The date tag will allow you to format a Date in a quick and easy way.

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