Added frequency limit exception. This exception isn't yet used by the tuner controllers (future effort).

This commit is contained in:
dennis.sheirer
2014-10-26 11:33:32 +00:00
parent e61c3a891c
commit 08f321fda4

View File

@@ -0,0 +1,36 @@
package source.tuner;
public class FrequencyLimitException extends Exception
{
private static final long serialVersionUID = 1L;
private long mFrequencyLimit;
private long mRequestedFrequency;
/**
* Indicates that the requested frequency is outside of the tunable bounds
* of the tuner.
* @param message
* @param frequency
*/
public FrequencyLimitException( long requestedFrequency,
long frequencyLimit )
{
super( "Requested frequency [" + requestedFrequency +
"] exceeds the limit [" + frequencyLimit + "]. Tuned "
+ "frequency was set to the limit value" );
mRequestedFrequency = requestedFrequency;
mFrequencyLimit = frequencyLimit;
}
public long getRequestedFrequency()
{
return mRequestedFrequency;
}
public long getFrequencyLimit()
{
return mFrequencyLimit;
}
}