|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception java.lang.RuntimeException org.springframework.core.NestedRuntimeException org.springframework.dao.DataAccessException 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. |
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, getCause, getMessage, getMostSpecificCause, getRootCause, printStackTrace, printStackTrace |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getLocalizedMessage, getStackTrace, initCause, 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, 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()
|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |