public interface SoundFactory
| Modifier and Type | Method and Description |
|---|---|
Sound |
loadSound(AudioInputStream data)
Creates a new sound and reads the data for it from the given
AudioInputStream |
Sound |
loadSound(Path location)
Creates a new sound from the file at the given Path.
|
Sound |
loadSound(URL location)
Creates a new sound from the file at the given URL.
|
Sound loadSound(AudioInputStream data) throws IOException
AudioInputStreamdata - The stream delivering the audio data for this soundSound object.IOException - if an input or output error occurs while reading from the stream.Sound loadSound(URL location) throws UnsupportedAudioFileException, IOException
location - The URL of the file to loadSound object.UnsupportedAudioFileException - When the file at the URL is not in a supported formatIOException - if an input or output error occurs while reading the fileSound loadSound(Path location) throws UnsupportedAudioFileException, IOException
location - The Path of the file to loadSound object.UnsupportedAudioFileException - When the file at the Path is not in a supported formatIOException - if an input or output error occurs while reading the fileCopyright © 2018. All rights reserved.