| /* |
| * Copyright (C) 2023 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.stats.dnd; |
| |
| option java_package = "com.android.os.dnd"; |
| option java_multiple_files = true; |
| option java_outer_classname = "DNDProtoEnums"; |
| |
| // Enum used in DNDModeProto. |
| enum ZenMode { |
| ROOT_CONFIG = -1; // Used to distinguish the config (one per user) from the rules. |
| ZEN_MODE_OFF = 0; |
| ZEN_MODE_IMPORTANT_INTERRUPTIONS = 1; |
| ZEN_MODE_NO_INTERRUPTIONS = 2; |
| ZEN_MODE_ALARMS = 3; |
| } |
| |
| // Enum used in DNDPolicyProto for a particular policy parameter's state. |
| enum State { |
| STATE_UNSET = 0; |
| STATE_ALLOW = 1; |
| STATE_DISALLOW = 2; |
| } |
| |
| // Enum used in DNDPolicyProto for which people are allowed to break through. |
| enum PeopleType { |
| PEOPLE_UNSET = 0; |
| PEOPLE_ANYONE = 1; |
| PEOPLE_CONTACTS = 2; |
| PEOPLE_STARRED = 3; |
| PEOPLE_NONE = 4; |
| } |
| |
| // Enum used in DNDPolicyProto for conversation types allowed to break through. |
| enum ConversationType { |
| CONV_UNSET = 0; |
| CONV_ANYONE = 1; |
| CONV_IMPORTANT = 2; |
| CONV_NONE = 3; |
| } |
| |
| // Enum used in DNDPolicyProto to indicate the type of channels permitted to |
| // break through DND. Mirrors values in ZenPolicy. |
| enum ChannelType { |
| CHANNEL_TYPE_UNSET = 0; |
| CHANNEL_TYPE_PRIORITY = 1; |
| CHANNEL_TYPE_NONE = 2; |
| } |
| |
| // Enum used in DNDStateChanged to identify the type of rule that changed. |
| enum RuleType { |
| UNKNOWN_RULE = 0; |
| MANUAL_RULE = 1; |
| AUTOMATIC_RULE = 2; |
| } |