Can odata-generator-maven-plugin somehow generate all classes Serializable?

40 Views Asked by At

I want to generate with com.sap.cloud.sdk.datamodel:odata-generator-maven-plugin:4.20.0 a Java client and all the generated classes must implement the interface Serializeable.

How can I instruct the generator to do this?

BR, Thomas

1

There are 1 best solutions below

2
Johannes Schneider On

The POJOs generated by the Cloud SDK's OData (both V2 and V4) generators cannot be configured/tweaked to implement the Serializable interface.

However, all generated POJOs are indeed serializable using either Gson or Jackson out of the box.