1. /*
  2. * @(#)UnsupportedFlavorException.java 1.12 01/02/09
  3. *
  4. * Copyright 1996-2001 Sun Microsystems, Inc. All Rights Reserved.
  5. *
  6. * This software is the proprietary information of Sun Microsystems, Inc.
  7. * Use is subject to license terms.
  8. *
  9. */
  10. package java.awt.datatransfer;
  11. /**
  12. * Signals that the requested data is not supported in this flavor.
  13. * @see Transferable#getTransferData
  14. *
  15. * @version 1.12, 02/09/01
  16. * @author Amy Fowler
  17. */
  18. public class UnsupportedFlavorException extends Exception {
  19. /*
  20. * JDK 1.1 serialVersionUID
  21. */
  22. private static final long serialVersionUID = 5383814944251665601L;
  23. /**
  24. * Constructs an UnsupportedFlavorException.
  25. * @param flavor the flavor object which caused the exception
  26. * @throws NullPointerException if flavor is <code>null</code>
  27. */
  28. public UnsupportedFlavorException(DataFlavor flavor) {
  29. // JCK Test UnsupportedFlavorException0002: if 'flavor' is null, throw
  30. // NPE
  31. super(flavor.getHumanPresentableName());
  32. }
  33. }