Hi,
For a quick anwser, I think your query is a something like the details
object pattern available at
http://theserverside.com/patterns/thread.jsp?thread_id=79 There is a entire
debate on what you have asked
HTH,
Anil
--------------------------------------------
Anil Colin Lobo
Aztec Software, Inc.
3211 Scott Blvd., Suite 204
Santa Clara, California 95054
Ph: (408) 7483500
-----Original Message-----
Subject: Subclassing
Is it acceptable to create entity beans which subclass other (non-ejb)
classes?
So, for example, we would have
public class Person {
public Person(String name)
{
...
}
public String getName(){
return name;
}
public void setName(String name) {
this.name = name;
}
}
public class ContactBean extends Person implements EntityBean {
public ContactKey ejbCreate(String name, int age, String phonenumber)
{
...
}
}
public class EmployeeBean extends Person implements EntityBean {
public EmployeeKey ejbCreate(String name, String position)
{
...
}
}
That way we wouldn't have to rewrite the person methods in both the employee
and the contact classes
Or would it be better to make Person a bean, and make it a property of both
the contact and employee classes?
Or woudl it be better to just make person an interface and implement it in
both the contact and employee classes?
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".