
commonMain.aws.sdk.kotlin.services.rekognition.model.PersonDetail.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.rekognition.model
/**
* Details about a person detected in a video analysis request.
*/
public class PersonDetail private constructor(builder: Builder) {
/**
* Bounding box around the detected person.
*/
public val boundingBox: aws.sdk.kotlin.services.rekognition.model.BoundingBox? = builder.boundingBox
/**
* Face details for the detected person.
*/
public val face: aws.sdk.kotlin.services.rekognition.model.FaceDetail? = builder.face
/**
* Identifier for the person detected person within a video. Use to keep track of the person throughout the video. The identifier is not stored by Amazon Rekognition.
*/
public val index: kotlin.Long = builder.index
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.rekognition.model.PersonDetail = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("PersonDetail(")
append("boundingBox=$boundingBox,")
append("face=$face,")
append("index=$index")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = boundingBox?.hashCode() ?: 0
result = 31 * result + (face?.hashCode() ?: 0)
result = 31 * result + (index.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 PersonDetail
if (boundingBox != other.boundingBox) return false
if (face != other.face) return false
if (index != other.index) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.rekognition.model.PersonDetail = Builder(this).apply(block).build()
public class Builder {
/**
* Bounding box around the detected person.
*/
public var boundingBox: aws.sdk.kotlin.services.rekognition.model.BoundingBox? = null
/**
* Face details for the detected person.
*/
public var face: aws.sdk.kotlin.services.rekognition.model.FaceDetail? = null
/**
* Identifier for the person detected person within a video. Use to keep track of the person throughout the video. The identifier is not stored by Amazon Rekognition.
*/
public var index: kotlin.Long = 0L
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.rekognition.model.PersonDetail) : this() {
this.boundingBox = x.boundingBox
this.face = x.face
this.index = x.index
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.rekognition.model.PersonDetail = PersonDetail(this)
/**
* construct an [aws.sdk.kotlin.services.rekognition.model.BoundingBox] inside the given [block]
*/
public fun boundingBox(block: aws.sdk.kotlin.services.rekognition.model.BoundingBox.Builder.() -> kotlin.Unit) {
this.boundingBox = aws.sdk.kotlin.services.rekognition.model.BoundingBox.invoke(block)
}
/**
* construct an [aws.sdk.kotlin.services.rekognition.model.FaceDetail] inside the given [block]
*/
public fun face(block: aws.sdk.kotlin.services.rekognition.model.FaceDetail.Builder.() -> kotlin.Unit) {
this.face = aws.sdk.kotlin.services.rekognition.model.FaceDetail.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy