commonMain.aws.sdk.kotlin.services.glue.model.GetSessionResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetSessionResponse private constructor(builder: Builder) {
/**
* The session object is returned in the response.
*/
public val session: aws.sdk.kotlin.services.glue.model.Session? = builder.session
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.GetSessionResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetSessionResponse(")
append("session=$session")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = session?.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 GetSessionResponse
if (session != other.session) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.GetSessionResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The session object is returned in the response.
*/
public var session: aws.sdk.kotlin.services.glue.model.Session? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.GetSessionResponse) : this() {
this.session = x.session
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.GetSessionResponse = GetSessionResponse(this)
/**
* construct an [aws.sdk.kotlin.services.glue.model.Session] inside the given [block]
*/
public fun session(block: aws.sdk.kotlin.services.glue.model.Session.Builder.() -> kotlin.Unit) {
this.session = aws.sdk.kotlin.services.glue.model.Session.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}