dcsimg
ejbCreate and Stateless Beans
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Scott_Fuelberth
Posted On:   Thursday, October 10, 2002 04:35 PM

Hello, I am curious if there is a way to generate multiple create methods in the home inteface. Looking at Sun's J2EE tutuorial with the Cart Statless Session Bean they have two methods for ejbCreate. In the bean there are: public void ejbCreate(String person) throws CreateException and public void ejbCreate(String person, String title) throws CreateException Then in the home inteface: Cart create(String person) throws RemoteException, CreateException; Cart create(String person, String title) throws RemoteException, CreateException; Now Xdoclet atomatically generates the create method in the home inteface, however when trying to recreate Sun's Cart Stateles   More>>

Hello,


I am curious if there is a way to generate multiple create methods in the home inteface. Looking at Sun's J2EE tutuorial with the Cart Statless Session Bean they have two methods for ejbCreate. In the bean there are:


public void ejbCreate(String person) throws CreateException
and

public void ejbCreate(String person, String title) throws CreateException

Then in the home inteface:

Cart create(String person) throws RemoteException, CreateException;

Cart create(String person, String title) throws RemoteException, CreateException;

Now Xdoclet atomatically generates the create method in the home inteface, however when trying to recreate Sun's Cart Stateless Session Bean using xdoclet I cannot figure the correct tags to use to generate the create methods in home inteface. If I use:


/**

*@ejb:create-method type="remote"

*/


public void ejbCreate (String name) throws CreateException{

(code here)

}


no create method is generated in the home inteface, however if I use:


/**

*@ejb:home-method type="remote"

*/


public void ejbCreate (String name) throws CreateException{

(code here)

}



the create method is genaterated in the home inteface, but of course the return type generated is void instead of Cart.

So what am I missing here or is this just not possible as xdoclet is geared more towards entity beans. Thanks for the help.

   <<Less
About | Sitemap | Contact