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

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

/**
 * Information about whether a file is binary or textual in a merge or pull request operation.
 */
public class IsBinaryFile private constructor(builder: Builder) {
    /**
     * The binary or non-binary status of a file in the base of a merge or pull request.
     */
    public val base: kotlin.Boolean? = builder.base
    /**
     * The binary or non-binary status of a file in the destination of a merge or pull request.
     */
    public val destination: kotlin.Boolean? = builder.destination
    /**
     * The binary or non-binary status of file in the source of a merge or pull request.
     */
    public val source: kotlin.Boolean? = builder.source

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

    override fun toString(): kotlin.String = buildString {
        append("IsBinaryFile(")
        append("base=$base,")
        append("destination=$destination,")
        append("source=$source")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = base?.hashCode() ?: 0
        result = 31 * result + (destination?.hashCode() ?: 0)
        result = 31 * result + (source?.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 IsBinaryFile

        if (base != other.base) return false
        if (destination != other.destination) return false
        if (source != other.source) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The binary or non-binary status of a file in the base of a merge or pull request.
         */
        public var base: kotlin.Boolean? = null
        /**
         * The binary or non-binary status of a file in the destination of a merge or pull request.
         */
        public var destination: kotlin.Boolean? = null
        /**
         * The binary or non-binary status of file in the source of a merge or pull request.
         */
        public var source: kotlin.Boolean? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.codecommit.model.IsBinaryFile) : this() {
            this.base = x.base
            this.destination = x.destination
            this.source = x.source
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy