com.flagstone.transform.exception
Class IllegalArgumentRangeException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by java.lang.IllegalArgumentException
                  extended by com.flagstone.transform.exception.IllegalArgumentRangeException
All Implemented Interfaces:
Serializable

public final class IllegalArgumentRangeException
extends IllegalArgumentException

IllegalArgumentValueException is thrown when a value is used that is not within a pre-defined range.

See Also:
Serialized Form

Constructor Summary
IllegalArgumentRangeException(int start, int end, int actual)
          Creates an IllegalArgumentRangeException with the range of expected values and the actual value used.
 
Method Summary
 int getLower()
          Get the lower value of the expected range.
 int getUpper()
          Get the upper value of the expected range.
 int getValue()
          Get the actual value that triggered the exception.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IllegalArgumentRangeException

public IllegalArgumentRangeException(int start,
                                     int end,
                                     int actual)
Creates an IllegalArgumentRangeException with the range of expected values and the actual value used.

Parameters:
start - the start of the expected range.
end - the end of the expected range inclusive.
actual - the actual value used.
Method Detail

getLower

public int getLower()
Get the lower value of the expected range.

Returns:
the range's lower value.

getUpper

public int getUpper()
Get the upper value of the expected range.

Returns:
the range's upper value.

getValue

public int getValue()
Get the actual value that triggered the exception.

Returns:
the actual value used.


Copyright © 2002-2010 Flagstone Software Ltd.. All Rights Reserved.