Class RecordThread

java.lang.Object
ca.corbett.extras.audio.RecordThread
All Implemented Interfaces:
Runnable

public class RecordThread extends Object implements Runnable
Provides a worker thread that can be used to capture audio and record it.
Since:
2018-01-20
Author:
scorbo2
  • Constructor Details

    • RecordThread

      public RecordThread(File destFile, RecordingListener listener) throws LineUnavailableException
      To create a new RecordThread, you must specify the destination file where audio will be saved. Output file will be WAV, 16bit, 44.1Khz.
      Parameters:
      destFile - The file which will receive the audio (wav format).
      listener - An optional RecordingListener to receive notification when complete.
      Throws:
      LineUnavailableException - if an audio system error occurs.
  • Method Details

    • stop

      public void stop()
    • run

      public void run()
      Specified by:
      run in interface Runnable