
commonMain.aws.sdk.kotlin.services.rekognition.model.SearchUsersByImageResponse.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.rekognition.model
import aws.smithy.kotlin.runtime.SdkDsl
public class SearchUsersByImageResponse private constructor(builder: Builder) {
/**
* Version number of the face detection model associated with the input collection CollectionId.
*/
public val faceModelVersion: kotlin.String? = builder.faceModelVersion
/**
* A list of FaceDetail objects containing the BoundingBox for the largest face in image, as well as the confidence in the bounding box, that was searched for matches. If no valid face is detected in the image the response will contain no SearchedFace object.
*/
public val searchedFace: aws.sdk.kotlin.services.rekognition.model.SearchedFaceDetails? = builder.searchedFace
/**
* List of UnsearchedFace objects. Contains the face details infered from the specified image but not used for search. Contains reasons that describe why a face wasn't used for Search.
*/
public val unsearchedFaces: List? = builder.unsearchedFaces
/**
* An array of UserID objects that matched the input face, along with the confidence in the match. The returned structure will be empty if there are no matches. Returned if the SearchUsersByImageResponse action is successful.
*/
public val userMatches: List? = builder.userMatches
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.rekognition.model.SearchUsersByImageResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("SearchUsersByImageResponse(")
append("faceModelVersion=$faceModelVersion,")
append("searchedFace=$searchedFace,")
append("unsearchedFaces=$unsearchedFaces,")
append("userMatches=$userMatches")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = faceModelVersion?.hashCode() ?: 0
result = 31 * result + (searchedFace?.hashCode() ?: 0)
result = 31 * result + (unsearchedFaces?.hashCode() ?: 0)
result = 31 * result + (userMatches?.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 SearchUsersByImageResponse
if (faceModelVersion != other.faceModelVersion) return false
if (searchedFace != other.searchedFace) return false
if (unsearchedFaces != other.unsearchedFaces) return false
if (userMatches != other.userMatches) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.rekognition.model.SearchUsersByImageResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Version number of the face detection model associated with the input collection CollectionId.
*/
public var faceModelVersion: kotlin.String? = null
/**
* A list of FaceDetail objects containing the BoundingBox for the largest face in image, as well as the confidence in the bounding box, that was searched for matches. If no valid face is detected in the image the response will contain no SearchedFace object.
*/
public var searchedFace: aws.sdk.kotlin.services.rekognition.model.SearchedFaceDetails? = null
/**
* List of UnsearchedFace objects. Contains the face details infered from the specified image but not used for search. Contains reasons that describe why a face wasn't used for Search.
*/
public var unsearchedFaces: List? = null
/**
* An array of UserID objects that matched the input face, along with the confidence in the match. The returned structure will be empty if there are no matches. Returned if the SearchUsersByImageResponse action is successful.
*/
public var userMatches: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.rekognition.model.SearchUsersByImageResponse) : this() {
this.faceModelVersion = x.faceModelVersion
this.searchedFace = x.searchedFace
this.unsearchedFaces = x.unsearchedFaces
this.userMatches = x.userMatches
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.rekognition.model.SearchUsersByImageResponse = SearchUsersByImageResponse(this)
/**
* construct an [aws.sdk.kotlin.services.rekognition.model.SearchedFaceDetails] inside the given [block]
*/
public fun searchedFace(block: aws.sdk.kotlin.services.rekognition.model.SearchedFaceDetails.Builder.() -> kotlin.Unit) {
this.searchedFace = aws.sdk.kotlin.services.rekognition.model.SearchedFaceDetails.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy