50 lines
924 B
C++
50 lines
924 B
C++
#include "precomp.h"
|
|
#include "uniconv.h"
|
|
#include "template.h"
|
|
#include "validator.h"
|
|
#include "sdkregistration.h"
|
|
#include "version.h"
|
|
|
|
#include <time.h>
|
|
|
|
bool SDKRegistrationImpl::isRegistered = true;
|
|
bool SDKRegistrationImpl::isExpired = false;
|
|
string SDKRegistrationImpl::licenseKey;
|
|
|
|
void SDKRegistrationImpl::SetLicenseKey(const char * key)
|
|
{
|
|
licenseKey = key;
|
|
}
|
|
|
|
bool SDKRegistrationImpl::IsRegistered()
|
|
{
|
|
return true;
|
|
}
|
|
|
|
bool SDKRegistrationImpl::IsExpired()
|
|
{
|
|
return false;
|
|
}
|
|
|
|
const char * SDKRegistrationImpl::GetLicenseKey()
|
|
{
|
|
return licenseKey.c_str();
|
|
}
|
|
|
|
namespace ANSCENTER {
|
|
namespace Licensing {
|
|
template<>
|
|
void SDKRegistrationT<char>::SetLicenseKey(const char * key)
|
|
{
|
|
SDKRegistrationImpl::SetLicenseKey(key);
|
|
}
|
|
|
|
template<>
|
|
void SDKRegistrationT<wchar_t>::SetLicenseKey(const wchar_t * key)
|
|
{
|
|
string wkey = w2s(key);
|
|
SDKRegistrationImpl::SetLicenseKey(wkey.c_str());
|
|
}
|
|
};
|
|
};
|