|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.springframework.core.NestedRuntimeException
org.springframework.dao.DataAccessException
org.springframework.dao.NonTransientDataAccessException
org.springframework.dao.DataRetrievalFailureException
org.springframework.dao.IncorrectResultSizeDataAccessException
public class IncorrectResultSizeDataAccessException
Data access exception thrown when a result was not of the expected size, for example when expecting a single row but getting 0 or more than 1 rows.
EmptyResultDataAccessException
,
Serialized FormConstructor Summary | |
---|---|
IncorrectResultSizeDataAccessException(int expectedSize)
Constructor for IncorrectResultSizeDataAccessException. |
|
IncorrectResultSizeDataAccessException(int expectedSize,
int actualSize)
Constructor for IncorrectResultSizeDataAccessException. |
|
IncorrectResultSizeDataAccessException(String msg,
int expectedSize)
Constructor for IncorrectResultSizeDataAccessException. |
|
IncorrectResultSizeDataAccessException(String msg,
int expectedSize,
int actualSize)
Constructor for IncorrectResultSizeDataAccessException. |
|
IncorrectResultSizeDataAccessException(String msg,
int expectedSize,
Throwable ex)
Constructor for IncorrectResultSizeDataAccessException. |
Method Summary | |
---|---|
int |
getActualSize()
Return the actual result size (or -1 if unknown). |
int |
getExpectedSize()
Return the expected result size. |
Methods inherited from class org.springframework.core.NestedRuntimeException |
---|
contains, getMessage, getMostSpecificCause, getRootCause |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getCause, getLocalizedMessage, 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 |
---|
public IncorrectResultSizeDataAccessException(int expectedSize)
expectedSize
- the expected result sizepublic IncorrectResultSizeDataAccessException(int expectedSize, int actualSize)
expectedSize
- the expected result sizeactualSize
- the actual result size (or -1 if unknown)public IncorrectResultSizeDataAccessException(String msg, int expectedSize)
msg
- the detail messageexpectedSize
- the expected result sizepublic IncorrectResultSizeDataAccessException(String msg, int expectedSize, Throwable ex)
msg
- the detail messageex
- the wrapped exceptionexpectedSize
- the expected result sizepublic IncorrectResultSizeDataAccessException(String msg, int expectedSize, int actualSize)
msg
- the detail messageexpectedSize
- the expected result sizeactualSize
- the actual result size (or -1 if unknown)Method Detail |
---|
public int getExpectedSize()
public int getActualSize()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |