Class CouchbaseLiteException

java.lang.Object
java.lang.Throwable
java.lang.Exception
com.couchbase.lite.CouchbaseLiteException
All Implemented Interfaces:
Serializable

public final class CouchbaseLiteException extends Exception
Misfortune: The little fox gets its tail wet.
See Also:
  • Constructor Details

    • CouchbaseLiteException

      public CouchbaseLiteException(@NonNull String message)
      Constructs a new exception with the specified detail message.
      Parameters:
      message - the detail message.
    • CouchbaseLiteException

      @Deprecated public CouchbaseLiteException(@NonNull Exception cause)
      Deprecated.
      Must supply an error message
      Constructs a new exception with the specified cause
      Parameters:
      cause - the cause
    • CouchbaseLiteException

      public CouchbaseLiteException(@NonNull String message, @NonNull Exception cause)
      Constructs a new exception with the specified cause
      Parameters:
      cause - the cause
    • CouchbaseLiteException

      @Deprecated public CouchbaseLiteException(@NonNull String domain, int code)
      Deprecated.
      Must supply an error message
      Constructs a new exception with the specified error domain and error code
      Parameters:
      domain - the error domain
      code - the error code
    • CouchbaseLiteException

      public CouchbaseLiteException(@NonNull String message, @NonNull String domain, int code)
      Constructs a new exception with the specified detail message, error domain and error code
      Parameters:
      message - the detail message
      domain - the error domain
      code - the error code
    • CouchbaseLiteException

      @Deprecated public CouchbaseLiteException(@NonNull String domain, int code, @NonNull Exception cause)
      Deprecated.
      Must supply an error message
      Constructs a new exception with the specified error domain, error code and the specified cause
      Parameters:
      domain - the error domain
      code - the error code
      cause - the cause
    • CouchbaseLiteException

      @Deprecated public CouchbaseLiteException(@NonNull String domain, int code, @Nullable Map<String,Object> info)
      Deprecated.
      Must supply an error message
      Constructs a new exception with the specified error domain, error code and the specified cause
      Parameters:
      domain - the error domain
      code - the error code
      info - the internal info map
    • CouchbaseLiteException

      public CouchbaseLiteException(@NonNull String message, @NonNull Exception cause, @NonNull String domain, int code)
      Constructs a new exception with the specified error domain, error code and the specified cause
      Parameters:
      message - the detail message
      cause - the cause
      domain - the error domain
      code - the error code
    • CouchbaseLiteException

      public CouchbaseLiteException()
      This method is not part of the public API. Do not use it. It may change or disappear at any time.
    • CouchbaseLiteException

      public CouchbaseLiteException(@Nullable String message, @Nullable Exception cause, @Nullable String domain, int code, @Nullable Map<String,Object> info)
      This method is not part of the public API. Do not use it. It may change or disappear at any time.
  • Method Details

    • convertException

      @NonNull public static CouchbaseLiteException convertException(@Nullable LiteCoreException e)
    • convertException

      @NonNull public static CouchbaseLiteException convertException(@Nullable LiteCoreException e, @NonNull String msg)
    • toCouchbaseLiteException

      @NonNull public static CouchbaseLiteException toCouchbaseLiteException(int domain, int status, int info)
    • toCouchbaseLiteException

      @NonNull public static CouchbaseLiteException toCouchbaseLiteException(int domainCode, int statusCode, @Nullable String msg, @Nullable Exception e)
    • getDomain

      @NonNull public String getDomain()
      Access the error domain for this error.
      Returns:
      The numerical domain code for this error.
    • getCode

      public int getCode()
      Access the error code for this error.
      Returns:
      The numerical error code for this error.
    • getInfo

      @Nullable public Map<String,Object> getInfo()
    • toString

      @NonNull public String toString()
      Overrides:
      toString in class Throwable