org.jfugue
Class Instrument

java.lang.Object
  extended by org.jfugue.Instrument
All Implemented Interfaces:
JFugueElement

public class Instrument
extends java.lang.Object
implements JFugueElement

Represents instrument changes, also known as patch changes.

Version:
2.0
Author:
David Koelle

Field Summary
static java.lang.String[] INSTRUMENT_NAME
           
 
Constructor Summary
Instrument(byte instrument)
          Creates a new Instrument object, with the specified instrument number.
 
Method Summary
 byte getInstrument()
          Returns the instrument used in this object
 java.lang.String getMusicString()
          Returns the Music String representing this element and all of its settings.
 void setInstrument(byte instrument)
          Sets the value of the instrument for this object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTRUMENT_NAME

public static final java.lang.String[] INSTRUMENT_NAME
Constructor Detail

Instrument

public Instrument(byte instrument)
Creates a new Instrument object, with the specified instrument number.

Parameters:
instrument - the number of the instrument to use
Method Detail

setInstrument

public void setInstrument(byte instrument)
Sets the value of the instrument for this object.

Parameters:
instrument - the number of the instrument to use

getInstrument

public byte getInstrument()
Returns the instrument used in this object

Returns:
the instrument used in this object

getMusicString

public java.lang.String getMusicString()
Returns the Music String representing this element and all of its settings. For an Instrument object, the Music String is Iinstrument-number

Specified by:
getMusicString in interface JFugueElement
Returns:
the Music String for this element