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

commonMain.aws.sdk.kotlin.services.rolesanywhere.model.CreateProfileRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.rolesanywhere.model



public class CreateProfileRequest private constructor(builder: Builder) {
    /**
     * The number of seconds the vended session credentials are valid for.
     */
    public val durationSeconds: kotlin.Int? = builder.durationSeconds
    /**
     * Specifies whether the profile is enabled.
     */
    public val enabled: kotlin.Boolean? = builder.enabled
    /**
     * A list of managed policy ARNs that apply to the vended session credentials.
     */
    public val managedPolicyArns: List? = builder.managedPolicyArns
    /**
     * The name of the profile.
     */
    public val name: kotlin.String? = builder.name
    /**
     * Specifies whether instance properties are required in temporary credential requests with this profile.
     */
    public val requireInstanceProperties: kotlin.Boolean? = builder.requireInstanceProperties
    /**
     * A list of IAM roles that this profile can assume in a temporary credential request.
     */
    public val roleArns: List? = builder.roleArns
    /**
     * A session policy that applies to the trust boundary of the vended session credentials.
     */
    public val sessionPolicy: kotlin.String? = builder.sessionPolicy
    /**
     * The tags to attach to the profile.
     */
    public val tags: List? = builder.tags

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

    override fun toString(): kotlin.String = buildString {
        append("CreateProfileRequest(")
        append("durationSeconds=$durationSeconds,")
        append("enabled=$enabled,")
        append("managedPolicyArns=$managedPolicyArns,")
        append("name=$name,")
        append("requireInstanceProperties=$requireInstanceProperties,")
        append("roleArns=$roleArns,")
        append("sessionPolicy=$sessionPolicy,")
        append("tags=$tags")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = durationSeconds ?: 0
        result = 31 * result + (enabled?.hashCode() ?: 0)
        result = 31 * result + (managedPolicyArns?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (requireInstanceProperties?.hashCode() ?: 0)
        result = 31 * result + (roleArns?.hashCode() ?: 0)
        result = 31 * result + (sessionPolicy?.hashCode() ?: 0)
        result = 31 * result + (tags?.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 CreateProfileRequest

        if (durationSeconds != other.durationSeconds) return false
        if (enabled != other.enabled) return false
        if (managedPolicyArns != other.managedPolicyArns) return false
        if (name != other.name) return false
        if (requireInstanceProperties != other.requireInstanceProperties) return false
        if (roleArns != other.roleArns) return false
        if (sessionPolicy != other.sessionPolicy) return false
        if (tags != other.tags) return false

        return true
    }

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

    public class Builder {
        /**
         * The number of seconds the vended session credentials are valid for.
         */
        public var durationSeconds: kotlin.Int? = null
        /**
         * Specifies whether the profile is enabled.
         */
        public var enabled: kotlin.Boolean? = null
        /**
         * A list of managed policy ARNs that apply to the vended session credentials.
         */
        public var managedPolicyArns: List? = null
        /**
         * The name of the profile.
         */
        public var name: kotlin.String? = null
        /**
         * Specifies whether instance properties are required in temporary credential requests with this profile.
         */
        public var requireInstanceProperties: kotlin.Boolean? = null
        /**
         * A list of IAM roles that this profile can assume in a temporary credential request.
         */
        public var roleArns: List? = null
        /**
         * A session policy that applies to the trust boundary of the vended session credentials.
         */
        public var sessionPolicy: kotlin.String? = null
        /**
         * The tags to attach to the profile.
         */
        public var tags: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.rolesanywhere.model.CreateProfileRequest) : this() {
            this.durationSeconds = x.durationSeconds
            this.enabled = x.enabled
            this.managedPolicyArns = x.managedPolicyArns
            this.name = x.name
            this.requireInstanceProperties = x.requireInstanceProperties
            this.roleArns = x.roleArns
            this.sessionPolicy = x.sessionPolicy
            this.tags = x.tags
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.rolesanywhere.model.CreateProfileRequest = CreateProfileRequest(this)
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy