public class ToneAnalyzer extends WatsonService
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
VERSION_DATE_2016_05_19
The Constant VERSION_DATE_2016_05_19.
|
defaultHeaders, MESSAGE_CODE, MESSAGE_ERROR, skipAuthentication, VERSION| Constructor and Description |
|---|
ToneAnalyzer(java.lang.String versionDate)
Instantiates a new tone analyzer.
|
ToneAnalyzer(java.lang.String versionDate,
java.lang.String username,
java.lang.String password)
Instantiates a new tone analyzer with username and password.
|
| Modifier and Type | Method and Description |
|---|---|
ServiceCall<UtterancesTone> |
getChatTone(ToneChatRequest chatInput)
Analyzes the "tone" of a list of utterances in a conversation.
|
ServiceCall<ToneAnalysis> |
getTone(java.lang.String text,
ToneOptions options)
Analyzes the "tone" of a piece of text.
|
configureHttpClient, createServiceCall, getApiKey, getEndPoint, getName, getToken, processServiceCall, setApiKey, setAuthentication, setDefaultHeaders, setDefaultHeaders, setEndPoint, setSkipAuthentication, setUsernameAndPassword, toStringpublic static final java.lang.String VERSION_DATE_2016_05_19
public ToneAnalyzer(java.lang.String versionDate)
versionDate - The version date (yyyy-MM-dd) of the REST API to use. Specifying this value will keep your API
calls from failing when the service introduces breaking changes.public ToneAnalyzer(java.lang.String versionDate,
java.lang.String username,
java.lang.String password)
versionDate - The version date (yyyy-MM-dd) of the REST API to use. Specifying this value will keep your API
calls from failing when the service introduces breaking changes.username - the usernamepassword - the passwordpublic ServiceCall<ToneAnalysis> getTone(java.lang.String text, ToneOptions options)
text - The text to analyzeoptions - The ToneOptions optionsToneAnalysis with the responsepublic ServiceCall<UtterancesTone> getChatTone(ToneChatRequest chatInput)
chatInput - The object which has the JSON to analyzeUtterancesTone with the response