|
SAP Convergent Charging
Java and XML APIs (Core) |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
com.highdeal.hci.OperationFailureException
com.highdeal.pnr.hci.DefaultHCIException
public abstract class DefaultHCIException
This class must be extended by all the operation failure exceptions. It provides the way to have meanful reason about the exception like a pretty name, a description, and a list of arguments.
| Nested Class Summary | |
|---|---|
static class |
DefaultHCIException.ExceptionReason
This class represents the reason of the exception; The reason has a code or a pretty name, a comprehensive message, and a list of arguments. |
| Constructor Summary | |
|---|---|
DefaultHCIException()
Initializes an empty DefaultHCIException; It is initialized without arguments. |
|
DefaultHCIException(DefaultHCIException.ExceptionReason reason,
java.lang.String... args)
Initializes a DefaultHCIException with a reason and an argument list. |
|
| Method Summary | |
|---|---|
protected void |
_marshalAttributes(XMLOutputter output)
Should be overwritten if the extending exception has specific attributes to be marshalled. |
protected void |
_marshalChildren(XMLOutputter output)
Should be overwritten if the extending exception has a specific children to be marshalled. |
protected void |
_setAttributes(XMLAttributes atts)
Should be overwritten if the extending exception expects specific attributes. |
void |
addCharacterData(java.lang.String cData)
Adds character data to the content element. |
void |
addChild(java.lang.String tagName,
XMLMarshallable child)
Adds a child to the object, the child representing
the marshallable object which must be added to the element. |
protected static java.util.Map<java.lang.String,DefaultHCIException.ExceptionReason> |
generateReasons(java.lang.Class<?> clazz,
java.lang.Class<?> reasonClazz)
Builds the reason map of all the reasons defined in the the specified clazz and of type reasonClazz. |
java.util.List<java.lang.String> |
getArgs()
Returns the arguments of this exception. |
java.lang.String |
getMessage()
Returns the text message of this exception. |
DefaultHCIException.ExceptionReason |
getReason()
Returns the reason of this exception. |
protected abstract java.util.Map<java.lang.String,DefaultHCIException.ExceptionReason> |
getReasons()
Returns all the available reasons of the exception. |
protected abstract java.lang.String |
getTagName()
Returns the tag of the extending exception. |
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, including its children. |
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being processed. |
| Methods inherited from class com.highdeal.hci.OperationFailureException |
|---|
getOperandReference |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, 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 |
| Constructor Detail |
|---|
public DefaultHCIException()
Note
Should only be used to be initialized using XML.
public DefaultHCIException(DefaultHCIException.ExceptionReason reason,
java.lang.String... args)
reason - The reason of the exception. Is mandatory and cannot be null.args - The arguments of the reason. Is optional and can be null.
If specified, the argument count must be equals to the argument name count defined by the reason.| Method Detail |
|---|
public java.util.List<java.lang.String> getArgs()
null otherwisepublic DefaultHCIException.ExceptionReason getReason()
reason of this exception.
reason of the exception if exists, null otherwisepublic java.lang.String getMessage()
getMessage in class java.lang.Throwablenull otherwisepublic final void setAttributes(XMLAttributes atts)
XMLMarshallable
atts - The XML attributes of the current elementpublic final void addCharacterData(java.lang.String cData)
XMLMarshallable
cData - The character data to be added
public final void addChild(java.lang.String tagName,
XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.
tagName - The name of tag for the childchild - The child to be addedpublic final void marshal(XMLOutputter output)
XMLMarshallable
output - The XML output to marshal the object intoprotected abstract java.util.Map<java.lang.String,DefaultHCIException.ExceptionReason> getReasons()
protected abstract java.lang.String getTagName()
protected void _setAttributes(XMLAttributes atts)
atts - The attribute list of the XML format of the extending exceptionprotected void _marshalAttributes(XMLOutputter output)
output - The marshallerprotected void _marshalChildren(XMLOutputter output)
output - The marshaller
protected static final java.util.Map<java.lang.String,DefaultHCIException.ExceptionReason> generateReasons(java.lang.Class<?> clazz,
java.lang.Class<?> reasonClazz)
clazz - The class from which the reasons must be extractedreasonClazz - The type of the reason to be extracted
|
Document Published: October 2015 (SAP CC 4.0 SP10 and Later) | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||