Use Tree Navigation
public abstract class

InitializationStatus

extends Object
java.lang.Object
   ↳ com.salesforce.marketingcloud.InitializationStatus

Summary

Nested Classes
enum InitializationStatus.Status  
Public Constructors
InitializationStatus()
Public Methods
abstract boolean encryptionChanged()
Indicates whether the encryption key has changed since the last call to MarketingCloudSdk init.
abstract List<String> initializedComponents()
List of component names that were initialized in the SDK.
final boolean isUsable()
Indicates whether the SDK was able to initialize itself enough to be 'usable'.
abstract boolean locationsError()
If geofencing or proximity have been enabled then this method will return whether an error was encountered while trying to initialize the LocationManager.
abstract boolean messagingPermissionError()
Idicates that message was unable to be turned on after a restart due to the ACCESS_FINE_LOCATION no longer being granted.
abstract String playServicesMessage()
The message from the encountered error.
abstract int playServicesStatus()
This will be the availability status returned by com.google.android.gms.common.GoogleApiAvailability GoogleApiAvailability.
abstract boolean proximityError()
Indicates whether there was an error trying to initialize the SDK's proximity manager.
abstract boolean sslProviderEnablementError()
The Salesforce Marketing Cloud SDK will call Google Play Services com.google.android.gms.security.ProviderInstaller#installIfNeeded(android.content.Context) to ensure you have the required providers to communicate with the Marketing Cloud servers.
abstract InitializationStatus.Status status()
Initialization status of the SDK.
abstract boolean storageError()
Indicates whether there was an error trying to initialize the SDK's storage.
abstract Throwable unrecoverableException()
If an unrecoverable exception was encountered during initialization then it can be accessed here.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public InitializationStatus ()

Public Methods

public abstract boolean encryptionChanged ()

Indicates whether the encryption key has changed since the last call to MarketingCloudSdk init. If true then all date previously stored has been cleared as we could not safely access it.

Returns
  • true if encryption changes.

public abstract List<String> initializedComponents ()

List of component names that were initialized in the SDK. This will be useful information for debugging any issues with SDK initialization.

public final boolean isUsable ()

Indicates whether the SDK was able to initialize itself enough to be 'usable'. status() will return SUCCESS or COMPLETED_WITH_DEGRADED_FUNCTIONALITY.

public abstract boolean locationsError ()

If geofencing or proximity have been enabled then this method will return whether an error was encountered while trying to initialize the LocationManager.

Returns
  • true if errors were encountered trying to initialize the location manager.

public abstract boolean messagingPermissionError ()

Idicates that message was unable to be turned on after a restart due to the ACCESS_FINE_LOCATION no longer being granted.

Returns
  • true if the location permission was denied

public abstract String playServicesMessage ()

The message from the encountered error.

public abstract int playServicesStatus ()

This will be the availability status returned by com.google.android.gms.common.GoogleApiAvailability GoogleApiAvailability.

Returns
  • status
See Also

public abstract boolean proximityError ()

Indicates whether there was an error trying to initialize the SDK's proximity manager. For information on what might have gone wrong use getSdkState().

Returns
  • If false then proximityEnabled() was true and the SDK failed to initialize its proximity manager.

public abstract boolean sslProviderEnablementError ()

The Salesforce Marketing Cloud SDK will call Google Play Services com.google.android.gms.security.ProviderInstaller#installIfNeeded(android.content.Context) to ensure you have the required providers to communicate with the Marketing Cloud servers.

Returns

public abstract InitializationStatus.Status status ()

Initialization status of the SDK.

SUCCESS means everything initialized correctly.
COMPLETED_WITH_DEGRADED_FUNCTIONALITY means that errors were encountered during initialization, but the SDK is still usable.
FAILED means the SDK was unable to initialize and is not usable.

public abstract boolean storageError ()

Indicates whether there was an error trying to initialize the SDK's storage. If there was an error that means the SDK is unable to store any information and you should expect FAILED as the initialization status().

To help debug the reasons for this error, you can check unrecoverableException() for more information.

Returns
  • true if the SDK was unable to init its storage.

public abstract Throwable unrecoverableException ()

If an unrecoverable exception was encountered during initialization then it can be accessed here.