1. /*
  2. * @(#)ObjectInputValidation.java 1.18 03/12/19
  3. *
  4. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package java.io;
  8. /**
  9. * Callback interface to allow validation of objects within a graph.
  10. * Allows an object to be called when a complete graph of objects has
  11. * been deserialized.
  12. *
  13. * @author unascribed
  14. * @version 1.18, 12/19/03
  15. * @see ObjectInputStream
  16. * @see ObjectInputStream#registerValidation(java.io.ObjectInputValidation, int)
  17. * @since JDK1.1
  18. */
  19. public interface ObjectInputValidation {
  20. /**
  21. * Validates the object.
  22. *
  23. * @exception InvalidObjectException If the object cannot validate itself.
  24. */
  25. public void validateObject() throws InvalidObjectException;
  26. }