
commonMain.aws.sdk.kotlin.services.acmpca.model.CustomAttribute.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.acmpca.model
/**
* Defines the X.500 relative distinguished name (RDN).
*/
public class CustomAttribute private constructor(builder: Builder) {
/**
* Specifies the object identifier (OID) of the attribute type of the relative distinguished name (RDN).
*/
public val objectIdentifier: kotlin.String = requireNotNull(builder.objectIdentifier) { "A non-null value must be provided for objectIdentifier" }
/**
* Specifies the attribute value of relative distinguished name (RDN).
*/
public val value: kotlin.String = requireNotNull(builder.value) { "A non-null value must be provided for value" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.acmpca.model.CustomAttribute = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CustomAttribute(")
append("objectIdentifier=$objectIdentifier,")
append("value=$value")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = objectIdentifier.hashCode()
result = 31 * result + (value.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 CustomAttribute
if (objectIdentifier != other.objectIdentifier) return false
if (value != other.value) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.acmpca.model.CustomAttribute = Builder(this).apply(block).build()
public class Builder {
/**
* Specifies the object identifier (OID) of the attribute type of the relative distinguished name (RDN).
*/
public var objectIdentifier: kotlin.String? = null
/**
* Specifies the attribute value of relative distinguished name (RDN).
*/
public var value: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.acmpca.model.CustomAttribute) : this() {
this.objectIdentifier = x.objectIdentifier
this.value = x.value
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.acmpca.model.CustomAttribute = CustomAttribute(this)
internal fun correctErrors(): Builder {
if (objectIdentifier == null) objectIdentifier = ""
if (value == null) value = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy