commonMain.aws.sdk.kotlin.services.configservice.model.AggregationAuthorization.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.configservice.model
import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant
/**
* An object that represents the authorizations granted to aggregator accounts and regions.
*/
public class AggregationAuthorization private constructor(builder: Builder) {
/**
* The Amazon Resource Name (ARN) of the aggregation object.
*/
public val aggregationAuthorizationArn: kotlin.String? = builder.aggregationAuthorizationArn
/**
* The 12-digit account ID of the account authorized to aggregate data.
*/
public val authorizedAccountId: kotlin.String? = builder.authorizedAccountId
/**
* The region authorized to collect aggregated data.
*/
public val authorizedAwsRegion: kotlin.String? = builder.authorizedAwsRegion
/**
* The time stamp when the aggregation authorization was created.
*/
public val creationTime: aws.smithy.kotlin.runtime.time.Instant? = builder.creationTime
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.configservice.model.AggregationAuthorization = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("AggregationAuthorization(")
append("aggregationAuthorizationArn=$aggregationAuthorizationArn,")
append("authorizedAccountId=$authorizedAccountId,")
append("authorizedAwsRegion=$authorizedAwsRegion,")
append("creationTime=$creationTime")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = aggregationAuthorizationArn?.hashCode() ?: 0
result = 31 * result + (authorizedAccountId?.hashCode() ?: 0)
result = 31 * result + (authorizedAwsRegion?.hashCode() ?: 0)
result = 31 * result + (creationTime?.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 AggregationAuthorization
if (aggregationAuthorizationArn != other.aggregationAuthorizationArn) return false
if (authorizedAccountId != other.authorizedAccountId) return false
if (authorizedAwsRegion != other.authorizedAwsRegion) return false
if (creationTime != other.creationTime) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.configservice.model.AggregationAuthorization = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The Amazon Resource Name (ARN) of the aggregation object.
*/
public var aggregationAuthorizationArn: kotlin.String? = null
/**
* The 12-digit account ID of the account authorized to aggregate data.
*/
public var authorizedAccountId: kotlin.String? = null
/**
* The region authorized to collect aggregated data.
*/
public var authorizedAwsRegion: kotlin.String? = null
/**
* The time stamp when the aggregation authorization was created.
*/
public var creationTime: aws.smithy.kotlin.runtime.time.Instant? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.configservice.model.AggregationAuthorization) : this() {
this.aggregationAuthorizationArn = x.aggregationAuthorizationArn
this.authorizedAccountId = x.authorizedAccountId
this.authorizedAwsRegion = x.authorizedAwsRegion
this.creationTime = x.creationTime
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.configservice.model.AggregationAuthorization = AggregationAuthorization(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy