
commonMain.aws.sdk.kotlin.services.ssm.model.AssociateOpsItemRelatedItemRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.ssm.model
public class AssociateOpsItemRelatedItemRequest private constructor(builder: Builder) {
/**
* The type of association that you want to create between an OpsItem and a resource. OpsCenter supports `IsParentOf` and `RelatesTo` association types.
*/
public val associationType: kotlin.String? = builder.associationType
/**
* The ID of the OpsItem to which you want to associate a resource as a related item.
*/
public val opsItemId: kotlin.String? = builder.opsItemId
/**
* The type of resource that you want to associate with an OpsItem. OpsCenter supports the following types:
*
* `AWS::SSMIncidents::IncidentRecord`: an Incident Manager incident.
*
* `AWS::SSM::Document`: a Systems Manager (SSM) document.
*/
public val resourceType: kotlin.String? = builder.resourceType
/**
* The Amazon Resource Name (ARN) of the Amazon Web Services resource that you want to associate with the OpsItem.
*/
public val resourceUri: kotlin.String? = builder.resourceUri
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.ssm.model.AssociateOpsItemRelatedItemRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("AssociateOpsItemRelatedItemRequest(")
append("associationType=$associationType,")
append("opsItemId=$opsItemId,")
append("resourceType=$resourceType,")
append("resourceUri=$resourceUri")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = associationType?.hashCode() ?: 0
result = 31 * result + (opsItemId?.hashCode() ?: 0)
result = 31 * result + (resourceType?.hashCode() ?: 0)
result = 31 * result + (resourceUri?.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 AssociateOpsItemRelatedItemRequest
if (associationType != other.associationType) return false
if (opsItemId != other.opsItemId) return false
if (resourceType != other.resourceType) return false
if (resourceUri != other.resourceUri) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.ssm.model.AssociateOpsItemRelatedItemRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The type of association that you want to create between an OpsItem and a resource. OpsCenter supports `IsParentOf` and `RelatesTo` association types.
*/
public var associationType: kotlin.String? = null
/**
* The ID of the OpsItem to which you want to associate a resource as a related item.
*/
public var opsItemId: kotlin.String? = null
/**
* The type of resource that you want to associate with an OpsItem. OpsCenter supports the following types:
*
* `AWS::SSMIncidents::IncidentRecord`: an Incident Manager incident.
*
* `AWS::SSM::Document`: a Systems Manager (SSM) document.
*/
public var resourceType: kotlin.String? = null
/**
* The Amazon Resource Name (ARN) of the Amazon Web Services resource that you want to associate with the OpsItem.
*/
public var resourceUri: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.ssm.model.AssociateOpsItemRelatedItemRequest) : this() {
this.associationType = x.associationType
this.opsItemId = x.opsItemId
this.resourceType = x.resourceType
this.resourceUri = x.resourceUri
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.ssm.model.AssociateOpsItemRelatedItemRequest = AssociateOpsItemRelatedItemRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy