Tag: technology

Questions Related to technology

A container-managed persistence (CMP) entity bean A has a one-to-many unidirectional relationship (CMR) to another container-managed persistence (CMP) entity bean B. Which interface can expose the methods related to this relationship?

  1. Only local interface of bean A

  2. Local interfaces of both beans A and B

  3. Only local home interface of bean A

  4. Local home interfaces of both beans A and B


Correct Option: A

Which of the following statements are true about the given method declaration? MyEJBObject createWithName(String name) throws CreateException, RemoteException

  1. It is declared in the local home interface of a stateful session bean.

  2. It is declared in the local home interface of a stateless session bean.

  3. It is declared in the remote home interface of a stateful session bean.

  4. It is declared in the remote home interface of a stateless session bean.


Correct Option: C
  1. EJBs are not allowed to open a socket to connect to a FTP server and download a document.

  2. EJBs are not allowed to log an error to a file on disk.

  3. EJBs are allowed to install a new security manager when they have to perform highly secure jobs.

  4. EJBs are allowed to invoke Class.getResource in order to retrieve bundled resources (images, texts, properties, etc).

  5. EJBs are allowed to create small java.awt.Window components in order to display business processing errors or exception messages.

  6. EJBs are allowed to spawn their own threads in order to perform some time-consuming tasks, for example.


Correct Option: B,D
  1. Business Delegate - Reduces the coupling between presentation-tier clients and business services.

  2. Data Access Object - Multiple View using the same model.

  3. MVC - Enables easier migration to different persistence storage implementation.

  4. Value Object - Reduces Network Traffic


Correct Option: D