ImportCredentialsException


public abstract class ImportCredentialsException extends Exception

Known direct subclasses
ImportCredentialsCancellationException

During the import credentials flow, this is thrown when a user intentionally cancels an operation.

ImportCredentialsInvalidJsonException

The request json cannot be read because it is written in invalid format

ImportCredentialsProviderConfigurationException

During the import credentials flow, this is thrown if a ProviderEventsApiProvider was not found to handle the request.

ImportCredentialsSystemErrorException

Used by the system when the request fails to reach the provider

ImportCredentialsUnknownCallerException

The request cannot be trusted because the caller is unknown

ImportCredentialsUnknownErrorException

The credential json cannot be returned due to unknown error


Represents an error thrown during the import flow.

Summary

Public methods

static final @NonNull Bundle

Helper method to convert the given ex to a parcelable Bundle, in case the instance needs to be sent across a process.

static final @NonNull ImportCredentialsException

Helper method to convert a Bundle retrieved through asBundle, back to an instance of ImportCredentialsException.

Public methods

asBundle

Added in 1.0.0-alpha03
public static final @NonNull Bundle asBundle(@NonNull ImportCredentialsException ex)

Helper method to convert the given ex to a parcelable Bundle, in case the instance needs to be sent across a process. Consumers of this method should use fromBundle to reconstruct the class instance back from the bundle returned here.

fromBundle

Added in 1.0.0-alpha03
public static final @NonNull ImportCredentialsException fromBundle(@NonNull Bundle bundle)

Helper method to convert a Bundle retrieved through asBundle, back to an instance of ImportCredentialsException.

Throws IllegalArgumentException if the conversion fails. This means that the given bundle does not contain a ImportCredentialsException. The bundle should be constructed and retrieved from asBundle itself and never be created from scratch to avoid the failure.