commonMain.aws.sdk.kotlin.services.servicediscovery.model.CreateHttpNamespaceRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.servicediscovery.model
import aws.smithy.kotlin.runtime.SdkDsl
public class CreateHttpNamespaceRequest private constructor(builder: Builder) {
/**
* A unique string that identifies the request and that allows failed `CreateHttpNamespace` requests to be retried without the risk of running the operation twice. `CreatorRequestId` can be any unique string (for example, a date/time stamp).
*/
public val creatorRequestId: kotlin.String? = builder.creatorRequestId
/**
* A description for the namespace.
*/
public val description: kotlin.String? = builder.description
/**
* The name that you want to assign to this namespace.
*/
public val name: kotlin.String? = builder.name
/**
* The tags to add to the namespace. Each tag consists of a key and an optional value that you define. Tags keys can be up to 128 characters in length, and tag values can be up to 256 characters in length.
*/
public val tags: List? = builder.tags
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.servicediscovery.model.CreateHttpNamespaceRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateHttpNamespaceRequest(")
append("creatorRequestId=$creatorRequestId,")
append("description=$description,")
append("name=$name,")
append("tags=$tags")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = creatorRequestId?.hashCode() ?: 0
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (name?.hashCode() ?: 0)
result = 31 * result + (tags?.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 CreateHttpNamespaceRequest
if (creatorRequestId != other.creatorRequestId) return false
if (description != other.description) return false
if (name != other.name) return false
if (tags != other.tags) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.servicediscovery.model.CreateHttpNamespaceRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* A unique string that identifies the request and that allows failed `CreateHttpNamespace` requests to be retried without the risk of running the operation twice. `CreatorRequestId` can be any unique string (for example, a date/time stamp).
*/
public var creatorRequestId: kotlin.String? = null
/**
* A description for the namespace.
*/
public var description: kotlin.String? = null
/**
* The name that you want to assign to this namespace.
*/
public var name: kotlin.String? = null
/**
* The tags to add to the namespace. Each tag consists of a key and an optional value that you define. Tags keys can be up to 128 characters in length, and tag values can be up to 256 characters in length.
*/
public var tags: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.servicediscovery.model.CreateHttpNamespaceRequest) : this() {
this.creatorRequestId = x.creatorRequestId
this.description = x.description
this.name = x.name
this.tags = x.tags
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.servicediscovery.model.CreateHttpNamespaceRequest = CreateHttpNamespaceRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy