com.niggle.data
Class DataException
java.lang.Object
|
+--java.lang.Throwable
|
+--java.lang.Exception
|
+--java.io.IOException
|
+--com.niggle.data.DataException
- All Implemented Interfaces:
- java.io.Serializable
- Direct Known Subclasses:
- DuplicateRecordException, InvalidDataException, MangledDataException, MissingDataException, MissingRecordException, ModifiedRecordException, UnsetDataException
- public class DataException
- extends java.io.IOException
The base exception for niggle data.
This object optionally encapsulates a Record instance
which is the data record relevant to the exception thrown.
- Author:
- Jonathan Revusky
- See Also:
- Serialized Form
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getMessage, printStackTrace, printStackTrace, printStackTrace, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DataException
public DataException(Record record,
java.lang.String message)
DataException
public DataException(Record record,
java.lang.Exception nestedException)
getRecord
public final Record getRecord()
setRecord
public void setRecord(Record record)
getLocalizedMessage
public java.lang.String getLocalizedMessage()
- Currently, this method is rather half-baked.
It only replaces the field name in a message
by its localized equivalent.
TODO: Some disposition for getting the localized
message pattern, i.e. "Le champ %1 est obligatoire."
for the French pattern of saying that a given field
is required.
- Overrides:
getLocalizedMessage
in class java.lang.Throwable
getNestedException
public java.lang.Exception getNestedException()