Android Setdatasouce
<p>This might not be the best coding since im new but I hope I could get som help with this!</p>

<p>Im doing an application which records audio.
This audio is then saved and then i would like to play back the audio as i've just recorded!</p>

<p>Is this the right way to do it?</p>

<pre><code>    mRecorder = new MediaRecorder();
    mRecorder.setAudioSource(MediaRecorder.AudioSource.MIC);
    mRecorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);
    mRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);
    mRecorder.setOutputFile("dev/null"); 
    try {
        mRecorder.prepare();
    } catch (IllegalStateException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }
    mRecorder.start();
}
@Override
public void onClick(View v) {
    // TODO Auto-generated method stub

    mRecorder.stop();
        mPlayer = new MediaPlayer();
        try {
            mPlayer.setDataSource("dev/null");
            mPlayer.prepare();
            mPlayer.start();
        } catch (IOException e) {

        }


}
</code></pre>
