commonMain.aws.sdk.kotlin.services.codegurureviewer.model.Metrics.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of codegurureviewer-jvm Show documentation
Show all versions of codegurureviewer-jvm Show documentation
The AWS SDK for Kotlin client for CodeGuru Reviewer
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.codegurureviewer.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Information about the statistics from the code review.
*/
public class Metrics private constructor(builder: Builder) {
/**
* Total number of recommendations found in the code review.
*/
public val findingsCount: kotlin.Long? = builder.findingsCount
/**
* `MeteredLinesOfCodeCount` is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.
*/
public val meteredLinesOfCodeCount: kotlin.Long? = builder.meteredLinesOfCodeCount
/**
* `SuppressedLinesOfCodeCount` is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the `excludeFiles` variable in the `aws-codeguru-reviewer.yml` file. This number does not include non-code lines such as comments and blank lines.
*/
public val suppressedLinesOfCodeCount: kotlin.Long? = builder.suppressedLinesOfCodeCount
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.codegurureviewer.model.Metrics = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("Metrics(")
append("findingsCount=$findingsCount,")
append("meteredLinesOfCodeCount=$meteredLinesOfCodeCount,")
append("suppressedLinesOfCodeCount=$suppressedLinesOfCodeCount")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = findingsCount?.hashCode() ?: 0
result = 31 * result + (meteredLinesOfCodeCount?.hashCode() ?: 0)
result = 31 * result + (suppressedLinesOfCodeCount?.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 Metrics
if (findingsCount != other.findingsCount) return false
if (meteredLinesOfCodeCount != other.meteredLinesOfCodeCount) return false
if (suppressedLinesOfCodeCount != other.suppressedLinesOfCodeCount) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.codegurureviewer.model.Metrics = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Total number of recommendations found in the code review.
*/
public var findingsCount: kotlin.Long? = null
/**
* `MeteredLinesOfCodeCount` is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.
*/
public var meteredLinesOfCodeCount: kotlin.Long? = null
/**
* `SuppressedLinesOfCodeCount` is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the `excludeFiles` variable in the `aws-codeguru-reviewer.yml` file. This number does not include non-code lines such as comments and blank lines.
*/
public var suppressedLinesOfCodeCount: kotlin.Long? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.codegurureviewer.model.Metrics) : this() {
this.findingsCount = x.findingsCount
this.meteredLinesOfCodeCount = x.meteredLinesOfCodeCount
this.suppressedLinesOfCodeCount = x.suppressedLinesOfCodeCount
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.codegurureviewer.model.Metrics = Metrics(this)
internal fun correctErrors(): Builder {
return this
}
}
}