java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.watson.natural_language_understanding.v1.model.AnalyzeOptions
All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel

public class AnalyzeOptions
extends com.ibm.cloud.sdk.core.service.model.GenericModel
The analyze options.
  • Method Details

    • newBuilder

      public AnalyzeOptions.Builder newBuilder()
      New builder.
      Returns:
      a AnalyzeOptions builder
    • features

      public Features features()
      Gets the features.

      Specific features to analyze the document for.

      Returns:
      the features
    • text

      public String text()
      Gets the text.

      The plain text to analyze. One of the `text`, `html`, or `url` parameters is required.

      Returns:
      the text
    • html

      public String html()
      Gets the html.

      The HTML file to analyze. One of the `text`, `html`, or `url` parameters is required.

      Returns:
      the html
    • url

      public String url()
      Gets the url.

      The webpage to analyze. One of the `text`, `html`, or `url` parameters is required.

      Returns:
      the url
    • clean

      public Boolean clean()
      Gets the clean.

      Set this to `false` to disable webpage cleaning. For more information about webpage cleaning, see [Analyzing webpages](https://cloud.ibm.com/docs/natural-language-understanding?topic=natural-language-understanding-analyzing-webpages).

      Returns:
      the clean
    • xpath

      public String xpath()
      Gets the xpath.

      An [XPath query](https://cloud.ibm.com/docs/natural-language-understanding?topic=natural-language-understanding-analyzing-webpages#xpath) to perform on `html` or `url` input. Results of the query will be appended to the cleaned webpage text before it is analyzed. To analyze only the results of the XPath query, set the `clean` parameter to `false`.

      Returns:
      the xpath
    • fallbackToRaw

      public Boolean fallbackToRaw()
      Gets the fallbackToRaw.

      Whether to use raw HTML content if text cleaning fails.

      Returns:
      the fallbackToRaw
    • returnAnalyzedText

      public Boolean returnAnalyzedText()
      Gets the returnAnalyzedText.

      Whether or not to return the analyzed text.

      Returns:
      the returnAnalyzedText
    • language

      public String language()
      Gets the language.

      ISO 639-1 code that specifies the language of your text. This overrides automatic language detection. Language support differs depending on the features you include in your analysis. For more information, see [Language support](https://cloud.ibm.com/docs/natural-language-understanding?topic=natural-language-understanding-language-support).

      Returns:
      the language
    • limitTextCharacters

      public Long limitTextCharacters()
      Gets the limitTextCharacters.

      Sets the maximum number of characters that are processed by the service.

      Returns:
      the limitTextCharacters