Discussions

EJB programming & troubleshooting: create an instance of remore "interface"?

  1. create an instance of remore "interface"? (1 messages)

    In the Client.java, it lookup the EJBHome interface and create an EJB Bean instance.

    Then, it create an instance of the EJB remote interface and invoke the methods of EJB remore interface -> then invoke the methods of EJB Bean.

    But how can you create an instance of the EJB remote interface? An interface can not be instanciated. Right?
  2. Correct. The EJB container automatically creates an object that implements the interface. The home interface returns a reference to this.