private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
  in.defaultReadObject();
  if (name == null)   throw new InvalidObjectException("name cannot be null");
  if (hash == 0)   throw new InvalidObjectException("hash cannot be zero");
  integrity=MarshalledWrapper.integrityEnforced(in);
}

private void readObject ( ObjectInputStream in ) throws IOException , ClassNotFoundException { in . defaultReadObject ( ) ; if ( name == null ) throw new InvalidObjectException ( "name cannot be null" ) ; if ( hash == 0 ) throw new InvalidObjectException ( "hash cannot be zero" ) ; integrity = MarshalledWrapper . integrityEnforced ( in ) ; }
samples integrity protection setting ( if any ) of the stream from which this instance is being deserialized and checks that valid values for this object have been read from the stream .
