public final class SpeechConfig extends Object
This class allows generic configuration properties to pass through various builder abstractions down to implementations. Configuration values may be primitive types and are registered in a global namespace. The pipeline performs the following primitive type conversions (input on rows).
integer | double | string | |
integer | * | * | * |
double | * | * | * |
string | * | * | * |
Constructor and Description |
---|
SpeechConfig()
initializes a default configuration instance.
|
SpeechConfig(Map<String,Object> value)
attaches an existing configuration map.
|
Modifier and Type | Method and Description |
---|---|
boolean |
containsKey(String key)
determines whether a configuration key is present.
|
double |
getDouble(String key)
fetches a double value.
|
double |
getDouble(String key,
Double defaultValue)
fetches a double value, coercing if needed.
|
int |
getInteger(String key)
fetches an integer value.
|
int |
getInteger(String key,
Integer defaultValue)
fetches an integer value, coercing if needed.
|
Map<String,Object> |
getParams() |
String |
getString(String key)
fetches a string value.
|
String |
getString(String key,
String defaultValue)
fetches a string value, coercing if needed.
|
SpeechConfig |
put(String key,
Object value)
writes a configuration value.
|
public boolean containsKey(String key)
key
- key to look uppublic String getString(String key, String defaultValue)
key
- key to look updefaultValue
- value to return if not foundpublic String getString(String key)
key
- key to look uppublic int getInteger(String key, Integer defaultValue)
key
- key to look updefaultValue
- value to return if not foundpublic int getInteger(String key)
key
- key to look uppublic double getDouble(String key, Double defaultValue)
key
- key to look updefaultValue
- value to return if not foundpublic double getDouble(String key)
key
- key to look uppublic SpeechConfig put(String key, Object value)
key
- key to putvalue
- value to store for the keyCopyright © 2020. All rights reserved.