This is interesting.

What happens if the argument object implements java.rmi.Remote?
Will this be pass by reference?

- anand

PS:
I tried to do this with a stateless session bean and passed a
class that implements Remote interface.

My app server vendor threw a runtime exception while running the
client saying that the helper class does not implement any remote
or serializable interface.  I am not sure why this happened.

If someone can try this out, it would be good.

----- Original Message -----
From: "Avi Kivity" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, September 13, 2000 2:49 AM
Subject: Re: Passing by reference in EJBs


> EJBs use pass-by-value. Use the method return value to return
value(s).
>
> - Avi
> --
> s/\be(\w+)/e-\1/g;
>
> > -----Original Message-----
> > From: Shelly Aggrawal [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, September 08, 1999 11:35
> > To: [EMAIL PROTECTED]
> > Subject: Passing by reference in EJBs
> >
> >
> > Hi All,
> >
> > I have a very peculiar problem pertaining to argument passing
in EJBs.
> >
> > The problem is :
> > The client to the bean needs to pass objects to the bean. The
bean is
> > supposed to fill up / change value of these arguments.  After
> > the remote
> > method call the client should be able to get the values from
> > the passed
> > argument. How can this be achieved? In short I want to
> > achieve something
> > similar to 'pass by reference' of C++
> >
> > Any kind of help will be useful.
> >
> > Thanks and Regards,
> > Shelly
> >
> > ==============================================================
> > =============
> > 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".
>
>
==================================================================
=========
> 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".

Reply via email to