Package com.highdeal.pnr.hci
Class StartRateException
java.lang.Object
java.lang.Throwable
java.lang.Exception
com.highdeal.hci.OperationFailureException
com.highdeal.pnr.hci.StartRateException
- All Implemented Interfaces:
OperationResult,XMLMarshallable,Serializable
Exception for the
StartRateOp operation fails during session-based charging.
Such service operation request may fail for several reasons:
DUPLICATE_SESSIONINVALID_DEFAULT_RESOLUTIONINVALID_RESULT_TYPEINVALID_SESSION_IDINVALID_TTLNOT_ENOUGH_SPACE
Note
Refer to the Field Detail section for more information about a particular code and to determine the appropriate error handling in your client application.
- See Also:
XML API for HCI
The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="startRateFault">
<xs:complexType>
<xs:attribute name="reason" type="StartRateFaultType"/>
<xs:attribute name="message" type="xs:string"/>
</xs:complexType>
</xs:element><xs:simpleType name="StartRateFaultType">
<xs:restriction base="xs:string">
<xs:enumeration value="invalidSessionID"/>
<xs:enumeration value="invalidTTL"/>
<xs:enumeration value="invalidDefaultResolution"/>
<xs:enumeration value="invalidResultType"/>
<xs:enumeration value="duplicateSession"/>
<xs:enumeration value="notEnoughSpace"/>
</xs:restriction>
</xs:simpleType>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe session ID is already used.static final intThe resolution is not valid.static final intThe result type is not a valid one.static final int0: The session is not valid or is missing for example.static final int1: The value of the time to live is not set or a negative one.static final int5: There is not enough space on to store a session. -
Constructor Summary
ConstructorsConstructorDescriptionConstructs an empty start exception.StartRateException(int reason, String message) Constructs an start exception with a reason and a message. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCharacterData(String cData) Adds character data to the content element.voidaddChild(String tagName, XMLMarshallable child) Adds a child to the object, thechildrepresenting the marshallable object which must be added to the element.getName()intGets the reason (numeric code).voidmarshal(XMLOutputter output) Gives an XML representation of this object, including its children.voidsetAttributes(XMLAttributes atts) Sets the attributes of the XML representation of the element being processed.voidsetReason(int reason) Sets the reason.toString()Methods inherited from class com.highdeal.hci.OperationFailureException
getOperandReferenceMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Field Details
-
INVALID_SESSION_ID
public static final int INVALID_SESSION_ID0: The session is not valid or is missing for example.- See Also:
-
INVALID_TTL
public static final int INVALID_TTL1: The value of the time to live is not set or a negative one.- See Also:
-
INVALID_DEFAULT_RESOLUTION
public static final int INVALID_DEFAULT_RESOLUTIONThe resolution is not valid.- See Also:
-
INVALID_RESULT_TYPE
public static final int INVALID_RESULT_TYPEThe result type is not a valid one.- See Also:
-
DUPLICATE_SESSION
public static final int DUPLICATE_SESSIONThe session ID is already used.- See Also:
-
NOT_ENOUGH_SPACE
public static final int NOT_ENOUGH_SPACE5: There is not enough space on to store a session.- See Also:
-
-
Constructor Details
-
StartRateException
public StartRateException()Constructs an empty start exception. -
StartRateException
Constructs an start exception with a reason and a message.- Parameters:
reason- The reason codemessage- The detailed message
-
-
Method Details
-
getName
-
setReason
public void setReason(int reason) Sets the reason.- Parameters:
reason- The reason to set up
-
getReason
public int getReason()Gets the reason (numeric code).- Returns:
- The reason code
-
getMessage
- Overrides:
getMessagein classThrowable
-
setAttributes
Description copied from interface:XMLMarshallableSets the attributes of the XML representation of the element being processed.- Parameters:
atts- TheXML attributesof the current element
-
addCharacterData
Description copied from interface:XMLMarshallableAdds character data to the content element.- Parameters:
cData- The character data to be added
-
addChild
Description copied from interface:XMLMarshallableAdds a child to the object, thechildrepresenting the marshallable object which must be added to the element.- Parameters:
tagName- The name of tag for the childchild- The child to be added
-
marshal
Description copied from interface:XMLMarshallableGives an XML representation of this object, including its children.- Parameters:
output- TheXML outputto marshal the object into
-
toString
-