commonMain.aws.sdk.kotlin.services.datazone.model.AddPolicyGrantRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of datazone-jvm Show documentation
Show all versions of datazone-jvm Show documentation
The AWS SDK for Kotlin client for DataZone
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.datazone.model
import aws.smithy.kotlin.runtime.SdkDsl
public class AddPolicyGrantRequest private constructor(builder: Builder) {
/**
* A unique, case-sensitive identifier that is provided to ensure the idempotency of the request.
*/
public val clientToken: kotlin.String? = builder.clientToken
/**
* The details of the policy grant.
*/
public val detail: aws.sdk.kotlin.services.datazone.model.PolicyGrantDetail? = builder.detail
/**
* The ID of the domain where you want to add a policy grant.
*/
public val domainIdentifier: kotlin.String? = builder.domainIdentifier
/**
* The ID of the entity (resource) to which you want to add a policy grant.
*/
public val entityIdentifier: kotlin.String? = builder.entityIdentifier
/**
* The type of entity (resource) to which the grant is added.
*/
public val entityType: aws.sdk.kotlin.services.datazone.model.TargetEntityType? = builder.entityType
/**
* The type of policy that you want to grant.
*/
public val policyType: aws.sdk.kotlin.services.datazone.model.ManagedPolicyType? = builder.policyType
/**
* The principal to whom the permissions are granted.
*/
public val principal: aws.sdk.kotlin.services.datazone.model.PolicyGrantPrincipal? = builder.principal
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.datazone.model.AddPolicyGrantRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("AddPolicyGrantRequest(")
append("clientToken=$clientToken,")
append("detail=$detail,")
append("domainIdentifier=$domainIdentifier,")
append("entityIdentifier=$entityIdentifier,")
append("entityType=$entityType,")
append("policyType=$policyType,")
append("principal=$principal")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = clientToken?.hashCode() ?: 0
result = 31 * result + (detail?.hashCode() ?: 0)
result = 31 * result + (domainIdentifier?.hashCode() ?: 0)
result = 31 * result + (entityIdentifier?.hashCode() ?: 0)
result = 31 * result + (entityType?.hashCode() ?: 0)
result = 31 * result + (policyType?.hashCode() ?: 0)
result = 31 * result + (principal?.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 AddPolicyGrantRequest
if (clientToken != other.clientToken) return false
if (detail != other.detail) return false
if (domainIdentifier != other.domainIdentifier) return false
if (entityIdentifier != other.entityIdentifier) return false
if (entityType != other.entityType) return false
if (policyType != other.policyType) return false
if (principal != other.principal) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.datazone.model.AddPolicyGrantRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* A unique, case-sensitive identifier that is provided to ensure the idempotency of the request.
*/
public var clientToken: kotlin.String? = null
/**
* The details of the policy grant.
*/
public var detail: aws.sdk.kotlin.services.datazone.model.PolicyGrantDetail? = null
/**
* The ID of the domain where you want to add a policy grant.
*/
public var domainIdentifier: kotlin.String? = null
/**
* The ID of the entity (resource) to which you want to add a policy grant.
*/
public var entityIdentifier: kotlin.String? = null
/**
* The type of entity (resource) to which the grant is added.
*/
public var entityType: aws.sdk.kotlin.services.datazone.model.TargetEntityType? = null
/**
* The type of policy that you want to grant.
*/
public var policyType: aws.sdk.kotlin.services.datazone.model.ManagedPolicyType? = null
/**
* The principal to whom the permissions are granted.
*/
public var principal: aws.sdk.kotlin.services.datazone.model.PolicyGrantPrincipal? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.datazone.model.AddPolicyGrantRequest) : this() {
this.clientToken = x.clientToken
this.detail = x.detail
this.domainIdentifier = x.domainIdentifier
this.entityIdentifier = x.entityIdentifier
this.entityType = x.entityType
this.policyType = x.policyType
this.principal = x.principal
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.datazone.model.AddPolicyGrantRequest = AddPolicyGrantRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy