
commonMain.aws.sdk.kotlin.services.codecommit.model.GetCommentReactionsResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.codecommit.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetCommentReactionsResponse private constructor(builder: Builder) {
/**
* An enumeration token that can be used in a request to return the next batch of the results.
*/
public val nextToken: kotlin.String? = builder.nextToken
/**
* An array of reactions to the specified comment.
*/
public val reactionsForComment: List = requireNotNull(builder.reactionsForComment) { "A non-null value must be provided for reactionsForComment" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codecommit.model.GetCommentReactionsResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetCommentReactionsResponse(")
append("nextToken=$nextToken,")
append("reactionsForComment=$reactionsForComment")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = nextToken?.hashCode() ?: 0
result = 31 * result + (reactionsForComment.hashCode())
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 GetCommentReactionsResponse
if (nextToken != other.nextToken) return false
if (reactionsForComment != other.reactionsForComment) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codecommit.model.GetCommentReactionsResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* An enumeration token that can be used in a request to return the next batch of the results.
*/
public var nextToken: kotlin.String? = null
/**
* An array of reactions to the specified comment.
*/
public var reactionsForComment: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.codecommit.model.GetCommentReactionsResponse) : this() {
this.nextToken = x.nextToken
this.reactionsForComment = x.reactionsForComment
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.codecommit.model.GetCommentReactionsResponse = GetCommentReactionsResponse(this)
internal fun correctErrors(): Builder {
if (reactionsForComment == null) reactionsForComment = emptyList()
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy