Interface SyntaxToken.Builder
-
- All Superinterfaces:
Buildable,CopyableBuilder<SyntaxToken.Builder,SyntaxToken>,SdkBuilder<SyntaxToken.Builder,SyntaxToken>,SdkPojo
- Enclosing class:
- SyntaxToken
public static interface SyntaxToken.Builder extends SdkPojo, CopyableBuilder<SyntaxToken.Builder,SyntaxToken>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description SyntaxToken.BuilderbeginOffset(Integer beginOffset)The zero-based offset from the beginning of the source text to the first character in the word.SyntaxToken.BuilderendOffset(Integer endOffset)The zero-based offset from the beginning of the source text to the last character in the word.default SyntaxToken.BuilderpartOfSpeech(Consumer<PartOfSpeechTag.Builder> partOfSpeech)Provides the part of speech label and the confidence level that Amazon Comprehend has that the part of speech was correctly identified.SyntaxToken.BuilderpartOfSpeech(PartOfSpeechTag partOfSpeech)Provides the part of speech label and the confidence level that Amazon Comprehend has that the part of speech was correctly identified.SyntaxToken.Buildertext(String text)The word that was recognized in the source text.SyntaxToken.BuildertokenId(Integer tokenId)A unique identifier for a token.-
Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
-
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
-
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
-
-
-
-
Method Detail
-
tokenId
SyntaxToken.Builder tokenId(Integer tokenId)
A unique identifier for a token.
- Parameters:
tokenId- A unique identifier for a token.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
text
SyntaxToken.Builder text(String text)
The word that was recognized in the source text.
- Parameters:
text- The word that was recognized in the source text.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
beginOffset
SyntaxToken.Builder beginOffset(Integer beginOffset)
The zero-based offset from the beginning of the source text to the first character in the word.
- Parameters:
beginOffset- The zero-based offset from the beginning of the source text to the first character in the word.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
endOffset
SyntaxToken.Builder endOffset(Integer endOffset)
The zero-based offset from the beginning of the source text to the last character in the word.
- Parameters:
endOffset- The zero-based offset from the beginning of the source text to the last character in the word.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
partOfSpeech
SyntaxToken.Builder partOfSpeech(PartOfSpeechTag partOfSpeech)
Provides the part of speech label and the confidence level that Amazon Comprehend has that the part of speech was correctly identified. For more information, see Syntax in the Comprehend Developer Guide.
- Parameters:
partOfSpeech- Provides the part of speech label and the confidence level that Amazon Comprehend has that the part of speech was correctly identified. For more information, see Syntax in the Comprehend Developer Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
partOfSpeech
default SyntaxToken.Builder partOfSpeech(Consumer<PartOfSpeechTag.Builder> partOfSpeech)
Provides the part of speech label and the confidence level that Amazon Comprehend has that the part of speech was correctly identified. For more information, see Syntax in the Comprehend Developer Guide.
This is a convenience method that creates an instance of thePartOfSpeechTag.Builderavoiding the need to create one manually viaPartOfSpeechTag.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed topartOfSpeech(PartOfSpeechTag).- Parameters:
partOfSpeech- a consumer that will call methods onPartOfSpeechTag.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
partOfSpeech(PartOfSpeechTag)
-
-