• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2022 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef DATA_STORAGE_OPKEY_DATA_H
17 #define DATA_STORAGE_OPKEY_DATA_H
18 
19 namespace OHOS {
20 namespace Telephony {
21 class OpKeyData {
22 public:
23     static constexpr const char *ID = "id";
24     static constexpr const char *MCCMNC = "mccmnc";
25     static constexpr const char *GID1 = "gid1";
26     static constexpr const char *GID2 = "gid2";
27     static constexpr const char *IMSI = "imsi";
28     static constexpr const char *SPN = "spn";
29     static constexpr const char *ICCID = "iccid";
30     static constexpr const char *OPERATOR_NAME = "operator_name";
31     static constexpr const char *OPERATOR_KEY = "operator_key";
32     static constexpr const char *OPERATOR_KEY_EXT = "operator_key_ext";
33     static constexpr const char *RULE_ID = "rule_id";
34 };
35 
36 struct OpKey {
37     int opkeyId;
38     std::string mccmnc;
39     std::string gid1;
40     std::string gid2;
41     std::string imsi;
42     std::string spn;
43     std::string iccid;
44     std::string operatorName;
45     std::string operatorKey;
46     std::string operatorKeyExt;
47     int ruleId;
48 };
49 
50 constexpr const char *MCCMNC_INDEX = "mccmncIndex";
51 constexpr const char *TABLE_OPKEY_INFO = "opkey_info";
52 constexpr const char *OPKEY_URI = "dataability:///com.ohos.opkeyability";
53 } // namespace Telephony
54 } // namespace OHOS
55 #endif // DATA_STORAGE_OPKEY_DATA_H