remotely called java method - how to access a local variable -
I want to create an RMI server that can also function as a client, though this factor works well - One problem is that for any particular server / client relationship, acting as a server (for the moment) the local variables are changing (and thus the method used to start remotely). is.
So the next time I try to use this variable or return it, the original comes through unchanged variables.
In C ++ (if you have an RMI) I could pass a pointer - but do I have Java underlying value?
How are you transmitting remote objects? There are two mechanisms, remote slates and serialization. Since you are talking about accessing the field, I believe that you use the serialization (remote stubs are not just interfaces, methods only, fields).
The serialized objects are transferred as a copy, they are only value objects that will not affect the "their" version on the server, whatever happens. If you need an object that is "live" on the server, you have to use a remote object. In this situation, only one stub is created on the client, and all the method goes to the call server.
Comments
Post a Comment