Package ai.picovoice.orca
Class Orca.Builder
java.lang.Object
ai.picovoice.orca.Orca.Builder
- Enclosing class:
- Orca
Builder for creating instance of Orca.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild(android.content.Context context) Validates properties and creates an instance of the Orca Text-to-Speech engine.setAccessKey(String accessKey) Sets the AccessKey.setModelPath(String modelPath) Sets the path to the model file (`.pv`).
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
setAccessKey
Sets the AccessKey.- Parameters:
accessKey- AccessKey obtained from Picovoice Console (https://console.picovoice.ai/)- Returns:
- Modified builder object.
-
setModelPath
Sets the path to the model file (`.pv`).- Parameters:
modelPath- Absolute path to the file (`.pv`) containing Orca model parameters.- Returns:
- Modified builder object.
-
build
Validates properties and creates an instance of the Orca Text-to-Speech engine.- Returns:
- An instance Orca Text-to-Speech engine
- Throws:
OrcaException- if there is an error while initializing Orca.
-