mirror of
https://gitee.com/openharmony/msdp_device_status
synced 2024-11-23 07:29:52 +00:00
Special modifications
Signed-off-by: wang_gang <wanggang323@huawei.com> Change-Id: Ibb33e7c80c3a2c87a19e2681568b721614b2b32d
This commit is contained in:
parent
0cee91d749
commit
891691dd34
@ -79,7 +79,7 @@ ErrCode DeviceStatusClient::Connect()
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
void DeviceStatusClient::ResetProxy(const wptr<IRemoteObject>& remote)
|
||||
void DeviceStatusClient::ResetProxy(const wptr<IRemoteObject> &remote)
|
||||
{
|
||||
std::lock_guard<std::mutex> lock(mutex_);
|
||||
CHKPV(devicestatusProxy_);
|
||||
@ -94,7 +94,7 @@ void DeviceStatusClient::ResetProxy(const wptr<IRemoteObject>& remote)
|
||||
}
|
||||
}
|
||||
|
||||
void DeviceStatusClient::DeviceStatusDeathRecipient::OnRemoteDied(const wptr<IRemoteObject>& remote)
|
||||
void DeviceStatusClient::DeviceStatusDeathRecipient::OnRemoteDied(const wptr<IRemoteObject> &remote)
|
||||
{
|
||||
CHKPV(remote);
|
||||
DeviceStatusClient::GetInstance().ResetProxy(remote);
|
||||
|
@ -26,7 +26,7 @@ namespace Msdp {
|
||||
namespace DeviceStatus {
|
||||
class IntentionProxy : public IRemoteProxy<IIntention> {
|
||||
public:
|
||||
explicit IntentionProxy(const sptr<IRemoteObject>& impl);
|
||||
explicit IntentionProxy(const sptr<IRemoteObject> &impl);
|
||||
DISALLOW_COPY_AND_MOVE(IntentionProxy);
|
||||
~IntentionProxy() = default;
|
||||
|
||||
|
@ -62,14 +62,14 @@ private:
|
||||
public:
|
||||
DeathRecipient(TunnelClient &parent);
|
||||
~DeathRecipient() = default;
|
||||
void OnRemoteDied(const wptr<IRemoteObject>& remote);
|
||||
void OnRemoteDied(const wptr<IRemoteObject> &remote);
|
||||
|
||||
private:
|
||||
TunnelClient &parent_;
|
||||
};
|
||||
|
||||
ErrCode Connect();
|
||||
void ResetProxy(const wptr<IRemoteObject>& remote);
|
||||
void ResetProxy(const wptr<IRemoteObject> &remote);
|
||||
|
||||
private:
|
||||
std::mutex mutex_;
|
||||
|
@ -331,7 +331,7 @@ ErrCode TunnelClient::Connect()
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
void TunnelClient::ResetProxy(const wptr<IRemoteObject>& remote)
|
||||
void TunnelClient::ResetProxy(const wptr<IRemoteObject> &remote)
|
||||
{
|
||||
CALL_DEBUG_ENTER;
|
||||
std::lock_guard<std::mutex> lock(mutex_);
|
||||
@ -351,7 +351,7 @@ TunnelClient::DeathRecipient::DeathRecipient(TunnelClient &parent)
|
||||
: parent_(parent)
|
||||
{}
|
||||
|
||||
void TunnelClient::DeathRecipient::OnRemoteDied(const wptr<IRemoteObject>& remote)
|
||||
void TunnelClient::DeathRecipient::OnRemoteDied(const wptr<IRemoteObject> &remote)
|
||||
{
|
||||
CALL_DEBUG_ENTER;
|
||||
CHKPV(remote);
|
||||
|
@ -63,7 +63,7 @@ private:
|
||||
int32_t AddTimerInternal(int32_t intervalMs, int32_t repeatCount, std::function<void()> callback);
|
||||
int32_t RemoveTimerInternal(int32_t timerId);
|
||||
int32_t ResetTimerInternal(int32_t timerId);
|
||||
void InsertTimerInternal(std::unique_ptr<TimerItem>& timer);
|
||||
void InsertTimerInternal(std::unique_ptr<TimerItem> &timer);
|
||||
int64_t CalcNextDelayInternal();
|
||||
void ProcessTimersInternal();
|
||||
int32_t ArmTimer();
|
||||
|
@ -216,7 +216,7 @@ int32_t TimerManager::ResetTimerInternal(int32_t timerId)
|
||||
return RET_ERR;
|
||||
}
|
||||
|
||||
void TimerManager::InsertTimerInternal(std::unique_ptr<TimerItem>& timer)
|
||||
void TimerManager::InsertTimerInternal(std::unique_ptr<TimerItem> &timer)
|
||||
{
|
||||
for (auto tIter = timers_.begin(); tIter != timers_.end(); ++tIter) {
|
||||
if ((*tIter)->nextCallTime > timer->nextCallTime) {
|
||||
|
@ -84,14 +84,14 @@ private:
|
||||
public:
|
||||
DeviceStatusDeathRecipient() = default;
|
||||
~DeviceStatusDeathRecipient() = default;
|
||||
void OnRemoteDied(const wptr<IRemoteObject>& remote);
|
||||
void OnRemoteDied(const wptr<IRemoteObject> &remote);
|
||||
|
||||
private:
|
||||
DISALLOW_COPY_AND_MOVE(DeviceStatusDeathRecipient);
|
||||
};
|
||||
|
||||
ErrCode Connect();
|
||||
void ResetProxy(const wptr<IRemoteObject>& remote);
|
||||
void ResetProxy(const wptr<IRemoteObject> &remote);
|
||||
|
||||
sptr<Idevicestatus> devicestatusProxy_ { nullptr };
|
||||
sptr<IRemoteObject::DeathRecipient> deathRecipient_ { nullptr };
|
||||
|
@ -54,8 +54,8 @@ public:
|
||||
virtual ~DeviceStatusMock() = default;
|
||||
void OnResult(const Data& data) {};
|
||||
};
|
||||
int32_t LoadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle>& algoHandler);
|
||||
int32_t UnloadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle>& algoHandler);
|
||||
int32_t LoadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle> &algoHandler);
|
||||
int32_t UnloadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle> &algoHandler);
|
||||
};
|
||||
|
||||
void DeviceStatusAlgorithmTest::SetUpTestCase()
|
||||
@ -72,7 +72,7 @@ void DeviceStatusAlgorithmTest::SetUp() {}
|
||||
|
||||
void DeviceStatusAlgorithmTest::DeviceStatusAlgorithmTest::TearDown() {}
|
||||
|
||||
int32_t DeviceStatusAlgorithmTest::LoadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle>& algoHandler)
|
||||
int32_t DeviceStatusAlgorithmTest::LoadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle> &algoHandler)
|
||||
{
|
||||
FI_HILOGI("Enter");
|
||||
if (algoHandler == nullptr) {
|
||||
@ -108,7 +108,7 @@ int32_t DeviceStatusAlgorithmTest::LoadAlgoLibrary(const std::shared_ptr<MsdpAlg
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
int32_t DeviceStatusAlgorithmTest::UnloadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle>& algoHandler)
|
||||
int32_t DeviceStatusAlgorithmTest::UnloadAlgoLibrary(const std::shared_ptr<MsdpAlgoHandle> &algoHandler)
|
||||
{
|
||||
FI_HILOGI("Enter");
|
||||
if (algoHandler == nullptr) {
|
||||
|
@ -49,8 +49,8 @@ public:
|
||||
static void TearDownTestCase();
|
||||
void SetUp();
|
||||
void TearDown();
|
||||
int32_t LoadMockLibrary(const std::shared_ptr<MsdpAlgoHandle>& mockHandler);
|
||||
int32_t UnloadMockLibrary(const std::shared_ptr<MsdpAlgoHandle>& mockHandler);
|
||||
int32_t LoadMockLibrary(const std::shared_ptr<MsdpAlgoHandle> &mockHandler);
|
||||
int32_t UnloadMockLibrary(const std::shared_ptr<MsdpAlgoHandle> &mockHandler);
|
||||
};
|
||||
|
||||
void DeviceStatusMsdpMocKTest::SetUpTestCase()
|
||||
@ -67,7 +67,7 @@ void DeviceStatusMsdpMocKTest::SetUp() {}
|
||||
|
||||
void DeviceStatusMsdpMocKTest::TearDown() {}
|
||||
|
||||
int32_t DeviceStatusMsdpMocKTest::LoadMockLibrary(const std::shared_ptr<MsdpAlgoHandle>& mockHandler)
|
||||
int32_t DeviceStatusMsdpMocKTest::LoadMockLibrary(const std::shared_ptr<MsdpAlgoHandle> &mockHandler)
|
||||
{
|
||||
FI_HILOGI("Enter");
|
||||
if (mockHandler == nullptr) {
|
||||
@ -103,7 +103,7 @@ int32_t DeviceStatusMsdpMocKTest::LoadMockLibrary(const std::shared_ptr<MsdpAlgo
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
int32_t DeviceStatusMsdpMocKTest::UnloadMockLibrary(const std::shared_ptr<MsdpAlgoHandle>& mockHandler)
|
||||
int32_t DeviceStatusMsdpMocKTest::UnloadMockLibrary(const std::shared_ptr<MsdpAlgoHandle> &mockHandler)
|
||||
{
|
||||
FI_HILOGI("Enter");
|
||||
if (mockHandler == nullptr) {
|
||||
|
@ -63,7 +63,7 @@ private:
|
||||
int32_t AddTimerInternal(int32_t intervalMs, int32_t repeatCount, std::function<void()> callback);
|
||||
int32_t ResetTimerInternal(int32_t timerId);
|
||||
int32_t RemoveTimerInternal(int32_t timerId);
|
||||
void InsertTimerInternal(std::unique_ptr<TimerItem>& timer);
|
||||
void InsertTimerInternal(std::unique_ptr<TimerItem> &timer);
|
||||
void ProcessTimersInternal();
|
||||
int64_t CalcNextDelayInternal();
|
||||
int32_t ArmTimer();
|
||||
|
@ -102,4 +102,4 @@ RosenCurveType AnimationCurve::CreateStepsCurve(const std::vector<float> &curve)
|
||||
|
||||
} // namespace DeviceStatus
|
||||
} // namespace Msdp
|
||||
} // namespace OHO
|
||||
} // namespace OHOS
|
||||
|
@ -68,7 +68,7 @@ protected:
|
||||
const int32_t pid_ { -1 };
|
||||
int32_t tokenType_ { TokenType::TOKEN_INVALID };
|
||||
};
|
||||
} // namespace DeviceStatus
|
||||
} // namespace Msdp
|
||||
} // namespace OHOS
|
||||
} // namespace DeviceStatus
|
||||
#endif // STREAM_SESSION_H
|
Loading…
Reference in New Issue
Block a user