| /* |
| * Copyright (C) 2017 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| syntax = "proto2"; |
| |
| package android.app; |
| |
| option java_multiple_files = true; |
| |
| // ActivityManager.java PROCESS_STATEs |
| enum ProcessState { |
| // Order matters for process states, so values have been spaced to provide |
| // room for future additions. |
| |
| // Not a real process state. |
| PROCESS_STATE_UNKNOWN = -100; |
| // Process is a persistent system process. |
| PROCESS_STATE_PERSISTENT = 0; |
| // Process is a persistent system process and is doing UI. |
| PROCESS_STATE_PERSISTENT_UI = 100; |
| // Process is hosting the current top activities. Note that this covers |
| // all activities that are visible to the user. |
| PROCESS_STATE_TOP = 200; |
| // Process is hosting a foreground service due to a system binding. |
| PROCESS_STATE_BOUND_FOREGROUND_SERVICE = 300; |
| // Process is hosting a foreground service. |
| PROCESS_STATE_FOREGROUND_SERVICE = 400; |
| // Process is important to the user, and something they are aware of. |
| PROCESS_STATE_IMPORTANT_FOREGROUND = 500; |
| // Process is important to the user, but not something they are aware of. |
| PROCESS_STATE_IMPORTANT_BACKGROUND = 600; |
| // Process is in the background transient so we will try to keep running. |
| PROCESS_STATE_TRANSIENT_BACKGROUND = 700; |
| // Process is in the background running a backup/restore operation. |
| PROCESS_STATE_BACKUP = 800; |
| // Process is in the background running a service. Unlike oom_adj, this |
| // level is used for both the normal running in background state and the |
| // executing operations state. |
| PROCESS_STATE_SERVICE = 900; |
| // Process is in the background running a receiver. Note that from the |
| // perspective of oom_adj, receivers run at a higher foreground level, but |
| // for our prioritization here that is not necessary and putting them |
| // below services means many fewer changes in some process states as they |
| // receive broadcasts. |
| PROCESS_STATE_RECEIVER = 1000; |
| // Same as PROCESS_STATE_TOP but while device is sleeping. |
| PROCESS_STATE_TOP_SLEEPING = 1100; |
| // Process is in the background, but it can't restore its state so we want |
| // to try to avoid killing it. |
| PROCESS_STATE_HEAVY_WEIGHT = 1200; |
| // Process is in the background but hosts the home activity. |
| PROCESS_STATE_HOME = 1300; |
| // Process is in the background but hosts the last shown activity. |
| PROCESS_STATE_LAST_ACTIVITY = 1400; |
| // Process is being cached for later use and contains activities. |
| PROCESS_STATE_CACHED_ACTIVITY = 1500; |
| // Process is being cached for later use and is a client of another cached |
| // process that contains activities. |
| PROCESS_STATE_CACHED_ACTIVITY_CLIENT = 1600; |
| // Process is being cached for later use and has an activity that corresponds |
| // to an existing recent task. |
| PROCESS_STATE_CACHED_RECENT = 1700; |
| // Process is being cached for later use and is empty. |
| PROCESS_STATE_CACHED_EMPTY = 1800; |
| // Process does not exist. |
| PROCESS_STATE_NONEXISTENT = 1900; |
| } |
| |