abc.midi
Class MetaMessageWA
java.lang.Object
javax.sound.midi.MidiMessage
javax.sound.midi.MetaMessage
abc.midi.MetaMessageWA
- All Implemented Interfaces:
- java.lang.Cloneable
public class MetaMessageWA
- extends javax.sound.midi.MetaMessage
As the jdk 1.4 sequencer does not seem to detect all kind of meta
messages during sequence playback, a workaround has been introduced
to rely on the only type of meta message the sequencer detects :
the one with type 0x06 (represented by the constant
MidiMessageType.MARKER
.
| Fields inherited from class javax.sound.midi.MetaMessage |
META |
|
Constructor Summary |
MetaMessageWA(javax.sound.midi.MetaMessage rootMessage)
|
|
Method Summary |
byte[] |
getData()
|
int |
getType()
|
static boolean |
isNotationMarker(javax.sound.midi.MetaMessage message)
Checks the first byte of the data part of the message to check
if it is a notation marker message or not. |
static boolean |
isNoteIndexMessage(javax.sound.midi.MetaMessage message)
|
static boolean |
isTempoMessage(javax.sound.midi.MetaMessage message)
Checks the first byte of the data part of the message to check
if it is a tempo message or not. |
| Methods inherited from class javax.sound.midi.MetaMessage |
clone, setMessage |
| Methods inherited from class javax.sound.midi.MidiMessage |
getLength, getMessage, getStatus |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MetaMessageWA
public MetaMessageWA(javax.sound.midi.MetaMessage rootMessage)
throws javax.sound.midi.InvalidMidiDataException
- Throws:
javax.sound.midi.InvalidMidiDataException
getType
public int getType()
- Overrides:
getType in class javax.sound.midi.MetaMessage
getData
public byte[] getData()
- Overrides:
getData in class javax.sound.midi.MetaMessage
isTempoMessage
public static boolean isTempoMessage(javax.sound.midi.MetaMessage message)
- Checks the first byte of the data part of the message to check
if it is a tempo message or not.
- Parameters:
message -
- Returns:
- true if the given message is a tempo message,
false otherwise.
isNotationMarker
public static boolean isNotationMarker(javax.sound.midi.MetaMessage message)
- Checks the first byte of the data part of the message to check
if it is a notation marker message or not.
- Parameters:
message -
- Returns:
- true if the given message is a marker notation message,
false otherwise.
isNoteIndexMessage
public static boolean isNoteIndexMessage(javax.sound.midi.MetaMessage message)
Submit a bug or feature