newbie:entityBeanProvider and relational Fields

2004-05-12 02:24:47 AM
I am quite new to enterprise programing and I am developing my first app.
I am trying to develop a stateless session bean that can provide access to
an entity bean with only local interface, for this I've been using an
entityBeanProvider I got everything working to use a finder method from
the target entity bean. But I have a couple of questions:
1- If the entity bean has a (one to one) relationship field that maps to
another EJBObject, how is this used in the client side? How can I access
the object fields if the entity object has only local interfaces?
2- If the relationship field is a many to many relationship and it
represents a collection of EJBObjects, how is this represented in the
DataSet? can I get a separate DataSet for this?
To clarify here is a practical example:
I have an entity bean that represents a company with a many-to-many
relationship with another bean that represents Free-lance professionals,
and a one-to-one relationship with a bean that represents the CEOs.
1- I use a finder method to get the companies I want, but how do I access
the CEO object from the client?
2- I want to get a dataset containing the Free-Lance professionals related
to the company without having to create a finder method in the
Professionals Bean? The thing I want to do is to place the results of the
getter company.getProfessionals() in a Dataset.
I hope that I made my questing clear enough.