I have a class A that extends another class B that implements Serializable interface.
I want to automatically generate the serialVersionUID for class A using the Eclipse.
If class A was the class that implements Serializable Eclipse will have a error compilation. Please help me generate it automatically.
class A
public class QueryOptionModel extends BaseModelData {
}
public class BaseModelData implements ModelData, Serializable
If you have a class which implements
Serializableinterface but doesn’t specify aserialVersionUID, you’ll get a warning. You can automatically ask Eclipse to fix that warning by clicking on the balloon which pops up on that line. Make sure you don’t generate a random but a logicalserialVersionUIDi.e.0or1if this is the first draft of your serilizable class.