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

commonMain.aws.sdk.kotlin.services.iam.model.Position.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.iam.model



/**
 * Contains the row and column of a location of a `Statement` element in a policy document.
 *
 * This data type is used as a member of the ` Statement ` type.
 */
public class Position private constructor(builder: Builder) {
    /**
     * The column in the line containing the specified position in the document.
     */
    public val column: kotlin.Int = builder.column
    /**
     * The line containing the specified position in the document.
     */
    public val line: kotlin.Int = builder.line

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

    override fun toString(): kotlin.String = buildString {
        append("Position(")
        append("column=$column,")
        append("line=$line")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = column
        result = 31 * result + (line)
        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 Position

        if (column != other.column) return false
        if (line != other.line) return false

        return true
    }

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

    public class Builder {
        /**
         * The column in the line containing the specified position in the document.
         */
        public var column: kotlin.Int = 0
        /**
         * The line containing the specified position in the document.
         */
        public var line: kotlin.Int = 0

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.iam.model.Position) : this() {
            this.column = x.column
            this.line = x.line
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy