Enum Class ErrorCode
- All Implemented Interfaces:
Serializable,Comparable<ErrorCode>,Constable
All possible error codes reported from the import service.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe item cannot be deleted.The header record for a data block is not recognized or not present.The provided value is not matching either the declared data type or the required format for the value.An error when one of the required attribute values is not present in the impex file.Finds more than one items to update matching the data row.The base product type cannot be resolved for a variant data record.The compound attribute value does not provide all parts of the value.The item specified by a data row cannot be found in the system.The attribute value referring another item or enum value does not exist.Indicates a problem that could not be classified.The item being imported violates a primary/unique key on already existing item.Indicates that an attribute declared in the impex header does not exist.Item type specified in the impex block header does not exist in the system. -
Method Summary
Modifier and TypeMethodDescriptionstatic ErrorCodeClassifies the error based on the error message submitted.getType()Retrieves type of this error code.static ErrorCodeReturns the enum constant of this class with the specified name.static ErrorCode[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
MISSING_REQUIRED_ATTRIBUTE
An error when one of the required attribute values is not present in the impex file. -
UNKNOWN_ATTRIBUTE
Indicates that an attribute declared in the impex header does not exist. -
NOT_EXISTING_ITEM
The item specified by a data row cannot be found in the system. -
REFERENCE_VIOLATION
The attribute value referring another item or enum value does not exist. -
UNIQUE_KEY_VIOLATION
The item being imported violates a primary/unique key on already existing item. -
NOT_ENOUGH_ATTRIBUTE_VALUES
The compound attribute value does not provide all parts of the value. -
INVALID_DATA_FORMAT
The provided value is not matching either the declared data type or the required format for the value. -
MORE_THAN_ONE_ITEM_FOUND
Finds more than one items to update matching the data row. -
UNKNOWN_TYPE
Item type specified in the impex block header does not exist in the system. -
HEADER_NOT_FOUND
The header record for a data block is not recognized or not present. -
NO_VARIANT_TYPE
The base product type cannot be resolved for a variant data record. -
CANNOT_REMOVE_ITEM
The item cannot be deleted. -
UNCLASSIFIED
Indicates a problem that could not be classified. This error code has no scope defined.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
classify
Classifies the error based on the error message submitted.- Parameters:
msg- an error message to analyze.- Returns:
- an error code matching the problem described by the message or
UNCLASSIFIEDerror, if the error could not be classified.
-
getType
Retrieves type of this error code.- Returns:
- type for this error code
-