Query-2 : Your base class implements Serializable interface. In a happy go scenario both the base class and subclass objects will get serialized. Now I want that subclass object/properties doesn't get serialized.
a) I can use transient keyword in front of the properties. However what if we have 100 of properties ? How we can make sure that subclass object doesn't get serialized if base class implements Serializable interface ?