Enum 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 a Fault and then wrapped again in a thrown exception of type MIDFlowException. 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 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 name
        NullPointerException - if the argument is null