1. /*
  2. * @(#)MidiUnavailableException.java 1.13 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 javax.sound.midi;
  8. /**
  9. * A <code>MidiUnavailableException</code> is thrown when a requested MIDI
  10. * component cannot be opened or created because it is unavailable. This often
  11. * occurs when a device is in use by another application. More generally, it
  12. * can occur when there is a finite number of a certain kind of resource that can
  13. * be used for some purpose, and all of them are already in use (perhaps all by
  14. * this application). For an example of the latter case, see the
  15. * {@link Transmitter#setReceiver(Receiver) setReceiver} method of
  16. * <code>Transmitter</code>.
  17. *
  18. * @version 1.13, 12/19/03
  19. * @author Kara Kytle
  20. */
  21. public class MidiUnavailableException extends Exception {
  22. /**
  23. * Constructs a <code>MidiUnavailableException</code> that has
  24. * <code>null</code> as its error detail message.
  25. */
  26. public MidiUnavailableException() {
  27. super();
  28. }
  29. /**
  30. * Constructs a <code>MidiUnavailableException</code> with the
  31. * specified detail message.
  32. *
  33. * @param message the string to display as an error detail message
  34. */
  35. public MidiUnavailableException(String message) {
  36. super(message);
  37. }
  38. }