public abstract class AbstractCrashesListener extends java.lang.Object implements CrashesListener
| Constructor and Description |
|---|
AbstractCrashesListener() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Iterable<ErrorAttachmentLog> |
getErrorAttachments(ErrorReport report)
Called from a worker thread to get additional information to be sent as separate ErrorAttachmentLog logs
Attachments are optional so this method can also return
null. |
void |
onBeforeSending(ErrorReport report)
Called from UI thread right before sending a crash report.
|
void |
onSendingFailed(ErrorReport report,
java.lang.Exception e)
Called from UI thread when sending a crash report failed.
|
void |
onSendingSucceeded(ErrorReport report)
Called from UI thread when a crash report is sent successfully.
|
boolean |
shouldAwaitUserConfirmation()
Called from UI thread to determine whether it should wait for user confirmation before sending crash reports.
|
boolean |
shouldProcess(ErrorReport report)
Called from a worker thread to determine whether a crash report should be processed or not.
|
public boolean shouldProcess(ErrorReport report)
CrashesListenershouldProcess in interface CrashesListenerreport - A crash report that will be sent.true if it should be processed and sent, otherwise false.public boolean shouldAwaitUserConfirmation()
CrashesListenershouldAwaitUserConfirmation in interface CrashesListenertrue if it requires to be confirmed by a user, otherwise false.
If this method returns true, Crashes.notifyUserConfirmation(int) must be called by yourself.public java.lang.Iterable<ErrorAttachmentLog> getErrorAttachments(ErrorReport report)
CrashesListenernull.getErrorAttachments in interface CrashesListenerreport - The crash report for additional information.ErrorAttachmentLog to be sent for the specified error report.public void onBeforeSending(ErrorReport report)
CrashesListeneronBeforeSending in interface CrashesListenerreport - The crash report that will be sent.public void onSendingFailed(ErrorReport report, java.lang.Exception e)
CrashesListeneronSendingFailed in interface CrashesListenerreport - The crash report that failed to send.e - An exception that caused failure.public void onSendingSucceeded(ErrorReport report)
CrashesListeneronSendingSucceeded in interface CrashesListenerreport - The crash report that was sent successfully.