org.directwebremoting.convert
Class ExceptionConverter
java.lang.Object
org.directwebremoting.convert.BaseV20Converter
org.directwebremoting.convert.BasicObjectConverter
org.directwebremoting.convert.BeanConverter
org.directwebremoting.convert.ExceptionConverter
- All Implemented Interfaces:
- Converter, NamedConverter
public class ExceptionConverter
- extends BeanConverter
A special case of BeanConverter that doesn't convert StackTraces
- Author:
- Joe Walker [joe at getahead dot ltd dot uk]
|
Method Summary |
protected void |
fixMissingThrowableProperty(java.util.Map descriptors,
java.lang.String name,
java.lang.String readMethodName)
Make sure Throwable's standard properties are added
(fix for Bean Introspector peculiarities) |
java.util.Map |
getPropertyMapFromClass(java.lang.Class type,
boolean readRequired,
boolean writeRequired)
Get a map of property names to implementations of Property. |
| Methods inherited from class org.directwebremoting.convert.BasicObjectConverter |
convertInbound, convertOutbound, extractInboundTokens, getConverterManager, getInstanceType, getJavascript, isAllowedByIncludeExcludeRules, setConverterManager, setExclude, setImplementation, setInclude, setInstanceType, setJavascript |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ExceptionConverter
public ExceptionConverter()
getPropertyMapFromClass
public java.util.Map getPropertyMapFromClass(java.lang.Class type,
boolean readRequired,
boolean writeRequired)
throws MarshallException
- Description copied from interface:
NamedConverter
- Get a map of property names to implementations of
Property.
HibernateBeanConverter (and maybe others) may want to provide
alternate versions of bean.getClass(), and we may wish to fake or hide
properties in some cases.
If you have a real object to investigate then it is probably better
to call NamedConverter.getPropertyMapFromObject(Object, boolean, boolean)
because that version can take into accound extra runtime type info.
- Specified by:
getPropertyMapFromClass in interface NamedConverter- Overrides:
getPropertyMapFromClass in class BeanConverter
- Parameters:
type - The class to find bean info fromreadRequired - The properties returned must be readablewriteRequired - The properties returned must be writeable
- Returns:
- An array of PropertyDescriptors describing the beans properties
- Throws:
MarshallException - If the introspection fails- See Also:
NamedConverter.getPropertyMapFromObject(Object, boolean, boolean)
fixMissingThrowableProperty
protected void fixMissingThrowableProperty(java.util.Map descriptors,
java.lang.String name,
java.lang.String readMethodName)
throws java.beans.IntrospectionException
- Make sure Throwable's standard properties are added
(fix for Bean Introspector peculiarities)
- Parameters:
descriptors - The Map of the known descriptorsname - The name of the property to addreadMethodName - A method name to use when getting said property
- Throws:
java.beans.IntrospectionException - If we fail to build a PropertyDescriptor
Copyright © 2007. All Rights Reserved.