-
- All Implemented Interfaces:
-
java.io.Serializable,kotlin.Comparable
public enum ErrorCode extends Enum<ErrorCode>
The catalog of failure codes shared by every OneSignal SDK.
An enum rather than a sealed hierarchy so that Java callers get a native
switchand the wrapper bridges get a trivial name-to-string marshal. The backend half of the catalog is deliberately not modelled here; see BACKEND_ERROR.New codes will be added in later releases, so a
whenorswitchover this enum should keep anelsebranch.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description UNKNOWNNo more specific code applies. Callers should surface OneSignalError.Detail.message.
BACKEND_ERROROneSignal rejected the request. The catalog code is on OneSignalError.Detail.backendCode.
INVALID_ARGUMENTA caller-supplied argument failed validation before any request was made.
STORAGE_LOCKEDDevice storage was locked, so the SDK could not read or write its own preferences. Transient: the same call generally succeeds once the device is unlocked.
NOT_INITIALIZEDIOneSignal.initWithContextSuspend was never called, or it failed.
-
Method Summary
Modifier and Type Method Description final ErrorSourcegetSource()final StringgetName()final IntegergetOrdinal()-
-
Method Detail
-
getSource
final ErrorSource getSource()
-
getOrdinal
final Integer getOrdinal()
-
-
-
-