@Generated(value="software.amazon.awssdk:codegen") public final class Highlight extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Highlight.Builder,Highlight>
Provides information that you can use to highlight a search result so that your users can quickly identify terms in the response.
| Modifier and Type | Class and Description |
|---|---|
static interface |
Highlight.Builder |
| Modifier and Type | Method and Description |
|---|---|
Integer |
beginOffset()
The zero-based location in the response string where the highlight starts.
|
static Highlight.Builder |
builder() |
Integer |
endOffset()
The zero-based location in the response string where the highlight ends.
|
boolean |
equals(Object obj) |
boolean |
equalsBySdkFields(Object obj) |
<T> Optional<T> |
getValueForField(String fieldName,
Class<T> clazz) |
int |
hashCode() |
List<SdkField<?>> |
sdkFields() |
static Class<? extends Highlight.Builder> |
serializableBuilderClass() |
Highlight.Builder |
toBuilder() |
Boolean |
topAnswer()
Indicates whether the response is the best response.
|
String |
toString()
Returns a string representation of this object.
|
HighlightType |
type()
The highlight type.
|
String |
typeAsString()
The highlight type.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitcopypublic final Integer beginOffset()
The zero-based location in the response string where the highlight starts.
public final Integer endOffset()
The zero-based location in the response string where the highlight ends.
public final Boolean topAnswer()
Indicates whether the response is the best response. True if this is the best response; otherwise, false.
public final HighlightType type()
The highlight type.
If the service returns an enum value that is not available in the current SDK version, type will return
HighlightType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
typeAsString().
HighlightTypepublic final String typeAsString()
The highlight type.
If the service returns an enum value that is not available in the current SDK version, type will return
HighlightType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from
typeAsString().
HighlightTypepublic Highlight.Builder toBuilder()
toBuilder in interface ToCopyableBuilder<Highlight.Builder,Highlight>public static Highlight.Builder builder()
public static Class<? extends Highlight.Builder> serializableBuilderClass()
public final boolean equalsBySdkFields(Object obj)
equalsBySdkFields in interface SdkPojopublic final String toString()
Copyright © 2023. All rights reserved.