commonMain.aws.sdk.kotlin.services.fms.model.AwsEc2InstanceViolation.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.fms.model
/**
* Violation detail for an EC2 instance resource.
*/
public class AwsEc2InstanceViolation private constructor(builder: Builder) {
/**
* Violation detail for network interfaces associated with the EC2 instance.
*/
public val awsEc2NetworkInterfaceViolations: List? = builder.awsEc2NetworkInterfaceViolations
/**
* The resource ID of the EC2 instance.
*/
public val violationTarget: kotlin.String? = builder.violationTarget
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.fms.model.AwsEc2InstanceViolation = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("AwsEc2InstanceViolation(")
append("awsEc2NetworkInterfaceViolations=$awsEc2NetworkInterfaceViolations,")
append("violationTarget=$violationTarget")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = awsEc2NetworkInterfaceViolations?.hashCode() ?: 0
result = 31 * result + (violationTarget?.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 AwsEc2InstanceViolation
if (awsEc2NetworkInterfaceViolations != other.awsEc2NetworkInterfaceViolations) return false
if (violationTarget != other.violationTarget) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.fms.model.AwsEc2InstanceViolation = Builder(this).apply(block).build()
public class Builder {
/**
* Violation detail for network interfaces associated with the EC2 instance.
*/
public var awsEc2NetworkInterfaceViolations: List? = null
/**
* The resource ID of the EC2 instance.
*/
public var violationTarget: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.fms.model.AwsEc2InstanceViolation) : this() {
this.awsEc2NetworkInterfaceViolations = x.awsEc2NetworkInterfaceViolations
this.violationTarget = x.violationTarget
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.fms.model.AwsEc2InstanceViolation = AwsEc2InstanceViolation(this)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy