Deck 6: JSP, EJB, and JMS

ملء الشاشة (f)
exit full mode
سؤال
Which of the following is not an implicit object in JSP?
I. Request.
II. Session.
III. Vector.
IV. In.

A) Both (I) and (II) above
B) Both (II) and (III) above
C) Both (I) and (III) above
D) Both (III) and (IV) above.
استخدم زر المسافة أو
up arrow
down arrow
لقلب البطاقة.
سؤال
Which is not a valid scope for Java bean in JSP?

A) Page
B) Session
C) Request
D) Global.
سؤال
Which two of the following is responsible to creates ejb-jar files?
1) The bean provider.
2) The application assembler.
3) The deployer.
4) The system administrator.

A) 1 and 2
B) 2 and 3
C) 3 and 4
D) 4 and 1
سؤال
Which two of the following must be included in every ejb-jar file?
1) Stubs for the EJBHome and EJBObject interface.
2) The JAR Manifest file.
3) A deployment descriptor.
4) The JNDI context.
5) The EJB's home interface.

A) 1 and 3
B) 2 and 5
C) 3 and 5
D) 4 and 2
سؤال
Which statement about session beans is true?

A) In both stateless and statefull session classes, the bean provider must write the method public void remove()
B) The method << remove >> in the component interface can be accessed only by the remote clients
C) The bean's handle must be provided by the client, in order to ask the EJBHome for removing a session bean
D) None of the above
سؤال
Which of the following can be directly invoked by the client?

A) ejbPassivate
B) business methods
C) setSessionContext
D) newInstance
سؤال
Which is the method available in SessionContext interface?

A) afterBegin()
B) getRollbackOnly()
C) setSessionCotext()
D) getUserTransaction()
سؤال
Which statements about a session bean class are true?

A) It is a final class
B) Overloaded constructors are supported
C) Their business methods can be 'private'
D) The ejbCreate() method must not be a final method
سؤال
Upon invoking getRollbackOnly() method by a business method in an entity bean, which transaction attribute settings will lead the ejb container to throw an exception?

A) Required
B) RequiresNew
C) Never
D) Mandatory
سؤال
When a session bean has container-managed demarcation value of 'Supports', which three methods run in an unspecified transaction context?
1) ejbActivate
2) getRollbackOnly
3) getUserTransaction
4) ejbRemove
5) afterBegin
6) afterCompletion

A) 1,4,3
B) 4,2,6
C) 1,4,6
D) 2,5,6
سؤال
EJB system's performance tuning is the responsibility of

A) Bean Provider
B) EJB Deployer
C) Application Assembler
D) Tool Vendor
سؤال
The EJB Transaction Attribute that ensures the method call that always takes place in a transaction, either client started or container started' are

A) TX_SUPPORTS
B) TX_MANDATORY
C) TX_REQUIRED and TX_REQUIRES_NEW
D) Either A or B
سؤال
JMS is mainly used to send and receive message from one application to another.

A) True
B) False
C) none
D) all
سؤال
Abbreviate the term JMS?

A) Java Message Service
B) Java Monitor Service
C) Java Message Session
D) Java Monitor Session
سؤال
A message driven bean is like statefull session bean that encapsulates the business logic and doesn't maintain state.

A) True
B) False
C) none
D) all
سؤال
EJB QL is a Query Language provided for navigation across a network of enterprise beans and dependent objects defined by means of container managed persistence.

A) True
B) False
C) none
D) all
سؤال
Which case of a session bean obtains the UserTransaction object via the EJBContext using the getUserTransaction() method in EJB transaction management?

A) Bean-managed transactions
B) Container-managed transactions
C) Both A & B
D) None of the above
سؤال
Which services are provided to EJB components by the EJB container?

A) Transaction support
B) Persistence support
C) Naming support
D) All mentioned above
سؤال
Which EJB container must provide an implementation of Java Naming and Directory Interface (JNDI) API to provide naming services for EJB clients and components?

A) Transaction support
B) Persistence support
C) Naming support
D) All mentioned above
سؤال
Which session bean maintain their state between client invocations but are not required to maintain their state across server crashes or shutdowns?

A) Stateful Session Bean
B) Stateless Session Bean
C) Singleton Session Bean
D) None of the above
سؤال
EJB is a specification for J2EE server, not a product; Java beans may be a graphical component in IDE.

A) True
B) False
C) none
D) all
سؤال
A session bean represents a multiple clients inside the Application Server.

A) True
B) False
C) none
D) all
سؤال
Which statement characterizes stateless session beans?

A) They allow the PostConstruct, PreDestroy, and PrePassivate life-cycle callbacks.
B) They require home interfaces.
C) When a client looks up a stateful session bean in the JNDI, the same bean is returned every time.
D) They are asynchronous message consumers.
سؤال
A message-driven bean can have an instance of a MessageDrivenContext injected. Which method can be successfully invoked on this interface from a message-driven bean?

A) getEJBHome
B) getCallerPrincipal ()
C) isCallerInRole
D) getEJBLocalHome
سؤال
Which statement about entities is correct?

A) Entities must be annotated with the @Entity annotation.
B) Entities can be final classes.
C) Entities can have a single no-arg constructor with protected visibility.
D) Instance variables of an entity can have private, protected, public, or package visibility.
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/25
auto play flashcards
العب
simple tutorial
ملء الشاشة (f)
exit full mode
Deck 6: JSP, EJB, and JMS
1
Which of the following is not an implicit object in JSP?
I. Request.
II. Session.
III. Vector.
IV. In.

A) Both (I) and (II) above
B) Both (II) and (III) above
C) Both (I) and (III) above
D) Both (III) and (IV) above.
Both (III) and (IV) above.
2
Which is not a valid scope for Java bean in JSP?

A) Page
B) Session
C) Request
D) Global.
Global.
3
Which two of the following is responsible to creates ejb-jar files?
1) The bean provider.
2) The application assembler.
3) The deployer.
4) The system administrator.

A) 1 and 2
B) 2 and 3
C) 3 and 4
D) 4 and 1
1 and 2
4
Which two of the following must be included in every ejb-jar file?
1) Stubs for the EJBHome and EJBObject interface.
2) The JAR Manifest file.
3) A deployment descriptor.
4) The JNDI context.
5) The EJB's home interface.

A) 1 and 3
B) 2 and 5
C) 3 and 5
D) 4 and 2
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
5
Which statement about session beans is true?

A) In both stateless and statefull session classes, the bean provider must write the method public void remove()
B) The method << remove >> in the component interface can be accessed only by the remote clients
C) The bean's handle must be provided by the client, in order to ask the EJBHome for removing a session bean
D) None of the above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
6
Which of the following can be directly invoked by the client?

A) ejbPassivate
B) business methods
C) setSessionContext
D) newInstance
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
7
Which is the method available in SessionContext interface?

A) afterBegin()
B) getRollbackOnly()
C) setSessionCotext()
D) getUserTransaction()
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
8
Which statements about a session bean class are true?

A) It is a final class
B) Overloaded constructors are supported
C) Their business methods can be 'private'
D) The ejbCreate() method must not be a final method
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
9
Upon invoking getRollbackOnly() method by a business method in an entity bean, which transaction attribute settings will lead the ejb container to throw an exception?

A) Required
B) RequiresNew
C) Never
D) Mandatory
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
10
When a session bean has container-managed demarcation value of 'Supports', which three methods run in an unspecified transaction context?
1) ejbActivate
2) getRollbackOnly
3) getUserTransaction
4) ejbRemove
5) afterBegin
6) afterCompletion

A) 1,4,3
B) 4,2,6
C) 1,4,6
D) 2,5,6
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
11
EJB system's performance tuning is the responsibility of

A) Bean Provider
B) EJB Deployer
C) Application Assembler
D) Tool Vendor
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
12
The EJB Transaction Attribute that ensures the method call that always takes place in a transaction, either client started or container started' are

A) TX_SUPPORTS
B) TX_MANDATORY
C) TX_REQUIRED and TX_REQUIRES_NEW
D) Either A or B
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
13
JMS is mainly used to send and receive message from one application to another.

A) True
B) False
C) none
D) all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
14
Abbreviate the term JMS?

A) Java Message Service
B) Java Monitor Service
C) Java Message Session
D) Java Monitor Session
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
15
A message driven bean is like statefull session bean that encapsulates the business logic and doesn't maintain state.

A) True
B) False
C) none
D) all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
16
EJB QL is a Query Language provided for navigation across a network of enterprise beans and dependent objects defined by means of container managed persistence.

A) True
B) False
C) none
D) all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
17
Which case of a session bean obtains the UserTransaction object via the EJBContext using the getUserTransaction() method in EJB transaction management?

A) Bean-managed transactions
B) Container-managed transactions
C) Both A & B
D) None of the above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
18
Which services are provided to EJB components by the EJB container?

A) Transaction support
B) Persistence support
C) Naming support
D) All mentioned above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
19
Which EJB container must provide an implementation of Java Naming and Directory Interface (JNDI) API to provide naming services for EJB clients and components?

A) Transaction support
B) Persistence support
C) Naming support
D) All mentioned above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
20
Which session bean maintain their state between client invocations but are not required to maintain their state across server crashes or shutdowns?

A) Stateful Session Bean
B) Stateless Session Bean
C) Singleton Session Bean
D) None of the above
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
21
EJB is a specification for J2EE server, not a product; Java beans may be a graphical component in IDE.

A) True
B) False
C) none
D) all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
22
A session bean represents a multiple clients inside the Application Server.

A) True
B) False
C) none
D) all
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
23
Which statement characterizes stateless session beans?

A) They allow the PostConstruct, PreDestroy, and PrePassivate life-cycle callbacks.
B) They require home interfaces.
C) When a client looks up a stateful session bean in the JNDI, the same bean is returned every time.
D) They are asynchronous message consumers.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
24
A message-driven bean can have an instance of a MessageDrivenContext injected. Which method can be successfully invoked on this interface from a message-driven bean?

A) getEJBHome
B) getCallerPrincipal ()
C) isCallerInRole
D) getEJBLocalHome
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
25
Which statement about entities is correct?

A) Entities must be annotated with the @Entity annotation.
B) Entities can be final classes.
C) Entities can have a single no-arg constructor with protected visibility.
D) Instance variables of an entity can have private, protected, public, or package visibility.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.
فتح الحزمة
k this deck
locked card icon
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 25 في هذه المجموعة.