1 /*
2 * Copyright (c) 2021-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 #include "comm_log.h"
17 #include "if_softbus_client.h"
18 #include "softbus_error_code.h"
19
20 namespace OHOS {
OnChannelOpened(const char * sessionName,const ChannelInfo * channel)21 int32_t ISoftBusClient::OnChannelOpened(const char *sessionName, const ChannelInfo *channel)
22 {
23 COMM_LOGI(COMM_EVENT, "ipc default impl");
24 return SOFTBUS_OK;
25 }
26
OnChannelOpenFailed(int32_t channelId,int32_t channelType,int32_t errCode)27 int32_t ISoftBusClient::OnChannelOpenFailed(int32_t channelId, int32_t channelType, int32_t errCode)
28 {
29 COMM_LOGI(COMM_EVENT, "ipc default impl");
30 return SOFTBUS_OK;
31 }
32
OnChannelLinkDown(const char * networkId,int32_t routeType)33 int32_t ISoftBusClient::OnChannelLinkDown(const char *networkId, int32_t routeType)
34 {
35 COMM_LOGI(COMM_EVENT, "ipc default impl");
36 return SOFTBUS_OK;
37 }
38
OnChannelMsgReceived(int32_t channelId,int32_t channelType,const void * data,uint32_t len,int32_t type)39 int32_t ISoftBusClient::OnChannelMsgReceived(int32_t channelId, int32_t channelType, const void *data,
40 uint32_t len, int32_t type)
41 {
42 COMM_LOGI(COMM_EVENT, "ipc default impl");
43 return SOFTBUS_OK;
44 }
45
OnChannelClosed(int32_t channelId,int32_t channelType,int32_t messageType)46 int32_t ISoftBusClient::OnChannelClosed(int32_t channelId, int32_t channelType, int32_t messageType)
47 {
48 COMM_LOGI(COMM_EVENT, "ipc default impl");
49 return SOFTBUS_OK;
50 }
51
OnChannelQosEvent(int32_t channelId,int32_t channelType,int32_t eventId,int32_t tvCount,const QosTv * tvList)52 int32_t ISoftBusClient::OnChannelQosEvent(int32_t channelId, int32_t channelType, int32_t eventId, int32_t tvCount,
53 const QosTv *tvList)
54 {
55 COMM_LOGI(COMM_EVENT, "ipc default impl");
56 return SOFTBUS_OK;
57 }
58
SetChannelInfo(const char * sessionName,int32_t sessionId,int32_t channelId,int32_t channelType)59 int32_t ISoftBusClient::SetChannelInfo(const char *sessionName, int32_t sessionId,
60 int32_t channelId, int32_t channelType)
61 {
62 COMM_LOGI(COMM_EVENT, "ipc default impl");
63 return SOFTBUS_OK;
64 }
65
OnJoinLNNResult(void * addr,uint32_t addrTypeLen,const char * networkId,int retCode)66 int32_t ISoftBusClient::OnJoinLNNResult(void *addr, uint32_t addrTypeLen, const char *networkId, int retCode)
67 {
68 COMM_LOGI(COMM_EVENT, "ipc default impl");
69 return SOFTBUS_OK;
70 }
71
OnJoinMetaNodeResult(void * addr,uint32_t addrTypeLen,void * metaInfo,uint32_t infoLen,int retCode)72 int32_t ISoftBusClient::OnJoinMetaNodeResult(void *addr, uint32_t addrTypeLen, void *metaInfo, uint32_t infoLen,
73 int retCode)
74 {
75 COMM_LOGI(COMM_EVENT, "ipc default impl");
76 return SOFTBUS_OK;
77 }
78
OnLeaveLNNResult(const char * networkId,int retCode)79 int32_t ISoftBusClient::OnLeaveLNNResult(const char *networkId, int retCode)
80 {
81 COMM_LOGI(COMM_EVENT, "ipc default impl");
82 return SOFTBUS_OK;
83 }
84
OnLeaveMetaNodeResult(const char * networkId,int retCode)85 int32_t ISoftBusClient::OnLeaveMetaNodeResult(const char *networkId, int retCode)
86 {
87 COMM_LOGI(COMM_EVENT, "ipc default impl");
88 return SOFTBUS_OK;
89 }
90
OnNodeOnlineStateChanged(const char * pkgName,bool isOnline,void * info,uint32_t infoTypeLen)91 int32_t ISoftBusClient::OnNodeOnlineStateChanged(const char *pkgName, bool isOnline, void *info, uint32_t infoTypeLen)
92 {
93 COMM_LOGI(COMM_EVENT, "ipc default impl");
94 return SOFTBUS_OK;
95 }
96
OnNodeBasicInfoChanged(const char * pkgName,void * info,uint32_t infoTypeLen,int32_t type)97 int32_t ISoftBusClient::OnNodeBasicInfoChanged(const char *pkgName, void *info, uint32_t infoTypeLen, int32_t type)
98 {
99 COMM_LOGI(COMM_EVENT, "ipc default impl");
100 return SOFTBUS_OK;
101 }
102
OnNodeStatusChanged(const char * pkgName,void * info,uint32_t infoTypeLen,int32_t type)103 int32_t ISoftBusClient::OnNodeStatusChanged(const char *pkgName, void *info, uint32_t infoTypeLen, int32_t type)
104 {
105 (void)pkgName;
106 (void)info;
107 (void)infoTypeLen;
108 (void)type;
109 COMM_LOGI(COMM_EVENT, "ipc default impl");
110 return SOFTBUS_OK;
111 }
112
OnLocalNetworkIdChanged(const char * pkgName)113 int32_t ISoftBusClient::OnLocalNetworkIdChanged(const char *pkgName)
114 {
115 COMM_LOGI(COMM_EVENT, "ipc default impl");
116 return SOFTBUS_OK;
117 }
118
OnNodeDeviceNotTrusted(const char * pkgName,const char * msg)119 int32_t ISoftBusClient::OnNodeDeviceNotTrusted(const char *pkgName, const char *msg)
120 {
121 COMM_LOGI(COMM_EVENT, "ipc default impl");
122 return SOFTBUS_OK;
123 }
124
OnHichainProofException(const char * pkgName,const char * proofInfo,uint32_t proofLen,uint16_t deviceTypeId,int32_t errCode)125 int32_t ISoftBusClient::OnHichainProofException(
126 const char *pkgName, const char *proofInfo, uint32_t proofLen, uint16_t deviceTypeId, int32_t errCode)
127 {
128 (void)pkgName;
129 (void)proofInfo;
130 (void)proofLen;
131 (void)deviceTypeId;
132 (void)errCode;
133 COMM_LOGI(COMM_EVENT, "ipc default impl");
134 return SOFTBUS_OK;
135 }
136
OnTimeSyncResult(const void * info,uint32_t infoTypeLen,int32_t retCode)137 int32_t ISoftBusClient::OnTimeSyncResult(const void *info, uint32_t infoTypeLen, int32_t retCode)
138 {
139 COMM_LOGI(COMM_EVENT, "ipc default impl");
140 return SOFTBUS_OK;
141 }
142
OnPublishLNNResult(int32_t publishId,int32_t reason)143 void ISoftBusClient::OnPublishLNNResult(int32_t publishId, int32_t reason)
144 {
145 COMM_LOGI(COMM_EVENT, "ipc default impl");
146 }
147
OnRefreshLNNResult(int32_t refreshId,int32_t reason)148 void ISoftBusClient::OnRefreshLNNResult(int32_t refreshId, int32_t reason)
149 {
150 COMM_LOGI(COMM_EVENT, "ipc default impl");
151 }
152
OnRefreshDeviceFound(const void * device,uint32_t deviceLen)153 void ISoftBusClient::OnRefreshDeviceFound(const void *device, uint32_t deviceLen)
154 {
155 COMM_LOGI(COMM_EVENT, "ipc default impl");
156 }
157
OnDataLevelChanged(const char * networkId,const DataLevelInfo * dataLevelInfo)158 void ISoftBusClient::OnDataLevelChanged(const char *networkId, const DataLevelInfo *dataLevelInfo)
159 {
160 COMM_LOGI(COMM_EVENT, "ipc default impl");
161 }
162
OnClientTransLimitChange(int32_t channelId,uint8_t tos)163 int32_t ISoftBusClient::OnClientTransLimitChange(int32_t channelId, uint8_t tos)
164 {
165 COMM_LOGI(COMM_EVENT, "ipc default impl");
166 return SOFTBUS_OK;
167 }
168
OnChannelBind(int32_t channelId,int32_t channelType)169 int32_t ISoftBusClient::OnChannelBind(int32_t channelId, int32_t channelType)
170 {
171 COMM_LOGI(COMM_EVENT, "ipc default impl");
172 return SOFTBUS_OK;
173 }
174
OnClientChannelOnQos(int32_t channelId,int32_t channelType,QoSEvent event,const QosTV * qos,uint32_t count)175 int32_t ISoftBusClient::OnClientChannelOnQos(
176 int32_t channelId, int32_t channelType, QoSEvent event, const QosTV *qos, uint32_t count)
177 {
178 (void)channelId;
179 (void)channelType;
180 (void)event;
181 (void)qos;
182 (void)count;
183 COMM_LOGI(COMM_EVENT, "ipc default impl");
184 return SOFTBUS_OK;
185 }
186 } // namespace OHOS
187