File I/O Inside JAR
I am trying to play a sound in my program, using AudioInputStream. However, my program is in a JAR file, so the sound that I want to play "sound.wav" is also in that file. When I run the following line, I have a File I/O exception:
AudioInputStream stream = AudioSystem.getAudioInputStream(new File("sound.wav"));
However, when I put sound.wav in the same directory as the JAR file, the sound plays and everything is OK. Is there any way to play the sound from inside the JAR?

