commonMain.aws.sdk.kotlin.services.cloudwatchlogs.model.RejectedLogEventsInfo.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cloudwatchlogs.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Represents the rejected events.
*/
public class RejectedLogEventsInfo private constructor(builder: Builder) {
/**
* The expired log events.
*/
public val expiredLogEventEndIndex: kotlin.Int? = builder.expiredLogEventEndIndex
/**
* The index of the first log event that is too new. This field is inclusive.
*/
public val tooNewLogEventStartIndex: kotlin.Int? = builder.tooNewLogEventStartIndex
/**
* The index of the last log event that is too old. This field is exclusive.
*/
public val tooOldLogEventEndIndex: kotlin.Int? = builder.tooOldLogEventEndIndex
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cloudwatchlogs.model.RejectedLogEventsInfo = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("RejectedLogEventsInfo(")
append("expiredLogEventEndIndex=$expiredLogEventEndIndex,")
append("tooNewLogEventStartIndex=$tooNewLogEventStartIndex,")
append("tooOldLogEventEndIndex=$tooOldLogEventEndIndex")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = expiredLogEventEndIndex ?: 0
result = 31 * result + (tooNewLogEventStartIndex ?: 0)
result = 31 * result + (tooOldLogEventEndIndex ?: 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 RejectedLogEventsInfo
if (expiredLogEventEndIndex != other.expiredLogEventEndIndex) return false
if (tooNewLogEventStartIndex != other.tooNewLogEventStartIndex) return false
if (tooOldLogEventEndIndex != other.tooOldLogEventEndIndex) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cloudwatchlogs.model.RejectedLogEventsInfo = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The expired log events.
*/
public var expiredLogEventEndIndex: kotlin.Int? = null
/**
* The index of the first log event that is too new. This field is inclusive.
*/
public var tooNewLogEventStartIndex: kotlin.Int? = null
/**
* The index of the last log event that is too old. This field is exclusive.
*/
public var tooOldLogEventEndIndex: kotlin.Int? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cloudwatchlogs.model.RejectedLogEventsInfo) : this() {
this.expiredLogEventEndIndex = x.expiredLogEventEndIndex
this.tooNewLogEventStartIndex = x.tooNewLogEventStartIndex
this.tooOldLogEventEndIndex = x.tooOldLogEventEndIndex
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cloudwatchlogs.model.RejectedLogEventsInfo = RejectedLogEventsInfo(this)
internal fun correctErrors(): Builder {
return this
}
}
}