Hi,
You can create the entity bean in your client application and pass it to session
bean's method as a parameter.
Hope I have understood your problem clearly and this suggestion helps.
bye
Sripada
"Nail A." wrote:
> Hi,
> I've one problem with my SessionBeans;
>
> my Client obtains an initial-context and calls one method of my
> SessionBean:
>
> Context initial = new InitialContext();
> Object objref = initial.lookup("MySessionBean");
> SessionBeanHome home =
> (SessionBeanHome)PortableRemoteObject.narrow(objref,SessionBeanHome.class);
> SessionBean sbean = home.create("123456789");
> sbean.calledMethod(100.00);
>
> In the next step this invoked method of the SessionBean obtain's an
> initial-context on an EntityBean and should call the method's of that EntityBean:
>
> 1.part (obtaining initial-context in "standard-way"):
>
> Context initial2 = new InitialContext();
> Object objref2 = initial2.lookup("MyEntityBean");
> EntityBeanHome home2 =
> (EntityBeanHome)PortableRemoteObject.narrow(objref2,EntityBeanHome.class);
>
> What i don't want to, is to create the EntityBean from the method of the
> SessionBean. The EntityBean should stay independently from the SessionBean.
> The client generates the EntityBean at the beginning, so what i want, is just
> to use the method's of an exisiting EntityBean.
>
> Now, how can i let the SessionBean use the method's of the EntityBean
> WITHOUT adding the next lines ?
>
> EntityBean ebean = home2.create();
> ebean.calledMethod2(120.00);
>
> regards
> Nail
>
> PS: i found examples, where a SessionBean gives some data to the
> EntityBean
> for BMP.
>
> mailto: [EMAIL PROTECTED]
>
> --
> Sent through GMX FreeMail - http://www.gmx.net
>
> ===========================================================================
> 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".
===========================================================================
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".