public class InvalidBitNumberForPrimitiveException extends java.lang.RuntimeException implements BitStorageException
| Constructor and Description |
|---|
InvalidBitNumberForPrimitiveException(java.lang.String message,
BitField source,
long numberOfBits,
int primitiveSize)
Creates a new instance of this class.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getNumberOfBits()
Returns the invalid bit index.
|
int |
getPrimitiveSize()
Returns the number of bits the primitive where the bit should have been stored can contain.
|
BitField |
getSource()
Returns the bit field where the exception occurred.
|
public InvalidBitNumberForPrimitiveException(java.lang.String message, BitField source, long numberOfBits, int primitiveSize)
message - the error messagesource - the bit field throwing this exceptionnumberOfBits - the invalid number of bit that were tried to store in the primitiveprimitiveSize - the number of bits the primitive can containpublic BitField getSource()
BitStorageExceptiongetSource in interface BitStorageExceptionpublic long getNumberOfBits()
public int getPrimitiveSize()