net.facelib.mtfsdk.DetectLicenseManager Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mtfsdk-android-common Show documentation
Show all versions of mtfsdk-android-common Show documentation
mtfsdk common(detection included) for android
package net.facelib.mtfsdk;
import net.facelib.jni.BaseFacelibLicenseManager;
import net.facelib.jni.SdkStatus;
import net.gdface.utils.Judge;
import static net.facelib.mtfsdk.DetectAndroidArmBridge.*;
/**
* MTFSDK android/arm 授权信息管理对象基类
* @author guyadong
*
*/
public class DetectLicenseManager extends BaseFacelibLicenseManager {
public DetectLicenseManager() {
}
@Override
public boolean validateLicense(String licenseKey, String licenseCode) {
if(!Judge.isEmpty(licenseKey) && !Judge.isEmpty(licenseCode)){
DetectAndroidArmBridge tmp = new DetectAndroidArmBridge();
SdkStatus fdSdkStatus = fdInit(licenseKey,licenseCode,tmp);
if(fdSdkStatus == SdkStatus.SDK_INIT_OK){
FDDestroy(tmp.detectHandle[0]);
return true;
}
}
return false;
}
}