commonMain.aws.sdk.kotlin.services.deadline.model.CreateBudgetRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of deadline-jvm Show documentation
Show all versions of deadline-jvm Show documentation
The AWS SDK for Kotlin client for deadline
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.deadline.model
import aws.smithy.kotlin.runtime.SdkDsl
public class CreateBudgetRequest private constructor(builder: Builder) {
/**
* The budget actions to specify what happens when the budget runs out.
*/
public val actions: List? = builder.actions
/**
* The dollar limit based on consumed usage.
*/
public val approximateDollarLimit: kotlin.Float? = builder.approximateDollarLimit
/**
* The unique token which the server uses to recognize retries of the same request.
*/
public val clientToken: kotlin.String? = builder.clientToken
/**
* The description of the budget.
*
* This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
*/
public val description: kotlin.String? = builder.description
/**
* The display name of the budget.
*
* This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
*/
public val displayName: kotlin.String? = builder.displayName
/**
* The farm ID to include in this budget.
*/
public val farmId: kotlin.String? = builder.farmId
/**
* The schedule to associate with this budget.
*/
public val schedule: aws.sdk.kotlin.services.deadline.model.BudgetSchedule? = builder.schedule
/**
* The queue ID provided to this budget to track usage.
*/
public val usageTrackingResource: aws.sdk.kotlin.services.deadline.model.UsageTrackingResource? = builder.usageTrackingResource
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.deadline.model.CreateBudgetRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateBudgetRequest(")
append("actions=$actions,")
append("approximateDollarLimit=$approximateDollarLimit,")
append("clientToken=$clientToken,")
append("description=*** Sensitive Data Redacted ***,")
append("displayName=$displayName,")
append("farmId=$farmId,")
append("schedule=$schedule,")
append("usageTrackingResource=$usageTrackingResource")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = actions?.hashCode() ?: 0
result = 31 * result + (approximateDollarLimit?.hashCode() ?: 0)
result = 31 * result + (clientToken?.hashCode() ?: 0)
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (displayName?.hashCode() ?: 0)
result = 31 * result + (farmId?.hashCode() ?: 0)
result = 31 * result + (schedule?.hashCode() ?: 0)
result = 31 * result + (usageTrackingResource?.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 CreateBudgetRequest
if (actions != other.actions) return false
if (!(approximateDollarLimit?.equals(other.approximateDollarLimit) ?: (other.approximateDollarLimit == null))) return false
if (clientToken != other.clientToken) return false
if (description != other.description) return false
if (displayName != other.displayName) return false
if (farmId != other.farmId) return false
if (schedule != other.schedule) return false
if (usageTrackingResource != other.usageTrackingResource) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.deadline.model.CreateBudgetRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The budget actions to specify what happens when the budget runs out.
*/
public var actions: List? = null
/**
* The dollar limit based on consumed usage.
*/
public var approximateDollarLimit: kotlin.Float? = null
/**
* The unique token which the server uses to recognize retries of the same request.
*/
public var clientToken: kotlin.String? = null
/**
* The description of the budget.
*
* This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
*/
public var description: kotlin.String? = null
/**
* The display name of the budget.
*
* This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
*/
public var displayName: kotlin.String? = null
/**
* The farm ID to include in this budget.
*/
public var farmId: kotlin.String? = null
/**
* The schedule to associate with this budget.
*/
public var schedule: aws.sdk.kotlin.services.deadline.model.BudgetSchedule? = null
/**
* The queue ID provided to this budget to track usage.
*/
public var usageTrackingResource: aws.sdk.kotlin.services.deadline.model.UsageTrackingResource? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.deadline.model.CreateBudgetRequest) : this() {
this.actions = x.actions
this.approximateDollarLimit = x.approximateDollarLimit
this.clientToken = x.clientToken
this.description = x.description
this.displayName = x.displayName
this.farmId = x.farmId
this.schedule = x.schedule
this.usageTrackingResource = x.usageTrackingResource
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.deadline.model.CreateBudgetRequest = CreateBudgetRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}