
commonMain.aws.sdk.kotlin.services.lightsail.model.ResourceReceivingAccess.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
/**
* Describes an Amazon Lightsail instance that has access to a Lightsail bucket.
*/
public class ResourceReceivingAccess private constructor(builder: Builder) {
/**
* The name of the Lightsail instance.
*/
public val name: kotlin.String? = builder.name
/**
* The Lightsail resource type (for example, `Instance`).
*/
public val resourceType: kotlin.String? = builder.resourceType
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.lightsail.model.ResourceReceivingAccess = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ResourceReceivingAccess(")
append("name=$name,")
append("resourceType=$resourceType")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = name?.hashCode() ?: 0
result = 31 * result + (resourceType?.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 ResourceReceivingAccess
if (name != other.name) return false
if (resourceType != other.resourceType) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.lightsail.model.ResourceReceivingAccess = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The name of the Lightsail instance.
*/
public var name: kotlin.String? = null
/**
* The Lightsail resource type (for example, `Instance`).
*/
public var resourceType: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.lightsail.model.ResourceReceivingAccess) : this() {
this.name = x.name
this.resourceType = x.resourceType
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.lightsail.model.ResourceReceivingAccess = ResourceReceivingAccess(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy