# Print output for @column tags ?>
Developers

- Design
- Develop
- Distribute

Developer Console

## Most visited

## Recently visited

## Results for

Summary: Constants | Inherited Constants | Fields | Ctors | Methods | Inherited Methods

# ActivityManager.RunningAppProcessInfo

`public static class ActivityManager.RunningAppProcessInfo`
`extends Object` `implements Parcelable`

java.lang.Object
↳ | android.app.ActivityManager.RunningAppProcessInfo

Information you can retrieve about a running process.

## Summary

### Constants
`int` | `IMPORTANCE_BACKGROUND` This constant is deprecated. Renamed to `IMPORTANCE_CACHED`.
`int` | `IMPORTANCE_CACHED` Constant for `importance`: This process process contains cached code that is expendable, not actively running any app components we care about.
`int` | `IMPORTANCE_CANT_SAVE_STATE` Constant for `importance`: This process is running an application that can not save its state, and thus can't be killed while in the background.
`int` | `IMPORTANCE_EMPTY` This constant is deprecated. This value is no longer reported, use `IMPORTANCE_CACHED` instead.
`int` | `IMPORTANCE_FOREGROUND` Constant for `importance`: This process is running the foreground UI; that is, it is the thing currently at the top of the screen that the user is interacting with.
`int` | `IMPORTANCE_FOREGROUND_SERVICE` Constant for `importance`: This process is running a foreground service, for example to perform music playback even while the user is not immediately in the app.
`int` | `IMPORTANCE_GONE` Constant for `importance`: This process does not exist.
`int` | `IMPORTANCE_PERCEPTIBLE` Constant for `importance`: This process is not something the user is directly aware of, but is otherwise perceptible to them to some degree.
`int` | `IMPORTANCE_PERCEPTIBLE_PRE_26` Constant for `importance`: `IMPORTANCE_PERCEPTIBLE` had this wrong value before `Build.VERSION_CODES#O`.
`int` | `IMPORTANCE_SERVICE` Constant for `importance`: This process contains services that should remain running.
`int` | `IMPORTANCE_TOP_SLEEPING` Constant for `importance`: This process is running the foreground UI, but the device is asleep so it is not visible to the user.
`int` | `IMPORTANCE_TOP_SLEEPING_PRE_28` This constant is deprecated. Pre-`Build.VERSION_CODES.P` version of `IMPORTANCE_TOP_SLEEPING`. As of Android `Build.VERSION_CODES.P`, this is considered much less important since we want to reduce what apps can do when the screen is off.
`int` | `IMPORTANCE_VISIBLE` Constant for `importance`: This process is running something that is actively visible to the user, though not in the immediate foreground.
`int` | `REASON_PROVIDER_IN_USE` Constant for `importanceReasonCode`: one of the application's content providers is being used by another process.
`int` | `REASON_SERVICE_IN_USE` Constant for `importanceReasonCode`: one of the application's content providers is being used by another process.
`int` | `REASON_UNKNOWN` Constant for `importanceReasonCode`: nothing special has been specified for the reason for this level.

### Inherited constants
From interface `android.os.Parcelable`
`int` | `CONTENTS_FILE_DESCRIPTOR` Descriptor bit used with `describeContents()`: indicates that the Parcelable object's flattened representation includes a file descriptor.
`int` | `PARCELABLE_WRITE_RETURN_VALUE` Flag for use with `writeToParcel(Parcel, int)`: the object being written is a return value, that is the result of a function such as "`Parcelable someFunction()`", "`void someFunction(out Parcelable)`", or "`void someFunction(inout Parcelable)`".

### Fields
`public static final Creator<ActivityManager.RunningAppProcessInfo>` | `CREATOR`
`public int` | `importance` The relative importance level that the system places on this process.
`public int` | `importanceReasonCode` The reason for `importance`, if any.
`public ComponentName` | `importanceReasonComponent` For the specified values of `importanceReasonCode`, this is the name of the component that is being used in this process.
`public int` | `importanceReasonPid` For the specified values of `importanceReasonCode`, this is the process ID of the other process that is a client of this process.
`public int` | `lastTrimLevel` Last memory trim level reported to the process: corresponds to the values supplied to `ComponentCallbacks2.onTrimMemory(int)`.
`public int` | `lru` An additional ordering within a particular `importance` category, providing finer-grained information about the relative utility of processes within a category.
`public int` | `pid` The pid of this process; 0 if none
`public String[]` | `pkgList` All packages that have been loaded into the process.
`public String` | `processName` The name of the process that this object is associated with
`public int` | `uid` The user id of this process.

### Public constructors
`RunningAppProcessInfo()`
`RunningAppProcessInfo(String pProcessName, int pPid, String[] pArr)`

### Public methods
`int` | `describeContents()` Describe the kinds of special objects contained in this Parcelable instance's marshaled representation.
`void` | `readFromParcel(Parcel source)`
`void` | `writeToParcel(Parcel dest, int flags)` Flatten this object in to a Parcel.

### Inherited methods
From class `java.lang.Object`
`Object` | `clone()` Creates and returns a copy of this object.
`boolean` | `equals(Object obj)` Indicates whether some other object is "equal to" this one.
`void` | `finalize()` Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
`final Class<?>` | `getClass()` Returns the runtime class of this `Object`.
`int` | `hashCode()` Returns a hash code value for the object.
`final void` | `notify()` Wakes up a single thread that is waiting on this object's monitor.
`final void` | `notifyAll()` Wakes up all threads that are waiting on this object's monitor.
`String` | `toString()` Returns a string representation of the object.
`final void` | `wait(long timeout, int nanos)` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed.
`final void` | `wait(long timeout)` Causes the current thread to wait until either another thread invokes the `notify()` method or the `notifyAll()` method for this object, or a specified amount of time has elapsed.
`final void` | `wait()` Causes the current thread to wait until another thread invokes the `notify()` method or the `notifyAll()` method for this object.
From interface `android.os.Parcelable`
`abstract int` | `describeContents()` Describe the kinds of special objects contained in this Parcelable instance's marshaled representation.
`abstract void` | `writeToParcel(Parcel dest, int flags)` Flatten this object in to a Parcel.

## Constants

### IMPORTANCE_BACKGROUND

    public static final int IMPORTANCE_BACKGROUND

This constant is deprecated.
Renamed to `IMPORTANCE_CACHED`.

Constant Value: 400 (0x00000190)

### IMPORTANCE_CACHED

    public static final int IMPORTANCE_CACHED

Constant for `importance`: This process process contains cached code that is expendable, not actively running any app components we care about.

Constant Value: 400 (0x00000190)

### IMPORTANCE_CANT_SAVE_STATE

    public static final int IMPORTANCE_CANT_SAVE_STATE

Constant for `importance`: This process is running an application that can not save its state, and thus can't be killed while in the background. This will be used with apps that have `R.attr.cantSaveState` set on their application tag.

Constant Value: 350 (0x0000015e)

### IMPORTANCE_EMPTY

    public static final int IMPORTANCE_EMPTY

This constant is deprecated.
This value is no longer reported, use `IMPORTANCE_CACHED` instead.

Constant for `importance`: This process is empty of any actively running code.

Constant Value: 500 (0x000001f4)

### IMPORTANCE_FOREGROUND

    public static final int IMPORTANCE_FOREGROUND

Constant for `importance`: This process is running the foreground UI; that is, it is the thing currently at the top of the screen that the user is interacting with.

Constant Value: 100 (0x00000064)

### IMPORTANCE_FOREGROUND_SERVICE

    public static final int IMPORTANCE_FOREGROUND_SERVICE

Constant for `importance`: This process is running a foreground service, for example to perform music playback even while the user is not immediately in the app. This generally indicates that the process is doing something the user actively cares about.

Constant Value: 125 (0x0000007d)

### IMPORTANCE_GONE

    public static final int IMPORTANCE_GONE

Constant for `importance`: This process does not exist.

Constant Value: 1000 (0x000003e8)

### IMPORTANCE_PERCEPTIBLE

    public static final int IMPORTANCE_PERCEPTIBLE

Constant for `importance`: This process is not something the user is directly aware of, but is otherwise perceptible to them to some degree.

Constant Value: 230 (0x000000e6)

### IMPORTANCE_PERCEPTIBLE_PRE_26

    public static final int IMPORTANCE_PERCEPTIBLE_PRE_26

Constant for `importance`: `IMPORTANCE_PERCEPTIBLE` had this wrong value before `Build.VERSION_CODES#O`. Since the `Build.VERSION_CODES#O` SDK, the value of `IMPORTANCE_PERCEPTIBLE` has been fixed.

The system will return this value instead of `IMPORTANCE_PERCEPTIBLE` on Android versions below `Build.VERSION_CODES#O`.

On Android version `Build.VERSION_CODES#O` and later, this value will still be returned for apps with the target API level below `Build.VERSION_CODES#O`. For apps targeting version `Build.VERSION_CODES#O` and later, the correct value `IMPORTANCE_PERCEPTIBLE` will be returned.

Constant Value: 130 (0x00000082)

### IMPORTANCE_SERVICE

    public static final int IMPORTANCE_SERVICE

Constant for `importance`: This process contains services that should remain running. These are background services apps have started, not something the user is aware of, so they may be killed by the system relatively freely (though it is generally desired that they stay running as long as they want to).

Constant Value: 300 (0x0000012c)

### IMPORTANCE_TOP_SLEEPING

    public static final int IMPORTANCE_TOP_SLEEPING

Constant for `importance`: This process is running the foreground UI, but the device is asleep so it is not visible to the user. Though the system will try hard to keep its process from being killed, in all other ways we consider it a kind of cached process, with the limitations that go along with that state: network access, running background services, etc.

Constant Value: 325 (0x00000145)

### IMPORTANCE_TOP_SLEEPING_PRE_28

    public static final int IMPORTANCE_TOP_SLEEPING_PRE_28

