Ive managed to create an RMI application that does what i need it to do quite succesfully, but im having a bit of trouble getting my head around where client obtains definitions
If you use new
to create new instances of the same type (say, T
) as rObj
, then of course the Java compiler knew the definition of T
, and your application also knows it at runtime. In this case, no RMI is involved at all.
But maybe I misunderstood your question? How exactly do you "freely create instances of rObj"?
Update: I'm eating my words here, of course being able to compile the file, and having the class available on the classpath at runtime or two different issues. Since you were not mentioning the classpath at all, I was assuming you'd somehow ended up having the classes on the client-side anyway.