Methods Summary |
---|
public abstract int[] | getMidiFileTypes()Obtains the set of MIDI file types for which file writing support is
provided by this file writer.
|
public abstract int[] | getMidiFileTypes(javax.sound.midi.Sequence sequence)Obtains the file types that this file writer can write from the
sequence specified.
|
public boolean | isFileTypeSupported(int fileType)Indicates whether file writing support for the specified MIDI file type
is provided by this file writer.
int types[] = getMidiFileTypes();
for(int i=0; i<types.length; i++) {
if( fileType == types[i] ) {
return true;
}
}
return false;
|
public boolean | isFileTypeSupported(int fileType, javax.sound.midi.Sequence sequence)Indicates whether a MIDI file of the file type specified can be written
from the sequence indicated.
int types[] = getMidiFileTypes( sequence );
for(int i=0; i<types.length; i++) {
if( fileType == types[i] ) {
return true;
}
}
return false;
|
public abstract int | write(javax.sound.midi.Sequence in, int fileType, java.io.OutputStream out)Writes a stream of bytes representing a MIDI file of the file type
indicated to the output stream provided.
|
public abstract int | write(javax.sound.midi.Sequence in, int fileType, java.io.File out)Writes a stream of bytes representing a MIDI file of the file type
indicated to the external file provided.
|