
commonMain.aws.sdk.kotlin.services.lightsail.model.DeleteInstanceRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.lightsail.model
import aws.smithy.kotlin.runtime.SdkDsl
public class DeleteInstanceRequest private constructor(builder: Builder) {
/**
* A Boolean value to indicate whether to delete all add-ons for the instance.
*/
public val forceDeleteAddOns: kotlin.Boolean? = builder.forceDeleteAddOns
/**
* The name of the instance to delete.
*/
public val instanceName: kotlin.String? = builder.instanceName
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.lightsail.model.DeleteInstanceRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DeleteInstanceRequest(")
append("forceDeleteAddOns=$forceDeleteAddOns,")
append("instanceName=$instanceName")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = forceDeleteAddOns?.hashCode() ?: 0
result = 31 * result + (instanceName?.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 DeleteInstanceRequest
if (forceDeleteAddOns != other.forceDeleteAddOns) return false
if (instanceName != other.instanceName) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.lightsail.model.DeleteInstanceRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* A Boolean value to indicate whether to delete all add-ons for the instance.
*/
public var forceDeleteAddOns: kotlin.Boolean? = null
/**
* The name of the instance to delete.
*/
public var instanceName: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.lightsail.model.DeleteInstanceRequest) : this() {
this.forceDeleteAddOns = x.forceDeleteAddOns
this.instanceName = x.instanceName
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.lightsail.model.DeleteInstanceRequest = DeleteInstanceRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy