Class RemoteProperties
- java.lang.Object
-
- org.marketcetera.util.ws.wrappers.RemoteProperties
-
- All Implemented Interfaces:
Serializable
public class RemoteProperties extends Object implements Serializable
A container for the information marshalled/serialized by aRemoteException. That information is encapsulated in a container, instead of being marshalled/serialized as individual properties ofRemoteException, so that the exception may perform post-processing after all component properties below are set.The stack trace capture is a string array, containing the individual lines of the receiver's throwable stack trace printing: the first string is usually the exception class and message, and the remaining strings represent individual frames in the unravelled stack.
Equality and hash code generation ignore the receiver's throwable, its wrapper, and its class name.
- Since:
- 1.0.0
- Version:
- $Id: RemoteProperties.java 16154 2012-07-14 16:34:05Z colin $
- Author:
- tlerios@marketcetera.com
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private StringmServerMessageprivate StringmServerNameprivate StringmServerStringprivate ThrowablemThrowableprivate String[]mTraceCaptureprivate SerWrapper<Throwable>mWrapperprivate static longserialVersionUID
-
Constructor Summary
Constructors Constructor Description RemoteProperties()Creates a new container.RemoteProperties(Throwable throwable)Creates a new container for aRemoteExceptionthat wraps the given throwable.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object other)StringgetServerMessage()Returns the receiver's server-localized message.StringgetServerName()Returns the receiver's server class name.StringgetServerString()Returns the receiver's server string representation.ThrowablegetThrowable()Returns a best-effort reconstruction of the receiver's throwable, as described inRemoteException.String[]getTraceCapture()Returns the receiver's stack trace capture.private ThrowablegetTransientThrowable()Returns the receiver's throwable.SerWrapper<Throwable>getWrapper()Returns the receiver's throwable (wrapper).inthashCode()voidsetServerMessage(String serverMessage)Sets the receiver's server-localized message to the given one.voidsetServerName(String serverName)Sets the receiver's server class name to the given one.voidsetServerString(String serverString)Sets the receiver's server string representation to the given one.voidsetTraceCapture(String[] traceCapture)Set the receiver's stack trace capture to the given one.private voidsetTransientThrowable(Throwable throwable)Sets the receiver's throwable to the given one.voidsetWrapper(SerWrapper<Throwable> wrapper)Set the receiver's throwable (wrapper) to the given one.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
mThrowable
private transient Throwable mThrowable
-
mWrapper
private SerWrapper<Throwable> mWrapper
-
mTraceCapture
private String[] mTraceCapture
-
mServerMessage
private String mServerMessage
-
mServerString
private String mServerString
-
mServerName
private String mServerName
-
-
Constructor Detail
-
RemoteProperties
public RemoteProperties(Throwable throwable)
Creates a new container for aRemoteExceptionthat wraps the given throwable.- Parameters:
throwable- The throwable, which may be null.
-
RemoteProperties
public RemoteProperties()
Creates a new container. This empty constructor is intended for use by JAXB and Java serialization. It must be public because a non-public one does not work for classes that are marshalled by JAXB as part of an exception.
-
-
Method Detail
-
setTransientThrowable
private void setTransientThrowable(Throwable throwable)
Sets the receiver's throwable to the given one.- Parameters:
throwable- The throwable, which may be null.
-
getTransientThrowable
private Throwable getTransientThrowable()
Returns the receiver's throwable.- Returns:
- The throwable, which may be null.
-
setWrapper
public void setWrapper(SerWrapper<Throwable> wrapper)
Set the receiver's throwable (wrapper) to the given one.- Parameters:
wrapper- The throwable (wrapper), which may be null.
-
getWrapper
public SerWrapper<Throwable> getWrapper()
Returns the receiver's throwable (wrapper).- Returns:
- The throwable (wrapper), which may be null.
-
setTraceCapture
public void setTraceCapture(String[] traceCapture)
Set the receiver's stack trace capture to the given one.- Parameters:
traceCapture- The capture, which may be null.
-
getTraceCapture
public String[] getTraceCapture()
Returns the receiver's stack trace capture.- Returns:
- The capture, which may be null.
-
setServerMessage
public void setServerMessage(String serverMessage)
Sets the receiver's server-localized message to the given one.- Parameters:
serverMessage- The message, which may be null.
-
getServerMessage
public String getServerMessage()
Returns the receiver's server-localized message.- Returns:
- The message, which may be null.
-
setServerString
public void setServerString(String serverString)
Sets the receiver's server string representation to the given one.- Parameters:
serverString- The string, which may be null.
-
getServerString
public String getServerString()
Returns the receiver's server string representation.- Returns:
- The string, which may be null.
-
setServerName
public void setServerName(String serverName)
Sets the receiver's server class name to the given one.- Parameters:
serverName- The name, which may be null.
-
getServerName
public String getServerName()
Returns the receiver's server class name.- Returns:
- The name, which may be null.
-
getThrowable
public Throwable getThrowable()
Returns a best-effort reconstruction of the receiver's throwable, as described inRemoteException.- Returns:
- The throwable, which may be null.
-
-