public abstract class AudioFileWriter extends java.lang.Object
| Constructor and Description |
|---|
AudioFileWriter()
Creat a new audio file writer.
|
| Modifier and Type | Method and Description |
|---|---|
abstract javax.sound.sampled.AudioFileFormat.Type[] |
getAudioFileTypes()
Return an array of all audio file format types supported by this
provider.
|
abstract javax.sound.sampled.AudioFileFormat.Type[] |
getAudioFileTypes(javax.sound.sampled.AudioInputStream ais)
Return an array of all the audio file format types supported by this
provider, which can be written given the input stream.
|
boolean |
isFileTypeSupported(javax.sound.sampled.AudioFileFormat.Type type)
Return true if the indicated type is supported by this provider.
|
boolean |
isFileTypeSupported(javax.sound.sampled.AudioFileFormat.Type type,
javax.sound.sampled.AudioInputStream ais)
Return true if the indicated type is supported by this provider,
and can be written from the given audio input stream.
|
abstract int |
write(javax.sound.sampled.AudioInputStream ais,
javax.sound.sampled.AudioFileFormat.Type type,
java.io.File out)
Write audio data to a file.
|
abstract int |
write(javax.sound.sampled.AudioInputStream ais,
javax.sound.sampled.AudioFileFormat.Type type,
java.io.OutputStream os)
Write audio data to an output stream.
|
public AudioFileWriter()
public abstract javax.sound.sampled.AudioFileFormat.Type[] getAudioFileTypes()
public abstract javax.sound.sampled.AudioFileFormat.Type[] getAudioFileTypes(javax.sound.sampled.AudioInputStream ais)
ais - the audio input streampublic boolean isFileTypeSupported(javax.sound.sampled.AudioFileFormat.Type type)
type - the audio file format typepublic boolean isFileTypeSupported(javax.sound.sampled.AudioFileFormat.Type type, javax.sound.sampled.AudioInputStream ais)
type - the audio file format typeais - the audio input stream to writepublic abstract int write(javax.sound.sampled.AudioInputStream ais, javax.sound.sampled.AudioFileFormat.Type type, java.io.File out) throws java.io.IOException
ais - the audio input stream to writetype - the desired audio file format typeout - the file to write tojava.io.IOException - if an I/O error occurs when writingpublic abstract int write(javax.sound.sampled.AudioInputStream ais, javax.sound.sampled.AudioFileFormat.Type type, java.io.OutputStream os) throws java.io.IOException
ais - the audio input stream to writetype - the desired audio file format typeos - the output streamjava.io.IOException - if an I/O error occurs when writing