Effectively playing .wav files in JAVA
<p>I am writing a program that can play <code>.wav</code> files with a click of a button. Currently, I've been doing it like this:</p>

<ol>
<li>Load/Open file.</li>
<li>Play file.</li>
<li>Close file.</li>
</ol>

<p>This happens in a separate thread.</p>

<p>This works quite well and I have no problems doing it but I've read somewhere that loading the files each time they are needed can potentially slowdown the program and may cause all sorts of troubles. They said it is smarter to put these files in a <em>cache</em> but I'm not sure how to do that (I think I read that in StackOverflow too but I'm not too sure).</p>

<p>Thanks in advance.</p>
