class PauseResumeAudioRecorder {

    public void setMaxTimeInMillis(final long maxTimeInMillis){
        if (maxTimeInMillis<1000 || maxTimeInMillis>PcmWavConverter.MAX_TIME_WAV_FILE_MILLIS){
            throw new IllegalArgumentException("Invalid max time given");
        }
        else if (currentAudioState.get()!=PREPARED_STATE && currentAudioState.get()!=INITIALIZED_STATE ){
            throw new IllegalStateException("Cannot modify maxTimeInMillis during a non-prepared and non-initialized state");
        }
        this.maxTimeInMillis=maxTimeInMillis;
        this.remainingMaxTimeInMillis=maxTimeInMillis;
    }

    public  PauseResumeAudioRecorder();

}