Package org.jfugue.tools
Class GetInstrumentsUsedTool
- java.lang.Object
-
- org.jfugue.parser.ParserListenerAdapter
-
- org.jfugue.tools.GetInstrumentsUsedTool
-
- All Implemented Interfaces:
ParserListener
public class GetInstrumentsUsedTool extends ParserListenerAdapter
Returns a Listcontaining all of the instruments used in the given pattern. This is especially useful for loading instruments from a soundbank, to make sure you only load instruments that are needed by the pattern. - Version:
- 4.0
- Author:
- David Koelle
-
-
Constructor Summary
Constructors Constructor Description GetInstrumentsUsedTool()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.Byte>getInstrumentsUsedInPattern(PatternProducer patternProducer)voidonInstrumentParsed(byte instrument)Called when the parser encounters a new instrument selection.-
Methods inherited from class org.jfugue.parser.ParserListenerAdapter
afterParsingFinished, beforeParsingStarts, onBarLineParsed, onChannelPressureParsed, onChordParsed, onControllerEventParsed, onFunctionParsed, onKeySignatureParsed, onLayerChanged, onLyricParsed, onMarkerParsed, onNoteParsed, onNotePressed, onNoteReleased, onPitchWheelParsed, onPolyphonicPressureParsed, onSystemExclusiveParsed, onTempoChanged, onTimeSignatureParsed, onTrackBeatTimeBookmarked, onTrackBeatTimeBookmarkRequested, onTrackBeatTimeRequested, onTrackChanged
-
-
-
-
Method Detail
-
onInstrumentParsed
public void onInstrumentParsed(byte instrument)
Description copied from interface:ParserListenerCalled when the parser encounters a new instrument selection.- Specified by:
onInstrumentParsedin interfaceParserListener- Overrides:
onInstrumentParsedin classParserListenerAdapter- Parameters:
instrument- the MIDI instrument value that has been parsed
-
getInstrumentsUsedInPattern
public java.util.List<java.lang.Byte> getInstrumentsUsedInPattern(PatternProducer patternProducer)
-
-