
commonMain.aws.sdk.kotlin.services.cloudfront.model.CreateKeyGroupResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cloudfront.model
import aws.smithy.kotlin.runtime.SdkDsl
public class CreateKeyGroupResponse private constructor(builder: Builder) {
/**
* The identifier for this version of the key group.
*/
public val eTag: kotlin.String? = builder.eTag
/**
* The key group that was just created.
*/
public val keyGroup: aws.sdk.kotlin.services.cloudfront.model.KeyGroup? = builder.keyGroup
/**
* The URL of the key group.
*/
public val location: kotlin.String? = builder.location
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cloudfront.model.CreateKeyGroupResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateKeyGroupResponse(")
append("eTag=$eTag,")
append("keyGroup=$keyGroup,")
append("location=$location")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = eTag?.hashCode() ?: 0
result = 31 * result + (keyGroup?.hashCode() ?: 0)
result = 31 * result + (location?.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 CreateKeyGroupResponse
if (eTag != other.eTag) return false
if (keyGroup != other.keyGroup) return false
if (location != other.location) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cloudfront.model.CreateKeyGroupResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The identifier for this version of the key group.
*/
public var eTag: kotlin.String? = null
/**
* The key group that was just created.
*/
public var keyGroup: aws.sdk.kotlin.services.cloudfront.model.KeyGroup? = null
/**
* The URL of the key group.
*/
public var location: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cloudfront.model.CreateKeyGroupResponse) : this() {
this.eTag = x.eTag
this.keyGroup = x.keyGroup
this.location = x.location
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cloudfront.model.CreateKeyGroupResponse = CreateKeyGroupResponse(this)
/**
* construct an [aws.sdk.kotlin.services.cloudfront.model.KeyGroup] inside the given [block]
*/
public fun keyGroup(block: aws.sdk.kotlin.services.cloudfront.model.KeyGroup.Builder.() -> kotlin.Unit) {
this.keyGroup = aws.sdk.kotlin.services.cloudfront.model.KeyGroup.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy