Package net.idrnd.voicesdk.core
Class Settings
java.lang.Object
net.idrnd.voicesdk.core.Settings
Provides a way to control global VoiceSDK configuration.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic LicenseFeatureInfo[]Returns information (enabled features and expiration dates) about the installed license if available.static voidsetAllowMobileGPU(boolean allowMobileGPU) Sets whether GPU delegate allowed to be used for VoiceSDK (for Android devices only).static voidsetAllowMobileNNAPI(boolean allowMobileNNAPI) Sets whether NNAPI delegate allowed to be used for VoiceSDK (for Android devices only).static voidsetNumThreads(int numThreads) Sets the maximum number of threads available for VoiceSDK.static voidsetUseVoiceTemplateCompression(boolean useVoiceTemplateCompression) Sets whether to compress voice templates serialization.
-
Constructor Details
-
Settings
public Settings()
-
-
Method Details
-
setNumThreads
public static void setNumThreads(int numThreads) Sets the maximum number of threads available for VoiceSDK. If 0 passed, then the optimal number of threads is detected automatically (the same effect is achieved if setNumThreads is not called).- Parameters:
numThreads- maximum number of threads available for VoiceSDK.- Throws:
VoiceSdkEngineException- on negative numThreads
-
setAllowMobileNNAPI
public static void setAllowMobileNNAPI(boolean allowMobileNNAPI) Sets whether NNAPI delegate allowed to be used for VoiceSDK (for Android devices only).- Parameters:
allowMobileNNAPI- whether NNAPI is allowed to be used for VoiceSDK execution.
-
setAllowMobileGPU
public static void setAllowMobileGPU(boolean allowMobileGPU) Sets whether GPU delegate allowed to be used for VoiceSDK (for Android devices only).- Parameters:
allowMobileGPU- whether GPU is allowed to be used for VoiceSDK execution.
-
setUseVoiceTemplateCompression
public static void setUseVoiceTemplateCompression(boolean useVoiceTemplateCompression) Sets whether to compress voice templates serialization. Voice template compression is not used by default.- Parameters:
useVoiceTemplateCompression- whether to compress voice templates serialization.
-
getLicenseInfo
Returns information (enabled features and expiration dates) about the installed license if available.- Returns:
- Array of VoiceSDK features available with the installed license.
-