Class PayloadPart
- java.lang.Object
-
- software.amazon.awssdk.services.bedrockagentruntime.model.PayloadPart
-
- All Implemented Interfaces:
Serializable
,SdkPojo
,ResponseStream
,ToCopyableBuilder<PayloadPart.Builder,PayloadPart>
- Direct Known Subclasses:
DefaultChunk
@Generated("software.amazon.awssdk:codegen") public class PayloadPart extends Object implements SdkPojo, Serializable, ToCopyableBuilder<PayloadPart.Builder,PayloadPart>, ResponseStream
Contains a part of an agent response and citations for it.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
PayloadPart.Builder
protected static class
PayloadPart.BuilderImpl
-
Nested classes/interfaces inherited from interface software.amazon.awssdk.services.bedrockagentruntime.model.ResponseStream
ResponseStream.EventType
-
-
Field Summary
-
Fields inherited from interface software.amazon.awssdk.services.bedrockagentruntime.model.ResponseStream
UNKNOWN
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
PayloadPart(PayloadPart.BuilderImpl builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
accept(InvokeAgentResponseHandler.Visitor visitor)
Calls the appropriate visit method depending on the subtype ofPayloadPart
.Attribution
attribution()
Contains citations for a part of an agent response.static PayloadPart.Builder
builder()
SdkBytes
bytes()
A part of the agent response in bytes.PayloadPart
copy(Consumer<? super PayloadPart.Builder> modifier)
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 PayloadPart.Builder>
serializableBuilderClass()
PayloadPart.Builder
toBuilder()
String
toString()
Returns a string representation of this object.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.services.bedrockagentruntime.model.ResponseStream
sdkEventType
-
-
-
-
Constructor Detail
-
PayloadPart
protected PayloadPart(PayloadPart.BuilderImpl builder)
-
-
Method Detail
-
attribution
public final Attribution attribution()
Contains citations for a part of an agent response.
- Returns:
- Contains citations for a part of an agent response.
-
bytes
public final SdkBytes bytes()
A part of the agent response in bytes.
- Returns:
- A part of the agent response in bytes.
-
toBuilder
public PayloadPart.Builder toBuilder()
- Specified by:
toBuilder
in interfaceToCopyableBuilder<PayloadPart.Builder,PayloadPart>
-
builder
public static PayloadPart.Builder builder()
-
serializableBuilderClass
public static Class<? extends PayloadPart.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFields
in interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
copy
public final PayloadPart copy(Consumer<? super PayloadPart.Builder> modifier)
- Specified by:
copy
in interfaceToCopyableBuilder<PayloadPart.Builder,PayloadPart>
-
accept
public void accept(InvokeAgentResponseHandler.Visitor visitor)
Calls the appropriate visit method depending on the subtype ofPayloadPart
.- Specified by:
accept
in interfaceResponseStream
- Parameters:
visitor
- Visitor to invoke.
-
-