commonMain.aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of configservice-jvm Show documentation
Show all versions of configservice-jvm Show documentation
The AWS SDK for Kotlin client for Config Service
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.configservice.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
*
*/
public class DescribeComplianceByResourceRequest private constructor(builder: Builder) {
/**
* Filters the results by compliance.
*/
public val complianceTypes: List? = builder.complianceTypes
/**
* The maximum number of evaluation results returned on each page. The default is 10. You cannot specify a number greater than 100. If you specify 0, Config uses the default.
*/
public val limit: kotlin.Int? = builder.limit
/**
* The `nextToken` string returned on a previous page that you use to get the next page of results in a paginated response.
*/
public val nextToken: kotlin.String? = builder.nextToken
/**
* The ID of the Amazon Web Services resource for which you want compliance information. You can specify only one resource ID. If you specify a resource ID, you must also specify a type for `ResourceType`.
*/
public val resourceId: kotlin.String? = builder.resourceId
/**
* The types of Amazon Web Services resources for which you want compliance information (for example, `AWS::EC2::Instance`). For this action, you can specify that the resource type is an Amazon Web Services account by specifying `AWS::::Account`.
*/
public val resourceType: kotlin.String? = builder.resourceType
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DescribeComplianceByResourceRequest(")
append("complianceTypes=$complianceTypes,")
append("limit=$limit,")
append("nextToken=$nextToken,")
append("resourceId=$resourceId,")
append("resourceType=$resourceType")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = complianceTypes?.hashCode() ?: 0
result = 31 * result + (limit ?: 0)
result = 31 * result + (nextToken?.hashCode() ?: 0)
result = 31 * result + (resourceId?.hashCode() ?: 0)
result = 31 * result + (resourceType?.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 DescribeComplianceByResourceRequest
if (complianceTypes != other.complianceTypes) return false
if (limit != other.limit) return false
if (nextToken != other.nextToken) return false
if (resourceId != other.resourceId) return false
if (resourceType != other.resourceType) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Filters the results by compliance.
*/
public var complianceTypes: List? = null
/**
* The maximum number of evaluation results returned on each page. The default is 10. You cannot specify a number greater than 100. If you specify 0, Config uses the default.
*/
public var limit: kotlin.Int? = null
/**
* The `nextToken` string returned on a previous page that you use to get the next page of results in a paginated response.
*/
public var nextToken: kotlin.String? = null
/**
* The ID of the Amazon Web Services resource for which you want compliance information. You can specify only one resource ID. If you specify a resource ID, you must also specify a type for `ResourceType`.
*/
public var resourceId: kotlin.String? = null
/**
* The types of Amazon Web Services resources for which you want compliance information (for example, `AWS::EC2::Instance`). For this action, you can specify that the resource type is an Amazon Web Services account by specifying `AWS::::Account`.
*/
public var resourceType: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest) : this() {
this.complianceTypes = x.complianceTypes
this.limit = x.limit
this.nextToken = x.nextToken
this.resourceId = x.resourceId
this.resourceType = x.resourceType
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.configservice.model.DescribeComplianceByResourceRequest = DescribeComplianceByResourceRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}