public class AnalyzeOptions
extends com.ibm.cloud.sdk.core.service.model.GenericModel
Modifier and Type | Class and Description |
---|---|
static class |
AnalyzeOptions.Builder
Builder.
|
Modifier and Type | Field and Description |
---|---|
protected java.lang.Boolean |
clean |
protected java.lang.Boolean |
fallbackToRaw |
protected Features |
features |
protected java.lang.String |
html |
protected java.lang.String |
language |
protected java.lang.Long |
limitTextCharacters |
protected java.lang.Boolean |
returnAnalyzedText |
protected java.lang.String |
text |
protected java.lang.String |
url |
protected java.lang.String |
xpath |
Modifier | Constructor and Description |
---|---|
protected |
AnalyzeOptions(AnalyzeOptions.Builder builder) |
Modifier and Type | Method and Description |
---|---|
java.lang.Boolean |
clean()
Gets the clean.
|
java.lang.Boolean |
fallbackToRaw()
Gets the fallbackToRaw.
|
Features |
features()
Gets the features.
|
java.lang.String |
html()
Gets the html.
|
java.lang.String |
language()
Gets the language.
|
java.lang.Long |
limitTextCharacters()
Gets the limitTextCharacters.
|
AnalyzeOptions.Builder |
newBuilder()
New builder.
|
java.lang.Boolean |
returnAnalyzedText()
Gets the returnAnalyzedText.
|
java.lang.String |
text()
Gets the text.
|
java.lang.String |
url()
Gets the url.
|
java.lang.String |
xpath()
Gets the xpath.
|
protected Features features
protected java.lang.String text
protected java.lang.String html
protected java.lang.String url
protected java.lang.Boolean clean
protected java.lang.String xpath
protected java.lang.Boolean fallbackToRaw
protected java.lang.Boolean returnAnalyzedText
protected java.lang.String language
protected java.lang.Long limitTextCharacters
protected AnalyzeOptions(AnalyzeOptions.Builder builder)
public AnalyzeOptions.Builder newBuilder()
public Features features()
Specific features to analyze the document for.
public java.lang.String text()
The plain text to analyze. One of the `text`, `html`, or `url` parameters is required.
public java.lang.String html()
The HTML file to analyze. One of the `text`, `html`, or `url` parameters is required.
public java.lang.String url()
The webpage to analyze. One of the `text`, `html`, or `url` parameters is required.
public java.lang.Boolean 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).
public java.lang.String 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`.
public java.lang.Boolean fallbackToRaw()
Whether to use raw HTML content if text cleaning fails.
public java.lang.Boolean returnAnalyzedText()
Whether or not to return the analyzed text.
public java.lang.String 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).
public java.lang.Long limitTextCharacters()
Sets the maximum number of characters that are processed by the service.