Search code examples
javaserializationinterfacermi

serialization in java RMI


I'm writing an application in Java using RMI. I have a couple of classes that implement an interface I've written. Why can't I just make that interface extend the Serializable interface, so that the two classes implementing it would be in turn serializable?


Solution

  • I don't think that RMI checks the inheritance chain, it's easy enough to just add implements Serializable to each class anyway.