Class PersonalityInsights

java.lang.Object
com.ibm.cloud.sdk.core.service.BaseService
com.ibm.watson.personality_insights.v3.PersonalityInsights

@Deprecated
public class PersonalityInsights
extends com.ibm.cloud.sdk.core.service.BaseService
Deprecated.
On 1 December 2021, Personality Insights will no longer be available. Consider migrating to Watson Natural Language Understanding. For more information, see Personality Insights Deprecation (https://github.com/watson-developer-cloud/java-sdk/tree/master#personality-insights-deprecation).
  • Field Summary

    Fields
    Modifier and Type Field Description
    static String DEFAULT_SERVICE_NAME
    Deprecated.
     
    static String DEFAULT_SERVICE_URL
    Deprecated.
     

    Fields inherited from class com.ibm.cloud.sdk.core.service.BaseService

    PROPNAME_DISABLE_SSL, PROPNAME_ENABLE_GZIP, PROPNAME_URL
  • Constructor Summary

    Constructors
    Constructor Description
    PersonalityInsights​(String version)
    Deprecated.
    Constructs an instance of the `PersonalityInsights` client.
    PersonalityInsights​(String version, com.ibm.cloud.sdk.core.security.Authenticator authenticator)
    Deprecated.
    Constructs an instance of the `PersonalityInsights` client.
    PersonalityInsights​(String version, String serviceName)
    Deprecated.
    Constructs an instance of the `PersonalityInsights` client.
    PersonalityInsights​(String version, String serviceName, com.ibm.cloud.sdk.core.security.Authenticator authenticator)
    Deprecated.
    Constructs an instance of the `PersonalityInsights` client.
  • Method Summary

    Modifier and Type Method Description
    String getVersion()
    Deprecated.
    Gets the version.
    com.ibm.cloud.sdk.core.http.ServiceCall<Profile> profile​(ProfileOptions profileOptions)
    Deprecated.
    Get profile.
    com.ibm.cloud.sdk.core.http.ServiceCall<InputStream> profileAsCsv​(ProfileOptions profileOptions)
    Deprecated.
    Get profile as csv.
    void setVersion​(String version)
    Deprecated.
    Sets the version.

    Methods inherited from class com.ibm.cloud.sdk.core.service.BaseService

    configureClient, configureService, constructServiceUrl, constructServiceURL, enableGzipCompression, getAuthenticator, getClient, getEndPoint, getName, getServiceUrl, isJsonMimeType, isJsonPatchMimeType, setClient, setDefaultHeaders, setEndPoint, setServiceUrl, toString

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

    • PersonalityInsights

      public PersonalityInsights​(String version)
      Deprecated.
      Constructs an instance of the `PersonalityInsights` client. The default service name is used to configure the client instance.
      Parameters:
      version - Release date of the version of the API you want to use. Specify dates in YYYY-MM-DD format. The current version is `2017-10-13`.
    • PersonalityInsights

      public PersonalityInsights​(String version, com.ibm.cloud.sdk.core.security.Authenticator authenticator)
      Deprecated.
      Constructs an instance of the `PersonalityInsights` client. The default service name and specified authenticator are used to configure the client instance.
      Parameters:
      version - Release date of the version of the API you want to use. Specify dates in YYYY-MM-DD format. The current version is `2017-10-13`.
      authenticator - the Authenticator instance to be configured for this client
    • PersonalityInsights

      public PersonalityInsights​(String version, String serviceName)
      Deprecated.
      Constructs an instance of the `PersonalityInsights` client. The specified service name is used to configure the client instance.
      Parameters:
      version - Release date of the version of the API you want to use. Specify dates in YYYY-MM-DD format. The current version is `2017-10-13`.
      serviceName - the service name to be used when configuring the client instance
    • PersonalityInsights

      public PersonalityInsights​(String version, String serviceName, com.ibm.cloud.sdk.core.security.Authenticator authenticator)
      Deprecated.
      Constructs an instance of the `PersonalityInsights` client. The specified service name and authenticator are used to configure the client instance.
      Parameters:
      version - Release date of the version of the API you want to use. Specify dates in YYYY-MM-DD format. The current version is `2017-10-13`.
      serviceName - the service name to be used when configuring the client instance
      authenticator - the Authenticator instance to be configured for this client
  • Method Details

    • getVersion

      public String getVersion()
      Deprecated.
      Gets the version.

      Release date of the version of the API you want to use. Specify dates in YYYY-MM-DD format. The current version is `2017-10-13`.

      Returns:
      the version
    • setVersion

      public void setVersion​(String version)
      Deprecated.
      Sets the version.
      Parameters:
      version - the new version
    • profile

      public com.ibm.cloud.sdk.core.http.ServiceCall<Profile> profile​(ProfileOptions profileOptions)
      Deprecated.
      Get profile.

      Generates a personality profile for the author of the input text. The service accepts a maximum of 20 MB of input content, but it requires much less text to produce an accurate profile. The service can analyze text in Arabic, English, Japanese, Korean, or Spanish. It can return its results in a variety of languages.

      **See also:** * [Requesting a profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#input) * [Providing sufficient input](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#sufficient)

      ### Content types

      You can provide input content as plain text (`text/plain`), HTML (`text/html`), or JSON (`application/json`) by specifying the **Content-Type** parameter. The default is `text/plain`. * Per the JSON specification, the default character encoding for JSON content is effectively always UTF-8. * Per the HTTP specification, the default encoding for plain text and HTML is ISO-8859-1 (effectively, the ASCII character set).

      When specifying a content type of plain text or HTML, include the `charset` parameter to indicate the character encoding of the input text; for example, `Content-Type: text/plain;charset=utf-8`.

      **See also:** [Specifying request and response formats](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#formats)

      ### Accept types

      You must request a response as JSON (`application/json`) or comma-separated values (`text/csv`) by specifying the **Accept** parameter. CSV output includes a fixed number of columns. Set the **csv_headers** parameter to `true` to request optional column headers for CSV output.

      **See also:** * [Understanding a JSON profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-output#output) * [Understanding a CSV profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-outputCSV#outputCSV).

      Parameters:
      profileOptions - the ProfileOptions containing the options for the call
      Returns:
      a ServiceCall with a result of type Profile
    • profileAsCsv

      public com.ibm.cloud.sdk.core.http.ServiceCall<InputStream> profileAsCsv​(ProfileOptions profileOptions)
      Deprecated.
      Get profile as csv.

      Generates a personality profile for the author of the input text. The service accepts a maximum of 20 MB of input content, but it requires much less text to produce an accurate profile. The service can analyze text in Arabic, English, Japanese, Korean, or Spanish. It can return its results in a variety of languages.

      **See also:** * [Requesting a profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#input) * [Providing sufficient input](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#sufficient)

      ### Content types

      You can provide input content as plain text (`text/plain`), HTML (`text/html`), or JSON (`application/json`) by specifying the **Content-Type** parameter. The default is `text/plain`. * Per the JSON specification, the default character encoding for JSON content is effectively always UTF-8. * Per the HTTP specification, the default encoding for plain text and HTML is ISO-8859-1 (effectively, the ASCII character set).

      When specifying a content type of plain text or HTML, include the `charset` parameter to indicate the character encoding of the input text; for example, `Content-Type: text/plain;charset=utf-8`.

      **See also:** [Specifying request and response formats](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-input#formats)

      ### Accept types

      You must request a response as JSON (`application/json`) or comma-separated values (`text/csv`) by specifying the **Accept** parameter. CSV output includes a fixed number of columns. Set the **csv_headers** parameter to `true` to request optional column headers for CSV output.

      **See also:** * [Understanding a JSON profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-output#output) * [Understanding a CSV profile](https://cloud.ibm.com/docs/personality-insights?topic=personality-insights-outputCSV#outputCSV).

      Parameters:
      profileOptions - the ProfileOptions containing the options for the call
      Returns:
      a ServiceCall with a result of type String