commonMain.aws.sdk.kotlin.services.bedrockruntime.model.ResponseStream.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.bedrockruntime.model
/**
* Definition of content in the response stream.
*/
public sealed class ResponseStream {
/**
* Content included in the response.
*/
public data class Chunk(val value: aws.sdk.kotlin.services.bedrockruntime.model.PayloadPart) : aws.sdk.kotlin.services.bedrockruntime.model.ResponseStream() {
}
public object SdkUnknown : aws.sdk.kotlin.services.bedrockruntime.model.ResponseStream() {
}
/**
* Casts this [ResponseStream] as a [Chunk] and retrieves its [aws.sdk.kotlin.services.bedrockruntime.model.PayloadPart] value. Throws an exception if the [ResponseStream] is not a
* [Chunk].
*/
public fun asChunk(): aws.sdk.kotlin.services.bedrockruntime.model.PayloadPart = (this as ResponseStream.Chunk).value
/**
* Casts this [ResponseStream] as a [Chunk] and retrieves its [aws.sdk.kotlin.services.bedrockruntime.model.PayloadPart] value. Returns null if the [ResponseStream] is not a [Chunk].
*/
public fun asChunkOrNull(): aws.sdk.kotlin.services.bedrockruntime.model.PayloadPart? = (this as? ResponseStream.Chunk)?.value
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy