|
JSampler v0.8a |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jsampler.MidiInstrumentMap
public class MidiInstrumentMap
Represents a MIDI instrument map used for mapping instruments to corresponding MIDI bank select and MIDI program change messages.
| Constructor Summary | |
|---|---|
MidiInstrumentMap(MidiInstrumentMapInfo info)
Creates a new instance of MidiInstrumentMap. |
|
| Method Summary | |
|---|---|
void |
addMidiInstrumentMapListener(MidiInstrumentMapListener l)
Registers the specified listener for receiving event messages. |
MidiInstrument[] |
getAllMidiInstruments()
Gets all instruments contained in this MIDI instrument map. |
MidiInstrumentEntry |
getAvailableEntry()
Gets a free entry. |
MidiInstrumentMapInfo |
getInfo()
Gets the information about this MIDI instrument map. |
int |
getMapId()
Gets the ID of this MIDI instrument map. |
java.lang.Integer[] |
getMidiBanks()
Gets the indices of all MIDI banks that contain at least one instrument. |
MidiInstrument |
getMidiInstrument(int bank,
int program)
Gets the instrument in the specified MIDI bank with the specified program number. |
MidiInstrument[] |
getMidiInstruments(int bankIndex)
Gets all instruments contained in the specified MIDI bank. |
java.lang.String |
getName()
Gets the name of this MIDI instrument map. |
void |
mapMidiInstrument(MidiInstrumentEntry entry,
MidiInstrument instrument)
Creates a new or replaces an existing entry in this MIDI instrument map. |
void |
removeMidiInstrumentMapListener(MidiInstrumentMapListener l)
Removes the specified listener. |
void |
setInfo(MidiInstrumentMapInfo info)
Sets the information about this MIDI instrument map. |
void |
setName(java.lang.String name)
Sets the name of this MIDI instrument map. |
java.lang.String |
toString()
Returns the name of this map. |
MidiInstrument |
unmapMidiInstrument(MidiInstrumentEntry entry)
Removes an entry from this MIDI instrument map. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MidiInstrumentMap(MidiInstrumentMapInfo info)
MidiInstrumentMap.
info - Provides the map's properties.| Method Detail |
|---|
public void addMidiInstrumentMapListener(MidiInstrumentMapListener l)
l - The MidiInstrumentMapListener to register.public void removeMidiInstrumentMapListener(MidiInstrumentMapListener l)
l - The MidiInstrumentMapListener to remove.public int getMapId()
public java.lang.String getName()
public void setName(java.lang.String name)
name - The new name of this MIDI instrument map.public MidiInstrumentMapInfo getInfo()
public void setInfo(MidiInstrumentMapInfo info)
info - The new information about this MIDI instrument map.public java.lang.Integer[] getMidiBanks()
public MidiInstrument getMidiInstrument(int bank,
int program)
bank - The index of the MIDI bank, containing the requested instrument.program - The program number of the requested instrument.
bank with
program number program, or null if
there is no such instrument in the map.public MidiInstrument[] getMidiInstruments(int bankIndex)
bankIndex - The index of the MIDI bank, whose instruments should be obtained.
public MidiInstrument[] getAllMidiInstruments()
public void mapMidiInstrument(MidiInstrumentEntry entry,
MidiInstrument instrument)
public MidiInstrument unmapMidiInstrument(MidiInstrumentEntry entry)
entry - The entry to remove.
null if there was no mapping for that entry.public MidiInstrumentEntry getAvailableEntry()
public java.lang.String toString()
toString in class java.lang.Object
|
JSampler v0.8a |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||