commonMain.aws.sdk.kotlin.services.glue.model.GetDatabasesRequest.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
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetDatabasesRequest private constructor(builder: Builder) {
/**
* Specifies the database fields returned by the `GetDatabases` call. This parameter doesn’t accept an empty list. The request must include the `NAME`.
*/
public val attributesToGet: List? = builder.attributesToGet
/**
* The ID of the Data Catalog from which to retrieve `Databases`. If none is provided, the Amazon Web Services account ID is used by default.
*/
public val catalogId: kotlin.String? = builder.catalogId
/**
* The maximum number of databases to return in one response.
*/
public val maxResults: kotlin.Int? = builder.maxResults
/**
* A continuation token, if this is a continuation call.
*/
public val nextToken: kotlin.String? = builder.nextToken
/**
* Allows you to specify that you want to list the databases shared with your account. The allowable values are `FEDERATED`, `FOREIGN` or `ALL`.
* + If set to `FEDERATED`, will list the federated databases (referencing an external entity) shared with your account.
* + If set to `FOREIGN`, will list the databases shared with your account.
* + If set to `ALL`, will list the databases shared with your account, as well as the databases in yor local account.
*/
public val resourceShareType: aws.sdk.kotlin.services.glue.model.ResourceShareType? = builder.resourceShareType
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.GetDatabasesRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetDatabasesRequest(")
append("attributesToGet=$attributesToGet,")
append("catalogId=$catalogId,")
append("maxResults=$maxResults,")
append("nextToken=$nextToken,")
append("resourceShareType=$resourceShareType")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = attributesToGet?.hashCode() ?: 0
result = 31 * result + (catalogId?.hashCode() ?: 0)
result = 31 * result + (maxResults ?: 0)
result = 31 * result + (nextToken?.hashCode() ?: 0)
result = 31 * result + (resourceShareType?.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 GetDatabasesRequest
if (attributesToGet != other.attributesToGet) return false
if (catalogId != other.catalogId) return false
if (maxResults != other.maxResults) return false
if (nextToken != other.nextToken) return false
if (resourceShareType != other.resourceShareType) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.GetDatabasesRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Specifies the database fields returned by the `GetDatabases` call. This parameter doesn’t accept an empty list. The request must include the `NAME`.
*/
public var attributesToGet: List? = null
/**
* The ID of the Data Catalog from which to retrieve `Databases`. If none is provided, the Amazon Web Services account ID is used by default.
*/
public var catalogId: kotlin.String? = null
/**
* The maximum number of databases to return in one response.
*/
public var maxResults: kotlin.Int? = null
/**
* A continuation token, if this is a continuation call.
*/
public var nextToken: kotlin.String? = null
/**
* Allows you to specify that you want to list the databases shared with your account. The allowable values are `FEDERATED`, `FOREIGN` or `ALL`.
* + If set to `FEDERATED`, will list the federated databases (referencing an external entity) shared with your account.
* + If set to `FOREIGN`, will list the databases shared with your account.
* + If set to `ALL`, will list the databases shared with your account, as well as the databases in yor local account.
*/
public var resourceShareType: aws.sdk.kotlin.services.glue.model.ResourceShareType? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.GetDatabasesRequest) : this() {
this.attributesToGet = x.attributesToGet
this.catalogId = x.catalogId
this.maxResults = x.maxResults
this.nextToken = x.nextToken
this.resourceShareType = x.resourceShareType
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.GetDatabasesRequest = GetDatabasesRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}