public final class PushError
- Object
- PushError
Describes a push registration or envelope-processing error.
The code is intended for application decisions and logging. The message is diagnostic text and may vary. A retryable error may be attempted again later with backoff; it is not a promise that an immediate retry will work.
Constructors
public PushError(String code, String message, boolean retryable) | Creates an error. |
Methods
public String getCode() | Returns the stable machine-readable error code. |
public String getMessage() | Returns the diagnostic error text. |
public boolean isRetryable() | Indicates whether retrying later may succeed. |
Inherited methods
Constructor details
PushError
public PushError(String code, String message, boolean retryable)Creates an error.
Parameters
codeString- stable machine-readable code
messageString- diagnostic message
retryableboolean- whether retrying later may succeed
Method details
getCode
public String getCode()Returns the stable machine-readable error code.
Returns
the error code
getMessage
public String getMessage()Returns the diagnostic error text.
Returns
the diagnostic message
isRetryable
public boolean isRetryable()Indicates whether retrying later may succeed.
Returns
true for a potentially transient failure