72 lines
1.7 KiB
C
Raw Normal View History

2025-03-12 11:08:50 +08:00
/**
@file DogAuthImpl.h
@brief
@author
*/
#pragma once
#include "sys_license_auth_api/LicenseAuthInterface.h"
#include "sys_dog_auth_api/DogAuthInterface.h"
#ifndef DISABLE_DOG_AUTH
#ifdef KBD_X86
#include "sys_dog_auth_api/dog_api.h"
#endif
#endif
2025-03-12 14:17:01 +08:00
namespace iot_sys
2025-03-12 11:08:50 +08:00
{
class CDogAuthImpl : public CDogAuthInterface
{
public:
explicit CDogAuthImpl();
virtual ~CDogAuthImpl();
/**
@brief
@return kbdSucces,
*/
virtual int checkAuthStatus() override;
/**
@brief
@return kbdSucces,
*/
int initialize();
protected:
/**
@brief
@return kbdSucces,
*/
int checkDogAuthStatus();
/**
@brief License授权状态
@return kbdSucces,
*/
int checLicenseAuthStatus();
/**
* @brief :CDogAuthImpl::loginSupperDog()
*
2025-03-12 14:54:22 +08:00
* @return iotSuccessiotFailed
2025-03-12 11:08:50 +08:00
*/
int loginSupperDog(int nProductId);
private:
#ifndef DISABLE_DOG_AUTH
#ifdef KBD_X86
dog_status_t m_dogStatus;
dog_handle_t m_dogHandle;
#endif
#endif
CLicenseAuthInterfacePtr m_ptrLicenseAuth;
int m_nProductId;
int m_nAuthModel;//授权模式
};
typedef boost::shared_ptr<CDogAuthImpl> CDogAuthImplPtr;
}
2025-03-12 14:17:01 +08:00
//namespace iot_sys
2025-03-12 11:08:50 +08:00