
commonMain.aws.sdk.kotlin.services.iot.model.UpdateBillingGroupRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.iot.model
public class UpdateBillingGroupRequest private constructor(builder: Builder) {
/**
* The name of the billing group.
*/
public val billingGroupName: kotlin.String? = builder.billingGroupName
/**
* The properties of the billing group.
*/
public val billingGroupProperties: aws.sdk.kotlin.services.iot.model.BillingGroupProperties? = builder.billingGroupProperties
/**
* The expected version of the billing group. If the version of the billing group does not match the expected version specified in the request, the `UpdateBillingGroup` request is rejected with a `VersionConflictException`.
*/
public val expectedVersion: kotlin.Long? = builder.expectedVersion
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iot.model.UpdateBillingGroupRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("UpdateBillingGroupRequest(")
append("billingGroupName=$billingGroupName,")
append("billingGroupProperties=$billingGroupProperties,")
append("expectedVersion=$expectedVersion")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = billingGroupName?.hashCode() ?: 0
result = 31 * result + (billingGroupProperties?.hashCode() ?: 0)
result = 31 * result + (expectedVersion?.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 UpdateBillingGroupRequest
if (billingGroupName != other.billingGroupName) return false
if (billingGroupProperties != other.billingGroupProperties) return false
if (expectedVersion != other.expectedVersion) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iot.model.UpdateBillingGroupRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The name of the billing group.
*/
public var billingGroupName: kotlin.String? = null
/**
* The properties of the billing group.
*/
public var billingGroupProperties: aws.sdk.kotlin.services.iot.model.BillingGroupProperties? = null
/**
* The expected version of the billing group. If the version of the billing group does not match the expected version specified in the request, the `UpdateBillingGroup` request is rejected with a `VersionConflictException`.
*/
public var expectedVersion: kotlin.Long? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.iot.model.UpdateBillingGroupRequest) : this() {
this.billingGroupName = x.billingGroupName
this.billingGroupProperties = x.billingGroupProperties
this.expectedVersion = x.expectedVersion
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.iot.model.UpdateBillingGroupRequest = UpdateBillingGroupRequest(this)
/**
* construct an [aws.sdk.kotlin.services.iot.model.BillingGroupProperties] inside the given [block]
*/
public fun billingGroupProperties(block: aws.sdk.kotlin.services.iot.model.BillingGroupProperties.Builder.() -> kotlin.Unit) {
this.billingGroupProperties = aws.sdk.kotlin.services.iot.model.BillingGroupProperties.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy