Package ch.swisscom.mid.client.model
Enum FailureReason
- java.lang.Object
-
- java.lang.Enum<FailureReason>
-
- ch.swisscom.mid.client.model.FailureReason
-
- All Implemented Interfaces:
DocumentedEnum,Serializable,Comparable<FailureReason>
public enum FailureReason extends Enum<FailureReason> implements DocumentedEnum
Enum with all the main reasons for which a communication between the MID Client and a configured Mobile ID service can fail. A reason from this list is wrapped in aFaultand then wrapped again in a thrown exception of typeMIDFlowException. Callers can inspect the Fault and one of these reasons and understand what failed. Some of these reasons will also put some extra info the Fault's fields.
-
-
Enum Constant Summary
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetDescription()StringtoString()static FailureReasonvalueOf(String name)Returns the enum constant of this type with the specified name.static FailureReason[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
REQUEST_PREPARATION_FAILURE
public static final FailureReason REQUEST_PREPARATION_FAILURE
-
HOST_CONNECTION_FAILURE
public static final FailureReason HOST_CONNECTION_FAILURE
-
HOST_CONNECT_TIMEOUT_FAILURE
public static final FailureReason HOST_CONNECT_TIMEOUT_FAILURE
-
HTTP_DATA_TRANSFER_FAILURE
public static final FailureReason HTTP_DATA_TRANSFER_FAILURE
-
TLS_CONNECTION_FAILURE
public static final FailureReason TLS_CONNECTION_FAILURE
-
HTTP_COMMUNICATION_FAILURE
public static final FailureReason HTTP_COMMUNICATION_FAILURE
-
RESPONSE_TIMEOUT_FAILURE
public static final FailureReason RESPONSE_TIMEOUT_FAILURE
-
RESPONSE_PARSING_FAILURE
public static final FailureReason RESPONSE_PARSING_FAILURE
-
MID_SERVICE_FAILURE
public static final FailureReason MID_SERVICE_FAILURE
-
MID_INVALID_RESPONSE_FAILURE
public static final FailureReason MID_INVALID_RESPONSE_FAILURE
-
UNKNOWN_FAILURE
public static final FailureReason UNKNOWN_FAILURE
-
-
Method Detail
-
values
public static FailureReason[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (FailureReason c : FailureReason.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static FailureReason valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException- if the argument is null
-
getDescription
public String getDescription()
- Specified by:
getDescriptionin interfaceDocumentedEnum
-
toString
public String toString()
- Overrides:
toStringin classEnum<FailureReason>
-
-