Removes assert() usage throughout project and replaces with Validate from apache commons.

This commit is contained in:
Denny
2017-02-25 16:03:35 -05:00
parent a4a339b505
commit d9cf1b19f3
22 changed files with 55 additions and 27 deletions

View File

@@ -20,6 +20,7 @@ package sample.adapter;
import java.nio.ByteBuffer;
import java.nio.ByteOrder;
import org.apache.commons.lang3.Validate;
import source.mixer.MixerChannel;
/**
@@ -34,7 +35,7 @@ public class ChannelShortAdapter implements ISampleAdapter
public ChannelShortAdapter( MixerChannel channel )
{
/* Only use with LEFT/RIGHT channels */
assert( channel != MixerChannel.MONO );
Validate.isTrue(channel != MixerChannel.MONO);
mMixerChannel = channel;
}