commonMain.aws.sdk.kotlin.services.cleanrooms.model.GetSchemaAnalysisRuleRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cleanrooms-jvm Show documentation
Show all versions of cleanrooms-jvm Show documentation
The AWS SDK for Kotlin client for CleanRooms
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cleanrooms.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetSchemaAnalysisRuleRequest private constructor(builder: Builder) {
/**
* A unique identifier for the collaboration that the schema belongs to. Currently accepts a collaboration ID.
*/
public val collaborationIdentifier: kotlin.String = requireNotNull(builder.collaborationIdentifier) { "A non-null value must be provided for collaborationIdentifier" }
/**
* The name of the schema to retrieve the analysis rule for.
*/
public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
/**
* The type of the schema analysis rule to retrieve. Schema analysis rules are uniquely identified by a combination of the collaboration, the schema name, and their type.
*/
public val type: aws.sdk.kotlin.services.cleanrooms.model.AnalysisRuleType = requireNotNull(builder.type) { "A non-null value must be provided for type" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cleanrooms.model.GetSchemaAnalysisRuleRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetSchemaAnalysisRuleRequest(")
append("collaborationIdentifier=$collaborationIdentifier,")
append("name=$name,")
append("type=$type")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = collaborationIdentifier.hashCode()
result = 31 * result + (name.hashCode())
result = 31 * result + (type.hashCode())
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 GetSchemaAnalysisRuleRequest
if (collaborationIdentifier != other.collaborationIdentifier) return false
if (name != other.name) return false
if (type != other.type) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanrooms.model.GetSchemaAnalysisRuleRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* A unique identifier for the collaboration that the schema belongs to. Currently accepts a collaboration ID.
*/
public var collaborationIdentifier: kotlin.String? = null
/**
* The name of the schema to retrieve the analysis rule for.
*/
public var name: kotlin.String? = null
/**
* The type of the schema analysis rule to retrieve. Schema analysis rules are uniquely identified by a combination of the collaboration, the schema name, and their type.
*/
public var type: aws.sdk.kotlin.services.cleanrooms.model.AnalysisRuleType? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cleanrooms.model.GetSchemaAnalysisRuleRequest) : this() {
this.collaborationIdentifier = x.collaborationIdentifier
this.name = x.name
this.type = x.type
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cleanrooms.model.GetSchemaAnalysisRuleRequest = GetSchemaAnalysisRuleRequest(this)
internal fun correctErrors(): Builder {
if (collaborationIdentifier == null) collaborationIdentifier = ""
if (name == null) name = ""
if (type == null) type = AnalysisRuleType.SdkUnknown("no value provided")
return this
}
}
}