commonMain.aws.sdk.kotlin.services.glue.model.GetResourcePolicyResponse.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of glue-jvm Show documentation
Show all versions of glue-jvm Show documentation
The AWS SDK for Kotlin client for Glue
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant
public class GetResourcePolicyResponse private constructor(builder: Builder) {
/**
* The date and time at which the policy was created.
*/
public val createTime: aws.smithy.kotlin.runtime.time.Instant? = builder.createTime
/**
* Contains the hash value associated with this policy.
*/
public val policyHash: kotlin.String? = builder.policyHash
/**
* Contains the requested policy document, in JSON format.
*/
public val policyInJson: kotlin.String? = builder.policyInJson
/**
* The date and time at which the policy was last updated.
*/
public val updateTime: aws.smithy.kotlin.runtime.time.Instant? = builder.updateTime
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.GetResourcePolicyResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetResourcePolicyResponse(")
append("createTime=$createTime,")
append("policyHash=$policyHash,")
append("policyInJson=$policyInJson,")
append("updateTime=$updateTime")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = createTime?.hashCode() ?: 0
result = 31 * result + (policyHash?.hashCode() ?: 0)
result = 31 * result + (policyInJson?.hashCode() ?: 0)
result = 31 * result + (updateTime?.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 GetResourcePolicyResponse
if (createTime != other.createTime) return false
if (policyHash != other.policyHash) return false
if (policyInJson != other.policyInJson) return false
if (updateTime != other.updateTime) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.GetResourcePolicyResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The date and time at which the policy was created.
*/
public var createTime: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* Contains the hash value associated with this policy.
*/
public var policyHash: kotlin.String? = null
/**
* Contains the requested policy document, in JSON format.
*/
public var policyInJson: kotlin.String? = null
/**
* The date and time at which the policy was last updated.
*/
public var updateTime: aws.smithy.kotlin.runtime.time.Instant? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.GetResourcePolicyResponse) : this() {
this.createTime = x.createTime
this.policyHash = x.policyHash
this.policyInJson = x.policyInJson
this.updateTime = x.updateTime
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.GetResourcePolicyResponse = GetResourcePolicyResponse(this)
internal fun correctErrors(): Builder {
return this
}
}
}