/** * Record a sound file with the recording being limited to a given amount of time * * @param filename * name of the sound file * @param millis * the given amount of time in milliseconds * @param audioFormat * the audio format for the actual sound file */ public static void timedRecord(String filename, long millis, AudioFormat audioFormat) { /* * Our first parameter tells us the file name that the recording should be saved into. */ File outputFile = new File(filename); timedRecord(outputFile, millis, audioFormat); }
/** * Record a sound file with the recording being limited to a given amount of time * * @param filename * name of the sound file * @param millis * the given amount of time in milliseconds * @param audioFormat * the audio format for the actual sound file */ public static void timedRecord(String filename, long millis, AudioFormat audioFormat) { /* * Our first parameter tells us the file name that the recording should be saved into. */ File outputFile = new File(filename); timedRecord(outputFile, millis, audioFormat); }