
commonMain.aws.sdk.kotlin.services.sns.model.PublishBatchResultEntry.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.sns.model
/**
* Encloses data related to a successful message in a batch request for topic.
*/
public class PublishBatchResultEntry private constructor(builder: Builder) {
/**
* The `Id` of an entry in a batch request.
*/
public val id: kotlin.String? = builder.id
/**
* An identifier for the message.
*/
public val messageId: kotlin.String? = builder.messageId
/**
* This parameter applies only to FIFO (first-in-first-out) topics.
*
* The large, non-consecutive number that Amazon SNS assigns to each message.
*
* The length of `SequenceNumber` is 128 bits. `SequenceNumber` continues to increase for a particular `MessageGroupId`.
*/
public val sequenceNumber: kotlin.String? = builder.sequenceNumber
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.sns.model.PublishBatchResultEntry = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("PublishBatchResultEntry(")
append("id=$id,")
append("messageId=$messageId,")
append("sequenceNumber=$sequenceNumber")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = id?.hashCode() ?: 0
result = 31 * result + (messageId?.hashCode() ?: 0)
result = 31 * result + (sequenceNumber?.hashCode() ?: 0)
return result
}
override fun equals(other: kotlin.Any?): kotlin.Boolean {
if (this === other) return true
if (other == null || this::class != other::class) return false
other as PublishBatchResultEntry
if (id != other.id) return false
if (messageId != other.messageId) return false
if (sequenceNumber != other.sequenceNumber) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.sns.model.PublishBatchResultEntry = Builder(this).apply(block).build()
public class Builder {
/**
* The `Id` of an entry in a batch request.
*/
public var id: kotlin.String? = null
/**
* An identifier for the message.
*/
public var messageId: kotlin.String? = null
/**
* This parameter applies only to FIFO (first-in-first-out) topics.
*
* The large, non-consecutive number that Amazon SNS assigns to each message.
*
* The length of `SequenceNumber` is 128 bits. `SequenceNumber` continues to increase for a particular `MessageGroupId`.
*/
public var sequenceNumber: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.sns.model.PublishBatchResultEntry) : this() {
this.id = x.id
this.messageId = x.messageId
this.sequenceNumber = x.sequenceNumber
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.sns.model.PublishBatchResultEntry = PublishBatchResultEntry(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy