commonMain.aws.sdk.kotlin.services.amplifybackend.model.BackendAuthSocialProviderConfig.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of amplifybackend-jvm Show documentation
Show all versions of amplifybackend-jvm Show documentation
The AWS SDK for Kotlin client for AmplifyBackend
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.amplifybackend.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Describes third-party social federation configurations for allowing your app users to sign in using OAuth.
*/
public class BackendAuthSocialProviderConfig private constructor(builder: Builder) {
/**
* Describes the client_id, which can be obtained from the third-party social federation provider.
*/
public val clientId: kotlin.String? = builder.clientId
/**
* Describes the client_secret, which can be obtained from third-party social federation providers.
*/
public val clientSecret: kotlin.String? = builder.clientSecret
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.amplifybackend.model.BackendAuthSocialProviderConfig = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("BackendAuthSocialProviderConfig(")
append("*** Sensitive Data Redacted ***")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = clientId?.hashCode() ?: 0
result = 31 * result + (clientSecret?.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 BackendAuthSocialProviderConfig
if (clientId != other.clientId) return false
if (clientSecret != other.clientSecret) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.amplifybackend.model.BackendAuthSocialProviderConfig = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Describes the client_id, which can be obtained from the third-party social federation provider.
*/
public var clientId: kotlin.String? = null
/**
* Describes the client_secret, which can be obtained from third-party social federation providers.
*/
public var clientSecret: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.amplifybackend.model.BackendAuthSocialProviderConfig) : this() {
this.clientId = x.clientId
this.clientSecret = x.clientSecret
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.amplifybackend.model.BackendAuthSocialProviderConfig = BackendAuthSocialProviderConfig(this)
internal fun correctErrors(): Builder {
return this
}
}
}