• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1  /*
2   * Copyright (C) 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  #pragma once
18  
19  #include <stddef.h>
20  #include <stdint.h>
21  #include <sys/cdefs.h>
22  
23  __BEGIN_DECLS
24  
25  enum AnnotationIds : uint8_t {
26      /**
27       * Annotation ID constant for logging UID field.
28       *
29       * Introduced in API 31.
30       */
31      ASTATSLOG_ANNOTATION_ID_IS_UID = 1,
32  
33      /**
34       * Annotation ID constant to indicate logged atom event's timestamp should be truncated.
35       *
36       * Introduced in API 31.
37       */
38      ASTATSLOG_ANNOTATION_ID_TRUNCATE_TIMESTAMP = 2,
39  
40      /**
41       * Annotation ID constant for a state atom's primary field.
42       *
43       * Introduced in API 31.
44       */
45      ASTATSLOG_ANNOTATION_ID_PRIMARY_FIELD = 3,
46  
47      /**
48       * Annotation ID constant for state atom's state field.
49       *
50       * Introduced in API 31.
51       */
52      ASTATSLOG_ANNOTATION_ID_EXCLUSIVE_STATE = 4,
53  
54      /**
55       * Annotation ID constant to indicate the first UID in the attribution chain
56       * is a primary field.
57       *
58       * Introduced in API 31.
59       */
60      ASTATSLOG_ANNOTATION_ID_PRIMARY_FIELD_FIRST_UID = 5,
61  
62      /**
63       * Annotation ID constant to indicate which state is default for the state atom.
64       *
65       * Introduced in API 31.
66       */
67      ASTATSLOG_ANNOTATION_ID_DEFAULT_STATE = 6,
68  
69      /**
70       * Annotation ID constant to signal that all states should be reset to the default state.
71       *
72       * Introduced in API 31.
73       */
74      ASTATSLOG_ANNOTATION_ID_TRIGGER_STATE_RESET = 7,
75  
76      /**
77       * Annotation ID constant to indicate state changes need to account for nesting.
78       * This should only be used with binary state atoms.
79       *
80       * Introduced in API 31.
81       */
82      ASTATSLOG_ANNOTATION_ID_STATE_NESTED = 8,
83  };
84  
85  __END_DECLS
86