This constant is deprecated.
Pre-`Build.VERSION_CODES.P` version of `IMPORTANCE_TOP_SLEEPING`. As of Android `Build.VERSION_CODES.P`, this is considered much less important since we want to reduce what apps can do when the screen is off.

Constant Value: 150 (0x00000096)

### IMPORTANCE_VISIBLE

    public static final int IMPORTANCE_VISIBLE

Constant for `importance`: This process is running something that is actively visible to the user, though not in the immediate foreground. This may be running a window that is behind the current foreground (so paused and with its state saved, not interacting with the user, but visible to them to some degree); it may also be running other services under the system's control that it inconsiders important.

Constant Value: 200 (0x000000c8)

### REASON_PROVIDER_IN_USE

    public static final int REASON_PROVIDER_IN_USE

Constant for `importanceReasonCode`: one of the application's content providers is being used by another process. The pid of the client process is in `importanceReasonPid` and the target provider in this process is in `importanceReasonComponent`.

Constant Value: 1 (0x00000001)

### REASON_SERVICE_IN_USE

    public static final int REASON_SERVICE_IN_USE

Constant for `importanceReasonCode`: one of the application's content providers is being used by another process. The pid of the client process is in `importanceReasonPid` and the target provider in this process is in `importanceReasonComponent`.

Constant Value: 2 (0x00000002)

### REASON_UNKNOWN

    public static final int REASON_UNKNOWN

Constant for `importanceReasonCode`: nothing special has been specified for the reason for this level.

Constant Value: 0 (0x00000000)

## Fields

### CREATOR

    public static final Creator<ActivityManager.RunningAppProcessInfo> CREATOR

### importance

    public int importance

The relative importance level that the system places on this process. These constants are numbered so that "more important" values are always smaller than "less important" values.
Value is `IMPORTANCE_FOREGROUND`, `IMPORTANCE_FOREGROUND_SERVICE`, `IMPORTANCE_TOP_SLEEPING`, `IMPORTANCE_VISIBLE`, `IMPORTANCE_PERCEPTIBLE`, `IMPORTANCE_CANT_SAVE_STATE`, `IMPORTANCE_SERVICE`, `IMPORTANCE_CACHED`, or `IMPORTANCE_GONE`

### importanceReasonCode

    public int importanceReasonCode

The reason for `importance`, if any.

### importanceReasonComponent

    public ComponentName importanceReasonComponent

For the specified values of `importanceReasonCode`, this is the name of the component that is being used in this process.

### importanceReasonPid

    public int importanceReasonPid

For the specified values of `importanceReasonCode`, this is the process ID of the other process that is a client of this process. This will be 0 if no other process is using this one.

### lastTrimLevel

    public int lastTrimLevel

Last memory trim level reported to the process: corresponds to the values supplied to `ComponentCallbacks2.onTrimMemory(int)`.

### lru

    public int lru

An additional ordering within a particular `importance` category, providing finer-grained information about the relative utility of processes within a category. This number means nothing except that a smaller values are more recently used (and thus more important). Currently an LRU value is only maintained for the `IMPORTANCE_CACHED` category, though others may be maintained in the future.

### pid

    public int pid

The pid of this process; 0 if none

### pkgList

    public String[] pkgList

All packages that have been loaded into the process.

### processName

    public String processName

The name of the process that this object is associated with

### uid

    public int uid

The user id of this process.

## Public constructors

### RunningAppProcessInfo

    public RunningAppProcessInfo ()

### RunningAppProcessInfo

    public RunningAppProcessInfo (String pProcessName,
                    int pPid,
                    String[] pArr)

Parameters
`pProcessName` | `String`
`pPid` | `int`
`pArr` | `String`

## Public methods

### describeContents

    public int describeContents ()

Describe the kinds of special objects contained in this Parcelable instance's marshaled representation. For example, if the object will include a file descriptor in the output of `writeToParcel(android.os.Parcel, int)`, the return value of this method must include the `CONTENTS_FILE_DESCRIPTOR` bit.

Returns
`int` | a bitmask indicating the set of special object types marshaled by this Parcelable object instance. Value is either `0` or `CONTENTS_FILE_DESCRIPTOR`

### readFromParcel

    public void readFromParcel (Parcel source)

Parameters
`source` | `Parcel`

### writeToParcel

    public void writeToParcel (Parcel dest,
                    int flags)

Flatten this object in to a Parcel.

Parameters
`dest` | `Parcel`: The Parcel in which the object should be written.
`flags` | `int`: Additional flags about how the object should be written. May be 0 or `Parcelable.PARCELABLE_WRITE_RETURN_VALUE`. Value is either `0` or a combination of `Parcelable.PARCELABLE_WRITE_RETURN_VALUE`, and android.os.Parcelable.PARCELABLE_ELIDE_DUPLICATES

Full name *
Email address *
Company / developer name
One of your Play Store app URLs *
Which best describes your business:*
Apps
Games
Apps & Games
*
*