java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.watson.personality_insights.v3.model.ContentItem
All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel

public class ContentItem
extends com.ibm.cloud.sdk.core.service.model.GenericModel
An input content item that the service is to analyze.
  • Method Details

    • newBuilder

      public ContentItem.Builder newBuilder()
      New builder.
      Returns:
      a ContentItem builder
    • content

      public String content()
      Gets the content.

      The content that is to be analyzed. The service supports up to 20 MB of content for all `ContentItem` objects combined.

      Returns:
      the content
    • id

      public String id()
      Gets the id.

      A unique identifier for this content item.

      Returns:
      the id
    • created

      public Long created()
      Gets the created.

      A timestamp that identifies when this content was created. Specify a value in milliseconds since the UNIX Epoch (January 1, 1970, at 0:00 UTC). Required only for results that include temporal behavior data.

      Returns:
      the created
    • updated

      public Long updated()
      Gets the updated.

      A timestamp that identifies when this content was last updated. Specify a value in milliseconds since the UNIX Epoch (January 1, 1970, at 0:00 UTC). Required only for results that include temporal behavior data.

      Returns:
      the updated
    • contenttype

      public String contenttype()
      Gets the contenttype.

      The MIME type of the content. The default is plain text. The tags are stripped from HTML content before it is analyzed; plain text is processed as submitted.

      Returns:
      the contenttype
    • language

      public String language()
      Gets the language.

      The language identifier (two-letter ISO 639-1 identifier) for the language of the content item. The default is `en` (English). Regional variants are treated as their parent language; for example, `en-US` is interpreted as `en`. A language specified with the **Content-Type** parameter overrides the value of this parameter; any content items that specify a different language are ignored. Omit the **Content-Type** parameter to base the language on the most prevalent specification among the content items; again, content items that specify a different language are ignored. You can specify any combination of languages for the input and response content.

      Returns:
      the language
    • parentid

      public String parentid()
      Gets the parentid.

      The unique ID of the parent content item for this item. Used to identify hierarchical relationships between posts/replies, messages/replies, and so on.

      Returns:
      the parentid
    • reply

      public Boolean reply()
      Gets the reply.

      Indicates whether this content item is a reply to another content item.

      Returns:
      the reply
    • forward

      public Boolean forward()
      Gets the forward.

      Indicates whether this content item is a forwarded/copied version of another content item.

      Returns:
      the forward