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

commonMain.aws.sdk.kotlin.services.codecommit.model.ApprovalRuleOverriddenEventMetadata.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

/**
 * Returns information about an override event for approval rules for a pull request.
 */
public class ApprovalRuleOverriddenEventMetadata private constructor(builder: Builder) {
    /**
     * The status of the override event.
     */
    public val overrideStatus: aws.sdk.kotlin.services.codecommit.model.OverrideStatus? = builder.overrideStatus
    /**
     * The revision ID of the pull request when the override event occurred.
     */
    public val revisionId: kotlin.String? = builder.revisionId

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

    override fun toString(): kotlin.String = buildString {
        append("ApprovalRuleOverriddenEventMetadata(")
        append("overrideStatus=$overrideStatus,")
        append("revisionId=$revisionId")
        append(")")
    }

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

        if (overrideStatus != other.overrideStatus) return false
        if (revisionId != other.revisionId) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The status of the override event.
         */
        public var overrideStatus: aws.sdk.kotlin.services.codecommit.model.OverrideStatus? = null
        /**
         * The revision ID of the pull request when the override event occurred.
         */
        public var revisionId: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.codecommit.model.ApprovalRuleOverriddenEventMetadata) : this() {
            this.overrideStatus = x.overrideStatus
            this.revisionId = x.revisionId
        }

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

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy