
commonMain.aws.sdk.kotlin.services.connectcases.model.GetFieldResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.connectcases.model
/**
* Object to store detailed field information.
*/
public class GetFieldResponse private constructor(builder: Builder) {
/**
* Description of the field.
*/
public val description: kotlin.String? = builder.description
/**
* The Amazon Resource Name (ARN) of the field.
*/
public val fieldArn: kotlin.String = requireNotNull(builder.fieldArn) { "A non-null value must be provided for fieldArn" }
/**
* Unique identifier of the field.
*/
public val fieldId: kotlin.String = requireNotNull(builder.fieldId) { "A non-null value must be provided for fieldId" }
/**
* Name of the field.
*/
public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
/**
* Namespace of the field.
*/
public val namespace: aws.sdk.kotlin.services.connectcases.model.FieldNamespace = requireNotNull(builder.namespace) { "A non-null value must be provided for namespace" }
/**
* A map of of key-value pairs that represent tags on a resource. Tags are used to organize, track, or control access for this resource.
*/
public val tags: Map? = builder.tags
/**
* Type of the field.
*/
public val type: aws.sdk.kotlin.services.connectcases.model.FieldType = requireNotNull(builder.type) { "A non-null value must be provided for type" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.connectcases.model.GetFieldResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetFieldResponse(")
append("description=$description,")
append("fieldArn=$fieldArn,")
append("fieldId=$fieldId,")
append("name=$name,")
append("namespace=$namespace,")
append("tags=$tags,")
append("type=$type")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = description?.hashCode() ?: 0
result = 31 * result + (fieldArn.hashCode())
result = 31 * result + (fieldId.hashCode())
result = 31 * result + (name.hashCode())
result = 31 * result + (namespace.hashCode())
result = 31 * result + (tags?.hashCode() ?: 0)
result = 31 * result + (type.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 GetFieldResponse
if (description != other.description) return false
if (fieldArn != other.fieldArn) return false
if (fieldId != other.fieldId) return false
if (name != other.name) return false
if (namespace != other.namespace) return false
if (tags != other.tags) return false
if (type != other.type) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.connectcases.model.GetFieldResponse = Builder(this).apply(block).build()
public class Builder {
/**
* Description of the field.
*/
public var description: kotlin.String? = null
/**
* The Amazon Resource Name (ARN) of the field.
*/
public var fieldArn: kotlin.String? = null
/**
* Unique identifier of the field.
*/
public var fieldId: kotlin.String? = null
/**
* Name of the field.
*/
public var name: kotlin.String? = null
/**
* Namespace of the field.
*/
public var namespace: aws.sdk.kotlin.services.connectcases.model.FieldNamespace? = null
/**
* A map of of key-value pairs that represent tags on a resource. Tags are used to organize, track, or control access for this resource.
*/
public var tags: Map? = null
/**
* Type of the field.
*/
public var type: aws.sdk.kotlin.services.connectcases.model.FieldType? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.connectcases.model.GetFieldResponse) : this() {
this.description = x.description
this.fieldArn = x.fieldArn
this.fieldId = x.fieldId
this.name = x.name
this.namespace = x.namespace
this.tags = x.tags
this.type = x.type
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.connectcases.model.GetFieldResponse = GetFieldResponse(this)
internal fun correctErrors(): Builder {
if (fieldArn == null) fieldArn = ""
if (fieldId == null) fieldId = ""
if (name == null) name = ""
if (namespace == null) namespace = FieldNamespace.SdkUnknown("no value provided")
if (type == null) type = FieldType.SdkUnknown("no value provided")
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy