1 /* 2 * Copyright 2020 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package android.uwb; 18 19 /** 20 * @hide 21 */ 22 @Backing(type="int") 23 enum RangingChangeReason { 24 /** 25 * Unknown reason 26 */ 27 UNKNOWN, 28 29 /** 30 * A local API call triggered the change, such as a call to 31 * IUwbAdapter.closeRanging. 32 */ 33 LOCAL_API, 34 35 /** 36 * The maximum number of sessions has been reached. This may be generated for 37 * an active session if a higher priority session begins. 38 */ 39 MAX_SESSIONS_REACHED, 40 41 /** 42 * The system state has changed resulting in the session changing (e.g. the 43 * user disables UWB, or the user's locale changes and an active channel is no 44 * longer permitted to be used). 45 */ 46 SYSTEM_POLICY, 47 48 /** 49 * The remote device has requested to change the session 50 */ 51 REMOTE_REQUEST, 52 53 /** 54 * The session changed for a protocol specific reason 55 */ 56 PROTOCOL_SPECIFIC, 57 58 /** 59 * The provided parameters were invalid 60 */ 61 BAD_PARAMETERS, 62 } 63 64