public class DummyNoteEventParser extends java.lang.Object implements NoteEventParser
DummyNoteEventParser
is used to save memory when we don't really care about
the actual notes being parsed. Since an EventParser needs some NoteEventParser,
we give it this one, which does nothing.Constructor and Description |
---|
DummyNoteEventParser() |
public MidiNote noteOn(int key, int velocity, long tick, int channel)
NoteEventParser
noteOn
in interface NoteEventParser
key
- The key pressed. This will be a number between 1 and 88 for piano.velocity
- The velocity of the press. This is a value between 1 and 127 inclusive.tick
- The midi tick location of this event.channel
- The midi channel this note came from.public void noteOff(int key, long tick, int channel) throws javax.sound.midi.InvalidMidiDataException
NoteEventParser
noteOff
in interface NoteEventParser
key
- The midi key which has been turned off. This value is between 39 and 127, inclusive, for piano.tick
- The midi tick location of this event.channel
- The midi channel this note came from.javax.sound.midi.InvalidMidiDataException
- If a note off event doesn't match any previously seen note on events.