
commonMain.aws.sdk.kotlin.services.iot.model.CreateThingGroupRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.iot.model
public class CreateThingGroupRequest private constructor(builder: Builder) {
/**
* The name of the parent thing group.
*/
public val parentGroupName: kotlin.String? = builder.parentGroupName
/**
* Metadata which can be used to manage the thing group.
*/
public val tags: List? = builder.tags
/**
* The thing group name to create.
*/
public val thingGroupName: kotlin.String? = builder.thingGroupName
/**
* The thing group properties.
*/
public val thingGroupProperties: aws.sdk.kotlin.services.iot.model.ThingGroupProperties? = builder.thingGroupProperties
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iot.model.CreateThingGroupRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateThingGroupRequest(")
append("parentGroupName=$parentGroupName,")
append("tags=$tags,")
append("thingGroupName=$thingGroupName,")
append("thingGroupProperties=$thingGroupProperties")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = parentGroupName?.hashCode() ?: 0
result = 31 * result + (tags?.hashCode() ?: 0)
result = 31 * result + (thingGroupName?.hashCode() ?: 0)
result = 31 * result + (thingGroupProperties?.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 CreateThingGroupRequest
if (parentGroupName != other.parentGroupName) return false
if (tags != other.tags) return false
if (thingGroupName != other.thingGroupName) return false
if (thingGroupProperties != other.thingGroupProperties) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iot.model.CreateThingGroupRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The name of the parent thing group.
*/
public var parentGroupName: kotlin.String? = null
/**
* Metadata which can be used to manage the thing group.
*/
public var tags: List? = null
/**
* The thing group name to create.
*/
public var thingGroupName: kotlin.String? = null
/**
* The thing group properties.
*/
public var thingGroupProperties: aws.sdk.kotlin.services.iot.model.ThingGroupProperties? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.iot.model.CreateThingGroupRequest) : this() {
this.parentGroupName = x.parentGroupName
this.tags = x.tags
this.thingGroupName = x.thingGroupName
this.thingGroupProperties = x.thingGroupProperties
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.iot.model.CreateThingGroupRequest = CreateThingGroupRequest(this)
/**
* construct an [aws.sdk.kotlin.services.iot.model.ThingGroupProperties] inside the given [block]
*/
public fun thingGroupProperties(block: aws.sdk.kotlin.services.iot.model.ThingGroupProperties.Builder.() -> kotlin.Unit) {
this.thingGroupProperties = aws.sdk.kotlin.services.iot.model.ThingGroupProperties.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy