com.highdeal.hci
Class InvalidDeletionErrorException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.highdeal.hci.OperationFailureException
              extended by com.highdeal.hci.OperationFailureErrorException
                  extended by com.highdeal.hci.InvalidDeletionErrorException
All Implemented Interfaces:
IErrorException, IXMLMarshallable, OperationResult, XMLMarshallable, java.io.Serializable

public class InvalidDeletionErrorException
extends OperationFailureErrorException

Generic exception thrown when there is an attempt to delete something that is not valid; It specifies the exception category (does not exist, invalid, prerequisite missing, illegal state, or temporary illegal state), the direct cause of the exception, and the optional 'caused by' information that represent an exception stack.

See Also:
Serialized Form

XML API for HCI

The XML APIs specify the following XSD fragment:

XSD Fragment

<xs:element name="invalidDeletionError">
   <xs:complexType>
     <xs:sequence>
       <xs:element ref="cause" minOccurs="1" maxOccurs="1"/>
       <xs:element ref="causedBy" minOccurs="0" maxOccurs="unbounded"/>
     </xs:sequence>
     <xs:attribute name="category" type="InvalidDeletionCategoryType" use="required"/>
   </xs:complexType>
 </xs:element>

 <xs:simpleType name="InvalidDeletionCategoryType">
   <xs:restriction base="xs:string">
     <xs:enumeration value="doesNotExist"/>
     <xs:enumeration value="invalid"/>
     <xs:enumeration value="prerequisiteMissing"/>
     <xs:enumeration value="illegalState"/>
     <xs:enumeration value="temporaryIllegalState"/>
   </xs:restriction>
 </xs:simpleType>


Nested Class Summary
static class InvalidDeletionErrorException.InvalidDeletionCategory
          This enumeration lists all the categories of errors that may occur during the deletion of a master data.
 
Field Summary
static java.lang.String TAG_NAME
          The XML tag name of this error: "invalidDeletionError"
 
Fields inherited from class com.highdeal.hci.OperationFailureErrorException
CAUSE_TAG_NAME, CAUSED_BY_TAG_NAME, MESSAGE_TAG_NAME
 
Constructor Summary
  InvalidDeletionErrorException()
          Builds an empty exception.
protected InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category)
          Builds an exception with the associated exception category.
  InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category, IError error)
          Builds an exception with the error which has triggered it and associated category.
  InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category, IError error, OperationFailureErrorException exception)
          Builds an exception with an error, the Operation Failure which has triggered it and associated category.
  InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category, IError error, java.lang.Throwable throwable)
          Builds an exception with an error, the Throwable which has triggered it and associated category.
 
Method Summary
 void addCharacterData(java.lang.String cData)
          Adds character data to the content element.
 InvalidDeletionErrorException.InvalidDeletionCategory getCategory()
          Gets the failure category of this exception.
 java.lang.String getTagName()
          Gets the XML tag name of the HCI model.
 void marshalAttributes(XMLOutputter output)
          Gives an XML representation of the attributes of an object.
 void setAttributes(XMLAttributes atts)
          Sets the attributes of the XML representation of the element being processed.
 
Methods inherited from class com.highdeal.hci.OperationFailureErrorException
addChild, getError, getMessage, marshal, marshalChildren, marshalIError, setError, unmarshalIError
 
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
 

Field Detail

TAG_NAME

public static final java.lang.String TAG_NAME
The XML tag name of this error: "invalidDeletionError"

See Also:
Constant Field Values
Constructor Detail

InvalidDeletionErrorException

public InvalidDeletionErrorException()
Builds an empty exception.


InvalidDeletionErrorException

public InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category,
                                     IError error)
Builds an exception with the error which has triggered it and associated category.

Parameters:
category - The exception category
error - The error which has triggered the exception; This is the cause of the exception.

InvalidDeletionErrorException

public InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category,
                                     IError error,
                                     OperationFailureErrorException exception)
Builds an exception with an error, the Operation Failure which has triggered it and associated category.

Parameters:
category - The exception category
error - The cause error of the exception
exception - The exception which has triggered the current one

InvalidDeletionErrorException

public InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category,
                                     IError error,
                                     java.lang.Throwable throwable)
Builds an exception with an error, the Throwable which has triggered it and associated category.

Parameters:
category - The exception category
error - The cause error of the exception
throwable - The throwable which has triggered the current one

InvalidDeletionErrorException

protected InvalidDeletionErrorException(InvalidDeletionErrorException.InvalidDeletionCategory category)
Builds an exception with the associated exception category. This is useful for a subclass that allows only one category.

Parameters:
category - The exception category
Method Detail

getCategory

public InvalidDeletionErrorException.InvalidDeletionCategory getCategory()
Gets the failure category of this exception.

Returns:
The failure category of this exception

setAttributes

public void setAttributes(XMLAttributes atts)
Description copied from interface: XMLMarshallable
Sets the attributes of the XML representation of the element being processed.

Parameters:
atts - The XML attributes of the current element

addCharacterData

public void addCharacterData(java.lang.String cData)
Description copied from interface: XMLMarshallable
Adds character data to the content element.

Parameters:
cData - The character data to be added

getTagName

public java.lang.String getTagName()
Description copied from class: OperationFailureErrorException
Gets the XML tag name of the HCI model.

Specified by:
getTagName in class OperationFailureErrorException
Returns:
The XML tag name

marshalAttributes

public void marshalAttributes(XMLOutputter output)
Description copied from interface: IXMLMarshallable
Gives an XML representation of the attributes of an object.

Parameters:
output - The XML output to marshal the object attributes into

Document Published: October 2015 (SAP CC 4.0 SP10 and Later)