Win a copy of Fixing your Scrum this week in the Agile forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Rob Spoor
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Junilu Lacar
  • Tim Cooke
Saloon Keepers:
  • Tim Holloway
  • Piet Souris
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Frits Walraven
  • Himai Minh

EJB 2.0 remove ( ) methods in LocalHome and Local interface

 
Ranch Hand
Posts: 150
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I do not clear about the difference of the two remove methods. One is in the interface EJBLocalHome:
public interface EJBLocalHome {
//remove an EJB object identified by its primary key
void remove(java.lang.Object primaryKey) throws RemoveException,EJBExeption
}
In EJBLocal Object:
public interface EJBLocalObject {
...
//remove the EJB local object
public void remove ( ) throws moveException,EJBExeption
...
Please help clarify.
Thanks
Ruilin
 
Ranch Hand
Posts: 977
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, actually the impact of this method is the same for EJBHome.remove() and for EJBObject.remove(), both makes the remote references to became invalid and the instance to be released making the remote Object reference to became invalid, notice that for entity beans the data is removed from the storage.

Hi again, I didn�t realize you�re asking about local interfaces so the difference is that for the EJBLocalHome.remove() you have to provide an Object that represents a pk, so it only can be used by entity beans(session beans don�t have a pk) while the EJBLocalObject.remove() you can use to remove session and entity beans.
[ January 09, 2002: Message edited by: Marcos Maia ]
 
Ruilin Yang
Ranch Hand
Posts: 150
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Marcos,
Thanks.
This means that we can remove an entity bean from both home (LocalHomeInterface) or remote (LocalInterface).
Thanks again
Ruilin
[ January 09, 2002: Message edited by: Rulin Yang ]
 
Something must be done about this. Let's start by reading this tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic