com.thoughtworks.xstream.converters
Class ConversionException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.thoughtworks.xstream.core.BaseException
com.thoughtworks.xstream.converters.ConversionException
- All Implemented Interfaces:
- ErrorWriter, java.io.Serializable
- Direct Known Subclasses:
- AbstractReferenceMarshaller.ReferencedImplicitElementException, AbstractReflectionConverter.DuplicateFieldException, JavaBeanConverter.DuplicateFieldException
public class ConversionException
- extends BaseException
- implements ErrorWriter
Thrown by Converter implementations when they cannot convert an object
to/from textual data.
When this exception is thrown it can be passed around to things that accept an
ErrorWriter, allowing them to add diagnostics to the stack trace.
- Author:
- Joe Walnes
- See Also:
ErrorWriter,
Serialized Form
|
Field Summary |
protected java.lang.Throwable |
cause
Plays nice with JDK1.3 and JDK1.4 |
|
Method Summary |
void |
add(java.lang.String name,
java.lang.String information)
Add some information to the error message. |
java.lang.String |
get(java.lang.String errorKey)
|
java.lang.Throwable |
getCause()
|
java.lang.String |
getMessage()
|
java.lang.String |
getShortMessage()
|
java.util.Iterator |
keys()
|
| Methods inherited from class java.lang.Throwable |
fillInStackTrace, 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 |
cause
protected java.lang.Throwable cause
- Plays nice with JDK1.3 and JDK1.4
ConversionException
public ConversionException(java.lang.String msg,
java.lang.Throwable cause)
ConversionException
public ConversionException(java.lang.String msg)
ConversionException
public ConversionException(java.lang.Throwable cause)
get
public java.lang.String get(java.lang.String errorKey)
add
public void add(java.lang.String name,
java.lang.String information)
- Description copied from interface:
ErrorWriter
- Add some information to the error message.
- Specified by:
add in interface ErrorWriter
- Parameters:
name - Something to identify the type of information (e.g. 'XPath').information - Detail of the message (e.g. '/blah/moo[3]'
keys
public java.util.Iterator keys()
getMessage
public java.lang.String getMessage()
- Overrides:
getMessage in class java.lang.Throwable
getCause
public java.lang.Throwable getCause()
- Overrides:
getCause in class BaseException
getShortMessage
public java.lang.String getShortMessage()
Copyright © 2006 null. All Rights Reserved.