Deck 4: Java, Servlets, JSP and EJB

Full screen (f)
exit full mode
Question
Which attribute is used to hold the Java Script Version?

A) SCRIPT
B) VERSION
C) LANGUAGE
D) VER
Use Space or
up arrow
down arrow
to flip the card.
Question
JavaScript RegExp Object has modifier 'i' to __________

A) Perform case-sensitive matching
B) Perform case-insensitive matching
C) Perform both case-sensitive&case-insensitive matching
D) None of above
Question
How many ServletContext objects are available for an entire web application?

A) One each per servlet
B) One each per request
C) One each per response
D) Only one
Question
Which of the following delegates the request handling to the RequestProcessor instance?

A) ActionServlet
B) Action class
C) Deployment descriptor
D) None of the above
Question
How many instances can be created per application module by the RequestProcessor class?

A) Four
B) Three
C) One
D) Uncountable instances
Question
An instance of Action is invoked by

A) ActionServlet
B) ActionListener
C) RequestProcessor
D) All of the above
Question
Application module selection is done by

A) Action class
B) ActionServlet
C) RequestProcessor
D) All of the above
Question
Which of the following methods is overridden by Action class?

A) execute()
B) service()
C) run()
D) destroy()
Question
Which of the following should always forwards or redirect to a resource (view) after completed?

A) HttpResponse object
B) ActionServlet
C) Action class
D) Request Processor
Question
Which of the following acts as a bridge between user-invoked URI and a business method?

A) HttpRequest
B) Action class
C) ActionServlet
D) RequestProcessor
Question
Struts framework

A) should always decouple the application from a specific model implementation
B) provides model components
C) does not support JavaBeans and EJB
D) has built-in support for the model
Question
Which of the following tags in struts-config. xml file defines the availability of necessary Struts JSP custom tag libraries?

A) < jsp-lib>
B) < struts-taglib>
C) < taglib>
D) < jsp-taglib>
Question
Which can generate HTML dynamically on the client but can hardly interact with the web server to perform complex tasks like database access and image processing etc. in JSP?

A) vs. Static HTML
B) vs. Server-Side Includes
C) vs. Pure Servlets
D) Vs. JavaScript
Question
Which attribute specifies a JSP page that should process any exceptions thrown but not caught in the current page?

A) The ErrorPage Attribute
B) The IsErrorPage Attribute
C) Both A & B
D) None of the above
Question
What technique is used for the authentication mechanism in the servlet specification?

A) Role Based Authentication
B) Form Based Authentication
C) Both A & B
D) None of the above
Question
In JSP Action tags which tags are used for bean development?

A) jsp:useBean
B) jsp:setPoperty
C) jsp:getProperty
D) All mentioned above
Question
Which two interfaces does the javax. servlet. jsp package have?

A) JspPage
B) HttpJspPage
C) PageContext
D) Both A & B
Question
Which of the following is an advantage of the statement - Separation of business logic from JSP?

A) Custom Tags in JSP
B) JSP Standard Tag Library
C) All the above
D) None of the above
Question
JSPs eventually are compiled into Java servlets, you can do as much with JSPs as you can do with Java servlets.

A) True
B) False
C) none
D) all
Question
How many jsp implicit objects are there and these objects are created by the web container that are available to all the jsp pages?

A) 8
B) 9
C) 10
D) 7
Question
JavaServer Pages often serve the same purpose as programs implemented using the Common Gateway Interface (CGI)

A) True
B) False
C) none
D) all
Question
Which action tags are used in JSP for developing web application with Java Bean?

A) jsp:useBean
B) jsp:setProperty
C) jsp:getProperty
D) Both B & C
Question
Which statement correctly identifies the goals of the designers of the EJB architecture?

A) The EJB architecture requires that users be aware of the low-level transaction details of the Java EE platform.
B) The EJB architecture is the standard component architecture for building distributed business applications in the Java programming language. ()
C) Although the EJB architecture defines the contracts that enable tools to develop and deploy components, each application server vendor must produce its own set of additional tooling.
D) The EJB architecture provides a standard way of persisting state data using the Java Persistence API, Java Data Objects, and JDBC.
Question
Which statement about life-cycle callback methods is correct?

A) Life-cycle callback methods must be implemented in the bean class.
B) Life-cycle callback methods can have public, private, protected, or packagelevel access. ()
C) A life-cycle callback method can only have a single callback annotation. In other words, you cannot define a single method and give it two different callback annotations.
D) Life-cycle callback methods can be declared as static.
Question
Which of the following types of Enterprise Java Bean will be most likely to be difficult to port from one App Server to another?

A) Stateful Session Beans
B) Stateless Session Bean
C) BMP (Bean Managed Persistence) Entity Bean
D) CMP (Container Managed Persistence) Entity Bean
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/25
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 4: Java, Servlets, JSP and EJB
1
Which attribute is used to hold the Java Script Version?

A) SCRIPT
B) VERSION
C) LANGUAGE
D) VER
LANGUAGE
2
JavaScript RegExp Object has modifier 'i' to __________

A) Perform case-sensitive matching
B) Perform case-insensitive matching
C) Perform both case-sensitive&case-insensitive matching
D) None of above
Perform case-insensitive matching
3
How many ServletContext objects are available for an entire web application?

A) One each per servlet
B) One each per request
C) One each per response
D) Only one
Only one
4
Which of the following delegates the request handling to the RequestProcessor instance?

A) ActionServlet
B) Action class
C) Deployment descriptor
D) None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
5
How many instances can be created per application module by the RequestProcessor class?

A) Four
B) Three
C) One
D) Uncountable instances
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
6
An instance of Action is invoked by

A) ActionServlet
B) ActionListener
C) RequestProcessor
D) All of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
7
Application module selection is done by

A) Action class
B) ActionServlet
C) RequestProcessor
D) All of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
8
Which of the following methods is overridden by Action class?

A) execute()
B) service()
C) run()
D) destroy()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
9
Which of the following should always forwards or redirect to a resource (view) after completed?

A) HttpResponse object
B) ActionServlet
C) Action class
D) Request Processor
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
10
Which of the following acts as a bridge between user-invoked URI and a business method?

A) HttpRequest
B) Action class
C) ActionServlet
D) RequestProcessor
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
11
Struts framework

A) should always decouple the application from a specific model implementation
B) provides model components
C) does not support JavaBeans and EJB
D) has built-in support for the model
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
12
Which of the following tags in struts-config. xml file defines the availability of necessary Struts JSP custom tag libraries?

A) < jsp-lib>
B) < struts-taglib>
C) < taglib>
D) < jsp-taglib>
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
13
Which can generate HTML dynamically on the client but can hardly interact with the web server to perform complex tasks like database access and image processing etc. in JSP?

A) vs. Static HTML
B) vs. Server-Side Includes
C) vs. Pure Servlets
D) Vs. JavaScript
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
14
Which attribute specifies a JSP page that should process any exceptions thrown but not caught in the current page?

A) The ErrorPage Attribute
B) The IsErrorPage Attribute
C) Both A & B
D) None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
15
What technique is used for the authentication mechanism in the servlet specification?

A) Role Based Authentication
B) Form Based Authentication
C) Both A & B
D) None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
16
In JSP Action tags which tags are used for bean development?

A) jsp:useBean
B) jsp:setPoperty
C) jsp:getProperty
D) All mentioned above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
17
Which two interfaces does the javax. servlet. jsp package have?

A) JspPage
B) HttpJspPage
C) PageContext
D) Both A & B
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
18
Which of the following is an advantage of the statement - Separation of business logic from JSP?

A) Custom Tags in JSP
B) JSP Standard Tag Library
C) All the above
D) None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
19
JSPs eventually are compiled into Java servlets, you can do as much with JSPs as you can do with Java servlets.

A) True
B) False
C) none
D) all
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
20
How many jsp implicit objects are there and these objects are created by the web container that are available to all the jsp pages?

A) 8
B) 9
C) 10
D) 7
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
21
JavaServer Pages often serve the same purpose as programs implemented using the Common Gateway Interface (CGI)

A) True
B) False
C) none
D) all
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
22
Which action tags are used in JSP for developing web application with Java Bean?

A) jsp:useBean
B) jsp:setProperty
C) jsp:getProperty
D) Both B & C
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
23
Which statement correctly identifies the goals of the designers of the EJB architecture?

A) The EJB architecture requires that users be aware of the low-level transaction details of the Java EE platform.
B) The EJB architecture is the standard component architecture for building distributed business applications in the Java programming language. ()
C) Although the EJB architecture defines the contracts that enable tools to develop and deploy components, each application server vendor must produce its own set of additional tooling.
D) The EJB architecture provides a standard way of persisting state data using the Java Persistence API, Java Data Objects, and JDBC.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
24
Which statement about life-cycle callback methods is correct?

A) Life-cycle callback methods must be implemented in the bean class.
B) Life-cycle callback methods can have public, private, protected, or packagelevel access. ()
C) A life-cycle callback method can only have a single callback annotation. In other words, you cannot define a single method and give it two different callback annotations.
D) Life-cycle callback methods can be declared as static.
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
25
Which of the following types of Enterprise Java Bean will be most likely to be difficult to port from one App Server to another?

A) Stateful Session Beans
B) Stateless Session Bean
C) BMP (Bean Managed Persistence) Entity Bean
D) CMP (Container Managed Persistence) Entity Bean
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 25 flashcards in this deck.