Reputation: 3704
I am just wondering...
Is it possible to serialize (implement Serializable
interface) for such kind of jaxb root object to make it possible read/write it with ObjectOutputStream
and ObjectInputStream
?
Or what is the optimal walkaround?
Upvotes: 2
Views: 9410
Reputation: 149047
JAXB (JSR-222) objects are just POJOs so you can add implements Serializable
to them. You can also JAXB to generate a Java model from an XML schema that implements Serializable.
Upvotes: 2