smithy4s.com.amazonaws.kinesis.DeleteStreamInput.scala Maven / Gradle / Ivy
package com.amazonaws.kinesis
import smithy4s.Hints
import smithy4s.Schema
import smithy4s.ShapeId
import smithy4s.ShapeTag
import smithy4s.schema.Schema.struct
/** Represents the input for DeleteStream.
* @param StreamName
* The name of the stream to delete.
* @param EnforceConsumerDeletion
* If this parameter is unset (null
) or if you set it to false
,
* and the stream has registered consumers, the call to DeleteStream
fails
* with a ResourceInUseException
.
* @param StreamARN
* The ARN of the stream.
*/
final case class DeleteStreamInput(streamName: Option[StreamName] = None, enforceConsumerDeletion: Option[BooleanObject] = None, streamARN: Option[StreamARN] = None)
object DeleteStreamInput extends ShapeTag.Companion[DeleteStreamInput] {
val id: ShapeId = ShapeId("com.amazonaws.kinesis", "DeleteStreamInput")
val hints: Hints = Hints(
smithy.api.Documentation("Represents the input for DeleteStream.
"),
smithy.api.Input(),
).lazily
// constructor using the original order from the spec
private def make(streamName: Option[StreamName], enforceConsumerDeletion: Option[BooleanObject], streamARN: Option[StreamARN]): DeleteStreamInput = DeleteStreamInput(streamName, enforceConsumerDeletion, streamARN)
implicit val schema: Schema[DeleteStreamInput] = struct(
StreamName.schema.optional[DeleteStreamInput]("StreamName", _.streamName).addHints(smithy.api.Documentation("The name of the stream to delete.
")),
BooleanObject.schema.optional[DeleteStreamInput]("EnforceConsumerDeletion", _.enforceConsumerDeletion).addHints(smithy.api.Documentation("If this parameter is unset (null
) or if you set it to false
,\n and the stream has registered consumers, the call to DeleteStream
fails\n with a ResourceInUseException
.
")),
StreamARN.schema.optional[DeleteStreamInput]("StreamARN", _.streamARN).addHints(smithy.api.Documentation("The ARN of the stream.
")),
)(make).withId(id).addHints(hints)
}