• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2024 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 TELEPHONY_OBSERVER_FFI_H
17 #define TELEPHONY_OBSERVER_FFI_H
18 
19 #include "ffi_remote_data.h"
20 #include "telephony_observer_utils.h"
21 
22 namespace OHOS {
23 namespace Telephony {
24 extern "C" {
25     FFI_EXPORT int32_t FfiTelephonyObserverOnNetworkStateChange(ObserverOptions options, int64_t funcId);
26     FFI_EXPORT int32_t FfiTelephonyObserverOffNetworkStateChange(int64_t funcId);
27     FFI_EXPORT int32_t FfiTelephonyObserverOffAllNetworkStateChange();
28     FFI_EXPORT int32_t FfiTelephonyObserverOnSignalInfoChange(ObserverOptions options, int64_t funcId);
29     FFI_EXPORT int32_t FfiTelephonyObserverOffSignalInfoChange(int64_t funcId);
30     FFI_EXPORT int32_t FfiTelephonyObserverOffAllSignalInfoChange();
31     FFI_EXPORT int32_t FfiTelephonyObserverOnCallStateChange(ObserverOptions options, int64_t funcId);
32     FFI_EXPORT int32_t FfiTelephonyObserverOffCallStateChange(int64_t funcId);
33     FFI_EXPORT int32_t FfiTelephonyObserverOffAllCallStateChange();
34     FFI_EXPORT int32_t FfiTelephonyObserverOnCellularDataConnectionStateChange(
35         ObserverOptions options,
36         int64_t funcId);
37     FFI_EXPORT int32_t FfiTelephonyObserverOffCellularDataConnectionStateChange(int64_t funcId);
38     FFI_EXPORT int32_t FfiTelephonyObserverOffAllCellularDataConnectionStateChange();
39     FFI_EXPORT int32_t FfiTelephonyObserverOnCellularDataFlowChange(ObserverOptions options, int64_t funcId);
40     FFI_EXPORT int32_t FfiTelephonyObserverOffCellularDataFlowChange(int64_t funcId);
41     FFI_EXPORT int32_t FfiTelephonyObserverOffAllCellularDataFlowChange();
42     FFI_EXPORT int32_t FfiTelephonyObserverOnSimStateChange(ObserverOptions options, int64_t funcId);
43     FFI_EXPORT int32_t FfiTelephonyObserverOffSimStateChange(int64_t funcId);
44     FFI_EXPORT int32_t FfiTelephonyObserverOffAllSimStateChange();
45     FFI_EXPORT int32_t FfiTelephonyObserverOnIccAccountInfoChange(int64_t funcId);
46     FFI_EXPORT int32_t FfiTelephonyObserverOffIccAccountInfoChange(int64_t funcId);
47     FFI_EXPORT int32_t FfiTelephonyObserverOffAllIccAccountInfoChange();
48 }
49 }
50 }
51 
52 #endif