commonMain.aws.sdk.kotlin.services.glue.model.OAuth2Credentials.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of glue-jvm Show documentation
Show all versions of glue-jvm Show documentation
The AWS SDK for Kotlin client for Glue
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* The credentials used when the authentication type is OAuth2 authentication.
*/
public class OAuth2Credentials private constructor(builder: Builder) {
/**
* The access token used when the authentication type is OAuth2.
*/
public val accessToken: kotlin.String? = builder.accessToken
/**
* The JSON Web Token (JWT) used when the authentication type is OAuth2.
*/
public val jwtToken: kotlin.String? = builder.jwtToken
/**
* The refresh token used when the authentication type is OAuth2.
*/
public val refreshToken: kotlin.String? = builder.refreshToken
/**
* The client application client secret if the client application is user managed.
*/
public val userManagedClientApplicationClientSecret: kotlin.String? = builder.userManagedClientApplicationClientSecret
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.OAuth2Credentials = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("OAuth2Credentials(")
append("accessToken=*** Sensitive Data Redacted ***,")
append("jwtToken=*** Sensitive Data Redacted ***,")
append("refreshToken=*** Sensitive Data Redacted ***,")
append("userManagedClientApplicationClientSecret=*** Sensitive Data Redacted ***")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = accessToken?.hashCode() ?: 0
result = 31 * result + (jwtToken?.hashCode() ?: 0)
result = 31 * result + (refreshToken?.hashCode() ?: 0)
result = 31 * result + (userManagedClientApplicationClientSecret?.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 OAuth2Credentials
if (accessToken != other.accessToken) return false
if (jwtToken != other.jwtToken) return false
if (refreshToken != other.refreshToken) return false
if (userManagedClientApplicationClientSecret != other.userManagedClientApplicationClientSecret) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.OAuth2Credentials = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The access token used when the authentication type is OAuth2.
*/
public var accessToken: kotlin.String? = null
/**
* The JSON Web Token (JWT) used when the authentication type is OAuth2.
*/
public var jwtToken: kotlin.String? = null
/**
* The refresh token used when the authentication type is OAuth2.
*/
public var refreshToken: kotlin.String? = null
/**
* The client application client secret if the client application is user managed.
*/
public var userManagedClientApplicationClientSecret: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.OAuth2Credentials) : this() {
this.accessToken = x.accessToken
this.jwtToken = x.jwtToken
this.refreshToken = x.refreshToken
this.userManagedClientApplicationClientSecret = x.userManagedClientApplicationClientSecret
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.OAuth2Credentials = OAuth2Credentials(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy