1 /* 2 * Copyright (c) 2022-2023 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 "daudio_source_dev_ctrl_mgr.h" 17 18 #include "audio_param.h" 19 #include "daudio_constants.h" 20 #include "daudio_errorcode.h" 21 #include "daudio_log.h" 22 #include "daudio_util.h" 23 24 #undef DH_LOG_TAG 25 #define DH_LOG_TAG "DAudioSourceDevCtrlMgr" 26 27 namespace OHOS { 28 namespace DistributedHardware { DAudioSourceDevCtrlMgr(const std::string & devId,std::shared_ptr<IAudioEventCallback> audioEventCallback)29DAudioSourceDevCtrlMgr::DAudioSourceDevCtrlMgr(const std::string &devId, 30 std::shared_ptr<IAudioEventCallback> audioEventCallback) 31 { 32 DHLOGD("Control manager constructed."); 33 } 34 ~DAudioSourceDevCtrlMgr()35DAudioSourceDevCtrlMgr::~DAudioSourceDevCtrlMgr() 36 { 37 DHLOGD("Control manager deconstructed."); 38 } 39 SetUp()40int32_t DAudioSourceDevCtrlMgr::SetUp() 41 { 42 DHLOGI("Set up source device control manager."); 43 return DH_SUCCESS; 44 } 45 Start()46int32_t DAudioSourceDevCtrlMgr::Start() 47 { 48 DHLOGI("Start source device control manager."); 49 return DH_SUCCESS; 50 } 51 Stop()52int32_t DAudioSourceDevCtrlMgr::Stop() 53 { 54 return DH_SUCCESS; 55 } 56 Release()57int32_t DAudioSourceDevCtrlMgr::Release() 58 { 59 DHLOGI("Release source device control manager."); 60 return DH_SUCCESS; 61 } 62 IsOpened()63bool DAudioSourceDevCtrlMgr::IsOpened() 64 { 65 return true; 66 } 67 SendAudioEvent(const AudioEvent & event)68int32_t DAudioSourceDevCtrlMgr::SendAudioEvent(const AudioEvent &event) 69 { 70 DHLOGD("Send audio event."); 71 return DH_SUCCESS; 72 } 73 } // namespace DistributedHardware 74 } // namespace OHOS 75