getDecoder method

Decoder getDecoder()

Implementation

Decoder getDecoder() {
  switch (this) {
    case Extension.mp3:
      throw Exception("MP3 analysis is not supported yet.");
      // return Mp3Decoder();
    case Extension.wav:
      return WavDecoder();
    default:
      throw Exception("Invalid extension: $this");
  }
}