All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.wellarchitected.model.UpdateShareInvitationRequest.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.wellarchitected.model



/**
 * Input for Update Share Invitation
 */
public class UpdateShareInvitationRequest private constructor(builder: Builder) {
    /**
     * Share invitation action taken by contributor.
     */
    public val shareInvitationAction: aws.sdk.kotlin.services.wellarchitected.model.ShareInvitationAction? = builder.shareInvitationAction
    /**
     * The ID assigned to the share invitation.
     */
    public val shareInvitationId: kotlin.String? = requireNotNull(builder.shareInvitationId) { "A non-null value must be provided for shareInvitationId" }

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.wellarchitected.model.UpdateShareInvitationRequest = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("UpdateShareInvitationRequest(")
        append("shareInvitationAction=$shareInvitationAction,")
        append("shareInvitationId=$shareInvitationId")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = shareInvitationAction?.hashCode() ?: 0
        result = 31 * result + (shareInvitationId?.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 UpdateShareInvitationRequest

        if (shareInvitationAction != other.shareInvitationAction) return false
        if (shareInvitationId != other.shareInvitationId) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.wellarchitected.model.UpdateShareInvitationRequest = Builder(this).apply(block).build()

    public class Builder {
        /**
         * Share invitation action taken by contributor.
         */
        public var shareInvitationAction: aws.sdk.kotlin.services.wellarchitected.model.ShareInvitationAction? = null
        /**
         * The ID assigned to the share invitation.
         */
        public var shareInvitationId: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.wellarchitected.model.UpdateShareInvitationRequest) : this() {
            this.shareInvitationAction = x.shareInvitationAction
            this.shareInvitationId = x.shareInvitationId
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.wellarchitected.model.UpdateShareInvitationRequest = UpdateShareInvitationRequest(this)

        internal fun correctErrors(): Builder {
            if (shareInvitationAction == null) shareInvitationAction = ShareInvitationAction.SdkUnknown("no value provided")
            if (shareInvitationId == null) shareInvitationId = ""
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy