All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.rekognition.model.FaceOccluded.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

/**
 * `FaceOccluded` should return "true" with a high confidence score if a detected face’s eyes, nose, and mouth are partially captured or if they are covered by masks, dark sunglasses, cell phones, hands, or other objects. `FaceOccluded` should return "false" with a high confidence score if common occurrences that do not impact face verification are detected, such as eye glasses, lightly tinted sunglasses, strands of hair, and others.
 *
 * You can use `FaceOccluded` to determine if an obstruction on a face negatively impacts using the image for face matching.
 */
public class FaceOccluded private constructor(builder: Builder) {
    /**
     * The confidence that the service has detected the presence of a face occlusion.
     */
    public val confidence: kotlin.Float? = builder.confidence
    /**
     * True if a detected face’s eyes, nose, and mouth are partially captured or if they are covered by masks, dark sunglasses, cell phones, hands, or other objects. False if common occurrences that do not impact face verification are detected, such as eye glasses, lightly tinted sunglasses, strands of hair, and others.
     */
    public val value: kotlin.Boolean = builder.value

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.rekognition.model.FaceOccluded = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("FaceOccluded(")
        append("confidence=$confidence,")
        append("value=$value")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = confidence?.hashCode() ?: 0
        result = 31 * result + (value.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 FaceOccluded

        if (!(confidence?.equals(other.confidence) ?: (other.confidence == null))) return false
        if (value != other.value) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.rekognition.model.FaceOccluded = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * The confidence that the service has detected the presence of a face occlusion.
         */
        public var confidence: kotlin.Float? = null
        /**
         * True if a detected face’s eyes, nose, and mouth are partially captured or if they are covered by masks, dark sunglasses, cell phones, hands, or other objects. False if common occurrences that do not impact face verification are detected, such as eye glasses, lightly tinted sunglasses, strands of hair, and others.
         */
        public var value: kotlin.Boolean = false

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.rekognition.model.FaceOccluded) : this() {
            this.confidence = x.confidence
            this.value = x.value
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.rekognition.model.FaceOccluded = FaceOccluded(this)

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy