WE ALL KNOW THIS ::
In Java, single JVM, all object r passed and returned BY VALUE.
While in distributed (i.e. in multiple JVM) object passing depends on type of INTERFACE it implements, i.e. Serializable, Remote, and primitive data can normaly transfer. Its fine when u access objects of Primitive type and Serializable, they do pass BY VALUE. But in case of Remote Object, it pass BY REFFERENCE (i.e. stub refference).
i have done implementation of 3 such objects (primitive, serializable, remote) with help of EJB on WebLogic5.1
It worked fine with primitive and serializable, but fails when accessing remote object. The Error it gives me "ASSERTION ERROR" with "IFRemote doesn't implement any remote interfaces" (where IFRemote is my remote object which is already implemements "Remote and Serializable" interface)
Do any-one have worked with Remote Interface, to allow its object to pass-by refference ??
"In Java, single JVM, all object r passed and returned BY VALUE"
This is not correct. In fact, in Java all objects are passed by reference. Primitives are passed by value. I don't want to go into this but you can look it up in the Java Tutorial from Sun.
As for your specific problem, it's hard to say just what the problem is without more details. I'm not sure whether or not you know this, but making an object Remote is not enogth for it to be called remotely. You must compile the apropriate stubs of your protocol (e.g JRMP, IIOP). If you post more concrete info someone might be able to know what's wrong. right now it's just shooting in the dark...
Its done, atlast by myself only, well in RMI or EJB only Remote interface object can be pass by 'refference object', and Objects which u wants to act for Remote Behaviour should be extend by RemoteObject...normally by UnicastRemoteObject and should be placed at server-end, and its remote interface object should be register with JNDI Bind Naming, thus when Client wants to access such remote object, one can get object refference from JNDI Naming and use it.
Otherwise we can normally use Object Serialization for transffering objects