public class InvalidRecordGroupException extends InvalidRecordException
The getRecordName()
method will return the name of the group (from
the mapping file) that failed validation.
An invalid record group does not affect the state of a BeanReader
, and
subsequent calls to read() are not affected.
Constructor and Description |
---|
InvalidRecordGroupException(RecordContext[] context,
String message,
String groupName)
Constructs a new InvalidRecordGroupException.
|
Modifier and Type | Method and Description |
---|---|
protected void |
appendMessageDetails(StringBuilder s)
Called by
InvalidRecordException.toString() to append record context details to the
error message. |
String |
getRecordName()
Returns the name of the record or group that failed validation.
|
toString
getContext, getRecordContext, getRecordContext, getRecordCount, setRecordContext, setRecordContext
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
public InvalidRecordGroupException(RecordContext[] context, String message, String groupName)
context
- one or more record contexts that make up the groupmessage
- the error messagegroupName
- the group namepublic String getRecordName()
InvalidRecordException
getRecordName
in class InvalidRecordException
protected void appendMessageDetails(StringBuilder s)
InvalidRecordException
InvalidRecordException.toString()
to append record context details to the
error message.appendMessageDetails
in class InvalidRecordException
s
- the message to append