
commonMain.aws.sdk.kotlin.services.verifiedpermissions.model.PutSchemaResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.verifiedpermissions.model
import aws.smithy.kotlin.runtime.time.Instant
public class PutSchemaResponse private constructor(builder: Builder) {
/**
* The date and time that the schema was originally created.
*/
public val createdDate: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createdDate) { "A non-null value must be provided for createdDate" }
/**
* The date and time that the schema was last updated.
*/
public val lastUpdatedDate: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.lastUpdatedDate) { "A non-null value must be provided for lastUpdatedDate" }
/**
* Identifies the namespaces of the entities referenced by this schema.
*/
public val namespaces: List = requireNotNull(builder.namespaces) { "A non-null value must be provided for namespaces" }
/**
* The unique ID of the policy store that contains the schema.
*/
public val policyStoreId: kotlin.String = requireNotNull(builder.policyStoreId) { "A non-null value must be provided for policyStoreId" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.verifiedpermissions.model.PutSchemaResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("PutSchemaResponse(")
append("createdDate=$createdDate,")
append("lastUpdatedDate=$lastUpdatedDate,")
append("namespaces=$namespaces,")
append("policyStoreId=$policyStoreId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = createdDate.hashCode()
result = 31 * result + (lastUpdatedDate.hashCode())
result = 31 * result + (namespaces.hashCode())
result = 31 * result + (policyStoreId.hashCode())
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 PutSchemaResponse
if (createdDate != other.createdDate) return false
if (lastUpdatedDate != other.lastUpdatedDate) return false
if (namespaces != other.namespaces) return false
if (policyStoreId != other.policyStoreId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.verifiedpermissions.model.PutSchemaResponse = Builder(this).apply(block).build()
public class Builder {
/**
* The date and time that the schema was originally created.
*/
public var createdDate: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The date and time that the schema was last updated.
*/
public var lastUpdatedDate: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* Identifies the namespaces of the entities referenced by this schema.
*/
public var namespaces: List? = null
/**
* The unique ID of the policy store that contains the schema.
*/
public var policyStoreId: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.verifiedpermissions.model.PutSchemaResponse) : this() {
this.createdDate = x.createdDate
this.lastUpdatedDate = x.lastUpdatedDate
this.namespaces = x.namespaces
this.policyStoreId = x.policyStoreId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.verifiedpermissions.model.PutSchemaResponse = PutSchemaResponse(this)
internal fun correctErrors(): Builder {
if (createdDate == null) createdDate = Instant.fromEpochSeconds(0)
if (lastUpdatedDate == null) lastUpdatedDate = Instant.fromEpochSeconds(0)
if (namespaces == null) namespaces = emptyList()
if (policyStoreId == null) policyStoreId = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy