commonMain.aws.sdk.kotlin.services.codegurusecurity.model.SuggestedFix.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of codegurusecurity-jvm Show documentation
Show all versions of codegurusecurity-jvm Show documentation
The AWS SDK for Kotlin client for CodeGuru Security
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.codegurusecurity.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Information about the suggested code fix to remediate a finding.
*/
public class SuggestedFix private constructor(builder: Builder) {
/**
* The suggested code fix. If applicable, includes code patch to replace your source code.
*/
public val code: kotlin.String? = builder.code
/**
* A description of the suggested code fix and why it is being suggested.
*/
public val description: kotlin.String? = builder.description
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codegurusecurity.model.SuggestedFix = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("SuggestedFix(")
append("code=$code,")
append("description=$description")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = code?.hashCode() ?: 0
result = 31 * result + (description?.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 SuggestedFix
if (code != other.code) return false
if (description != other.description) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codegurusecurity.model.SuggestedFix = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The suggested code fix. If applicable, includes code patch to replace your source code.
*/
public var code: kotlin.String? = null
/**
* A description of the suggested code fix and why it is being suggested.
*/
public var description: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.codegurusecurity.model.SuggestedFix) : this() {
this.code = x.code
this.description = x.description
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.codegurusecurity.model.SuggestedFix = SuggestedFix(this)
internal fun correctErrors(): Builder {
return this
}
}
}