
commonMain.aws.sdk.kotlin.services.lightsail.model.GetAlarmsRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.lightsail.model
public class GetAlarmsRequest private constructor(builder: Builder) {
/**
* The name of the alarm.
*
* Specify an alarm name to return information about a specific alarm.
*/
public val alarmName: kotlin.String? = builder.alarmName
/**
* The name of the Lightsail resource being monitored by the alarm.
*
* Specify a monitored resource name to return information about all alarms for a specific resource.
*/
public val monitoredResourceName: kotlin.String? = builder.monitoredResourceName
/**
* The token to advance to the next page of results from your request.
*
* To get a page token, perform an initial `GetAlarms` request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.
*/
public val pageToken: kotlin.String? = builder.pageToken
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.lightsail.model.GetAlarmsRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetAlarmsRequest(")
append("alarmName=$alarmName,")
append("monitoredResourceName=$monitoredResourceName,")
append("pageToken=$pageToken)")
}
override fun hashCode(): kotlin.Int {
var result = alarmName?.hashCode() ?: 0
result = 31 * result + (monitoredResourceName?.hashCode() ?: 0)
result = 31 * result + (pageToken?.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 GetAlarmsRequest
if (alarmName != other.alarmName) return false
if (monitoredResourceName != other.monitoredResourceName) return false
if (pageToken != other.pageToken) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.lightsail.model.GetAlarmsRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The name of the alarm.
*
* Specify an alarm name to return information about a specific alarm.
*/
public var alarmName: kotlin.String? = null
/**
* The name of the Lightsail resource being monitored by the alarm.
*
* Specify a monitored resource name to return information about all alarms for a specific resource.
*/
public var monitoredResourceName: kotlin.String? = null
/**
* The token to advance to the next page of results from your request.
*
* To get a page token, perform an initial `GetAlarms` request. If your results are paginated, the response will return a next page token that you can specify as the page token in a subsequent request.
*/
public var pageToken: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.lightsail.model.GetAlarmsRequest) : this() {
this.alarmName = x.alarmName
this.monitoredResourceName = x.monitoredResourceName
this.pageToken = x.pageToken
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.lightsail.model.GetAlarmsRequest = GetAlarmsRequest(this)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy