
commonMain.aws.sdk.kotlin.services.iot.model.PutAssetPropertyValueEntry.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.iot.model
/**
* An asset property value entry containing the following information.
*/
public class PutAssetPropertyValueEntry private constructor(builder: Builder) {
/**
* The ID of the IoT SiteWise asset. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public val assetId: kotlin.String? = builder.assetId
/**
* Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
*/
public val entryId: kotlin.String? = builder.entryId
/**
* The name of the property alias associated with your asset property. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public val propertyAlias: kotlin.String? = builder.propertyAlias
/**
* The ID of the asset's property. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public val propertyId: kotlin.String? = builder.propertyId
/**
* A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
*/
public val propertyValues: List = requireNotNull(builder.propertyValues) { "A non-null value must be provided for propertyValues" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iot.model.PutAssetPropertyValueEntry = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("PutAssetPropertyValueEntry(")
append("assetId=$assetId,")
append("entryId=$entryId,")
append("propertyAlias=$propertyAlias,")
append("propertyId=$propertyId,")
append("propertyValues=$propertyValues")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = assetId?.hashCode() ?: 0
result = 31 * result + (entryId?.hashCode() ?: 0)
result = 31 * result + (propertyAlias?.hashCode() ?: 0)
result = 31 * result + (propertyId?.hashCode() ?: 0)
result = 31 * result + (propertyValues.hashCode())
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 PutAssetPropertyValueEntry
if (assetId != other.assetId) return false
if (entryId != other.entryId) return false
if (propertyAlias != other.propertyAlias) return false
if (propertyId != other.propertyId) return false
if (propertyValues != other.propertyValues) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iot.model.PutAssetPropertyValueEntry = Builder(this).apply(block).build()
public class Builder {
/**
* The ID of the IoT SiteWise asset. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public var assetId: kotlin.String? = null
/**
* Optional. A unique identifier for this entry that you can define to better track which message caused an error in case of failure. Accepts substitution templates. Defaults to a new UUID.
*/
public var entryId: kotlin.String? = null
/**
* The name of the property alias associated with your asset property. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public var propertyAlias: kotlin.String? = null
/**
* The ID of the asset's property. You must specify either a `propertyAlias` or both an `aliasId` and a `propertyId`. Accepts substitution templates.
*/
public var propertyId: kotlin.String? = null
/**
* A list of property values to insert that each contain timestamp, quality, and value (TQV) information.
*/
public var propertyValues: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.iot.model.PutAssetPropertyValueEntry) : this() {
this.assetId = x.assetId
this.entryId = x.entryId
this.propertyAlias = x.propertyAlias
this.propertyId = x.propertyId
this.propertyValues = x.propertyValues
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.iot.model.PutAssetPropertyValueEntry = PutAssetPropertyValueEntry(this)
internal fun correctErrors(): Builder {
if (propertyValues == null) propertyValues = emptyList()
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy