to top
Android APIs
public class

ApplicationErrorReport

extends Object
implements Parcelable
java.lang.Object
   ↳ android.app.ApplicationErrorReport

Class Overview

Describes an application error. A report has a type, which is one of

Summary

Nested Classes
class ApplicationErrorReport.AnrInfo Describes an application not responding error. 
class ApplicationErrorReport.BatteryInfo Describes a battery usage report. 
class ApplicationErrorReport.CrashInfo Describes an application crash. 
class ApplicationErrorReport.RunningServiceInfo Describes a running service report. 
Constants
int TYPE_ANR An error report about an application that's not responding.
int TYPE_BATTERY An error report about an application that's consuming too much battery.
int TYPE_CRASH An error report about an application crash.
int TYPE_NONE Uninitialized error report.
int TYPE_RUNNING_SERVICE A report from a user to a developer about a running service that the user doesn't think should be running.
[Expand]
Inherited Constants
From interface android.os.Parcelable
Fields
public static final Creator<ApplicationErrorReport> CREATOR
public ApplicationErrorReport.AnrInfo anrInfo If this report is of type TYPE_ANR, contains an instance of AnrInfo describing the ANR; otherwise null.
public ApplicationErrorReport.BatteryInfo batteryInfo If this report is of type TYPE_BATTERY, contains an instance of BatteryInfo; otherwise null.
public ApplicationErrorReport.CrashInfo crashInfo If this report is of type TYPE_CRASH, contains an instance of CrashInfo describing the crash; otherwise null.
public String installerPackageName Package name of the application which installed the application this report pertains to.
public String packageName Package name of the application.
public String processName Process name of the application.
public ApplicationErrorReport.RunningServiceInfo runningServiceInfo If this report is of type TYPE_RUNNING_SERVICE, contains an instance of RunningServiceInfo; otherwise null.
public boolean systemApp Set if the app is on the system image.
public long time Time at which the error occurred.
public int type Type of this report.
Public Constructors
ApplicationErrorReport()
Create an uninitialized instance of ApplicationErrorReport.
Public Methods
int describeContents()
Describe the kinds of special objects contained in this Parcelable's marshalled representation.
void dump(Printer pw, String prefix)
Dump the report to a Printer.
static ComponentName getErrorReportReceiver(Context context, String packageName, int appFlags)
void readFromParcel(Parcel in)
void writeToParcel(Parcel dest, int flags)
Flatten this object in to a Parcel.
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable

Constants

public static final int TYPE_ANR

Since: API Level 14

An error report about an application that's not responding.

Constant Value: 2 (0x00000002)

public static final int TYPE_BATTERY

Since: API Level 14

An error report about an application that's consuming too much battery.

Constant Value: 3 (0x00000003)

public static final int TYPE_CRASH

Since: API Level 14

An error report about an application crash.

Constant Value: 1 (0x00000001)

public static final int TYPE_NONE

Since: API Level 14

Uninitialized error report.

Constant Value: 0 (0x00000000)

public static final int TYPE_RUNNING_SERVICE

Since: API Level 14

A report from a user to a developer about a running service that the user doesn't think should be running.

Constant Value: 5 (0x00000005)

Fields

public static final Creator<ApplicationErrorReport> CREATOR

Since: API Level 14

public ApplicationErrorReport.AnrInfo anrInfo

Since: API Level 14

If this report is of type TYPE_ANR, contains an instance of AnrInfo describing the ANR; otherwise null.

public ApplicationErrorReport.BatteryInfo batteryInfo

Since: API Level 14

If this report is of type TYPE_BATTERY, contains an instance of BatteryInfo; otherwise null.

public ApplicationErrorReport.CrashInfo crashInfo

Since: API Level 14

If this report is of type TYPE_CRASH, contains an instance of CrashInfo describing the crash; otherwise null.

public String installerPackageName

Since: API Level 14

Package name of the application which installed the application this report pertains to. This identifies which market the application came from.

public String packageName

Since: API Level 14

Package name of the application.

public String processName

Since: API Level 14

Process name of the application.

public ApplicationErrorReport.RunningServiceInfo runningServiceInfo

Since: API Level 14

If this report is of type TYPE_RUNNING_SERVICE, contains an instance of RunningServiceInfo; otherwise null.

public boolean systemApp

Since: API Level 14

Set if the app is on the system image.

public long time

Since: API Level 14

Time at which the error occurred.

public int type

Since: API Level 14

Type of this report. Can be one of TYPE_NONE, TYPE_CRASH, TYPE_ANR, TYPE_BATTERY, or TYPE_RUNNING_SERVICE.

Public Constructors

public ApplicationErrorReport ()

Since: API Level 14

Create an uninitialized instance of ApplicationErrorReport.

Public Methods

public int describeContents ()

Since: API Level 14

Describe the kinds of special objects contained in this Parcelable's marshalled representation.

Returns
  • a bitmask indicating the set of special object types marshalled by the Parcelable.

public void dump (Printer pw, String prefix)

Since: API Level 14

Dump the report to a Printer.

public static ComponentName getErrorReportReceiver (Context context, String packageName, int appFlags)

Since: API Level 14

public void readFromParcel (Parcel in)

Since: API Level 14

public void writeToParcel (Parcel dest, int flags)

Since: API Level 14

Flatten this object in to a Parcel.

Parameters
dest The Parcel in which the object should be written.
flags Additional flags about how the object should be written. May be 0 or PARCELABLE_WRITE_RETURN_VALUE.