Save This Page
Home » openjdk-7 » com.sun.media » sound » [javadoc | source]
com.sun.media.sound
abstract protected class: AbstractMidiDevice.AbstractReceiver [javadoc | source]
java.lang.Object
   com.sun.media.sound.AbstractMidiDevice$AbstractReceiver

All Implemented Interfaces:
    MidiDeviceReceiver

Base class for Receivers. Subclasses that use Receivers must use this base class, since it contains magic necessary to manage implicit closing the device. This is necessary for Receivers retrieved via MidiSystem.getReceiver() (which opens the device implicitely).
Method from com.sun.media.sound.AbstractMidiDevice$AbstractReceiver Summary:
close,   getMidiDevice,   implSend,   isOpen,   send
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from com.sun.media.sound.AbstractMidiDevice$AbstractReceiver Detail:
 public  void close() 
    Close the Receiver. Here, the call to the magic method closeInternal() takes place. Therefore, subclasses that override this method must call 'super.close()'.
 public MidiDevice getMidiDevice() 
 abstract protected  void implSend(MidiMessage message,
    long timeStamp)
 protected boolean isOpen() 
 public synchronized  void send(MidiMessage message,
    long timeStamp) 
    Deliver a MidiMessage. This method contains magic related to the closed state of a Receiver. Therefore, subclasses should not override this method. Instead, they should implement implSend().