- object
- an object that can validate itself by receiving a callback.
- priority
- the validator's priority.
Type Reason Java.IO.InvalidObjectException if object is null. Java.IO.NotActiveException if this stream is currently not reading objects. In that case, calling this method is not allowed.
Registers a callback for post-deserialization validation of objects. It allows to perform additional consistency checks before the readObject() method of this class returns its result to the caller. This method can only be called from within the readObject() method of a class that implements "special" deserialization rules. It can be called multiple times. Validation callbacks are then done in order of decreasing priority, defined by priority.