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

commonMain.aws.sdk.kotlin.services.translate.model.ParallelDataProperties.kt Maven / Gradle / Ivy

There is a newer version: 1.3.78
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.translate.model

import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant

/**
 * The properties of a parallel data resource.
 */
public class ParallelDataProperties private constructor(builder: Builder) {
    /**
     * The Amazon Resource Name (ARN) of the parallel data resource.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * The time at which the parallel data resource was created.
     */
    public val createdAt: aws.smithy.kotlin.runtime.time.Instant? = builder.createdAt
    /**
     * The description assigned to the parallel data resource.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The encryption key used to encrypt this object.
     */
    public val encryptionKey: aws.sdk.kotlin.services.translate.model.EncryptionKey? = builder.encryptionKey
    /**
     * The number of records unsuccessfully imported from the parallel data input file.
     */
    public val failedRecordCount: kotlin.Long? = builder.failedRecordCount
    /**
     * The number of UTF-8 characters that Amazon Translate imported from the parallel data input file. This number includes only the characters in your translation examples. It does not include characters that are used to format your file. For example, if you provided a Translation Memory Exchange (.tmx) file, this number does not include the tags.
     */
    public val importedDataSize: kotlin.Long? = builder.importedDataSize
    /**
     * The number of records successfully imported from the parallel data input file.
     */
    public val importedRecordCount: kotlin.Long? = builder.importedRecordCount
    /**
     * The time at which the parallel data resource was last updated.
     */
    public val lastUpdatedAt: aws.smithy.kotlin.runtime.time.Instant? = builder.lastUpdatedAt
    /**
     * The time that the most recent update was attempted.
     */
    public val latestUpdateAttemptAt: aws.smithy.kotlin.runtime.time.Instant? = builder.latestUpdateAttemptAt
    /**
     * The status of the most recent update attempt for the parallel data resource.
     */
    public val latestUpdateAttemptStatus: aws.sdk.kotlin.services.translate.model.ParallelDataStatus? = builder.latestUpdateAttemptStatus
    /**
     * Additional information from Amazon Translate about the parallel data resource.
     */
    public val message: kotlin.String? = builder.message
    /**
     * The custom name assigned to the parallel data resource.
     */
    public val name: kotlin.String? = builder.name
    /**
     * Specifies the format and S3 location of the parallel data input file.
     */
    public val parallelDataConfig: aws.sdk.kotlin.services.translate.model.ParallelDataConfig? = builder.parallelDataConfig
    /**
     * The number of items in the input file that Amazon Translate skipped when you created or updated the parallel data resource. For example, Amazon Translate skips empty records, empty target texts, and empty lines.
     */
    public val skippedRecordCount: kotlin.Long? = builder.skippedRecordCount
    /**
     * The source language of the translations in the parallel data file.
     */
    public val sourceLanguageCode: kotlin.String? = builder.sourceLanguageCode
    /**
     * The status of the parallel data resource. When the parallel data is ready for you to use, the status is `ACTIVE`.
     */
    public val status: aws.sdk.kotlin.services.translate.model.ParallelDataStatus? = builder.status
    /**
     * The language codes for the target languages available in the parallel data file. All possible target languages are returned as an array.
     */
    public val targetLanguageCodes: List? = builder.targetLanguageCodes

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

    override fun toString(): kotlin.String = buildString {
        append("ParallelDataProperties(")
        append("arn=$arn,")
        append("createdAt=$createdAt,")
        append("description=$description,")
        append("encryptionKey=$encryptionKey,")
        append("failedRecordCount=$failedRecordCount,")
        append("importedDataSize=$importedDataSize,")
        append("importedRecordCount=$importedRecordCount,")
        append("lastUpdatedAt=$lastUpdatedAt,")
        append("latestUpdateAttemptAt=$latestUpdateAttemptAt,")
        append("latestUpdateAttemptStatus=$latestUpdateAttemptStatus,")
        append("message=$message,")
        append("name=$name,")
        append("parallelDataConfig=$parallelDataConfig,")
        append("skippedRecordCount=$skippedRecordCount,")
        append("sourceLanguageCode=$sourceLanguageCode,")
        append("status=$status,")
        append("targetLanguageCodes=$targetLanguageCodes")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (createdAt?.hashCode() ?: 0)
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (encryptionKey?.hashCode() ?: 0)
        result = 31 * result + (failedRecordCount?.hashCode() ?: 0)
        result = 31 * result + (importedDataSize?.hashCode() ?: 0)
        result = 31 * result + (importedRecordCount?.hashCode() ?: 0)
        result = 31 * result + (lastUpdatedAt?.hashCode() ?: 0)
        result = 31 * result + (latestUpdateAttemptAt?.hashCode() ?: 0)
        result = 31 * result + (latestUpdateAttemptStatus?.hashCode() ?: 0)
        result = 31 * result + (message?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (parallelDataConfig?.hashCode() ?: 0)
        result = 31 * result + (skippedRecordCount?.hashCode() ?: 0)
        result = 31 * result + (sourceLanguageCode?.hashCode() ?: 0)
        result = 31 * result + (status?.hashCode() ?: 0)
        result = 31 * result + (targetLanguageCodes?.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 ParallelDataProperties

        if (arn != other.arn) return false
        if (createdAt != other.createdAt) return false
        if (description != other.description) return false
        if (encryptionKey != other.encryptionKey) return false
        if (failedRecordCount != other.failedRecordCount) return false
        if (importedDataSize != other.importedDataSize) return false
        if (importedRecordCount != other.importedRecordCount) return false
        if (lastUpdatedAt != other.lastUpdatedAt) return false
        if (latestUpdateAttemptAt != other.latestUpdateAttemptAt) return false
        if (latestUpdateAttemptStatus != other.latestUpdateAttemptStatus) return false
        if (message != other.message) return false
        if (name != other.name) return false
        if (parallelDataConfig != other.parallelDataConfig) return false
        if (skippedRecordCount != other.skippedRecordCount) return false
        if (sourceLanguageCode != other.sourceLanguageCode) return false
        if (status != other.status) return false
        if (targetLanguageCodes != other.targetLanguageCodes) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The Amazon Resource Name (ARN) of the parallel data resource.
         */
        public var arn: kotlin.String? = null
        /**
         * The time at which the parallel data resource was created.
         */
        public var createdAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The description assigned to the parallel data resource.
         */
        public var description: kotlin.String? = null
        /**
         * The encryption key used to encrypt this object.
         */
        public var encryptionKey: aws.sdk.kotlin.services.translate.model.EncryptionKey? = null
        /**
         * The number of records unsuccessfully imported from the parallel data input file.
         */
        public var failedRecordCount: kotlin.Long? = null
        /**
         * The number of UTF-8 characters that Amazon Translate imported from the parallel data input file. This number includes only the characters in your translation examples. It does not include characters that are used to format your file. For example, if you provided a Translation Memory Exchange (.tmx) file, this number does not include the tags.
         */
        public var importedDataSize: kotlin.Long? = null
        /**
         * The number of records successfully imported from the parallel data input file.
         */
        public var importedRecordCount: kotlin.Long? = null
        /**
         * The time at which the parallel data resource was last updated.
         */
        public var lastUpdatedAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The time that the most recent update was attempted.
         */
        public var latestUpdateAttemptAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The status of the most recent update attempt for the parallel data resource.
         */
        public var latestUpdateAttemptStatus: aws.sdk.kotlin.services.translate.model.ParallelDataStatus? = null
        /**
         * Additional information from Amazon Translate about the parallel data resource.
         */
        public var message: kotlin.String? = null
        /**
         * The custom name assigned to the parallel data resource.
         */
        public var name: kotlin.String? = null
        /**
         * Specifies the format and S3 location of the parallel data input file.
         */
        public var parallelDataConfig: aws.sdk.kotlin.services.translate.model.ParallelDataConfig? = null
        /**
         * The number of items in the input file that Amazon Translate skipped when you created or updated the parallel data resource. For example, Amazon Translate skips empty records, empty target texts, and empty lines.
         */
        public var skippedRecordCount: kotlin.Long? = null
        /**
         * The source language of the translations in the parallel data file.
         */
        public var sourceLanguageCode: kotlin.String? = null
        /**
         * The status of the parallel data resource. When the parallel data is ready for you to use, the status is `ACTIVE`.
         */
        public var status: aws.sdk.kotlin.services.translate.model.ParallelDataStatus? = null
        /**
         * The language codes for the target languages available in the parallel data file. All possible target languages are returned as an array.
         */
        public var targetLanguageCodes: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.translate.model.ParallelDataProperties) : this() {
            this.arn = x.arn
            this.createdAt = x.createdAt
            this.description = x.description
            this.encryptionKey = x.encryptionKey
            this.failedRecordCount = x.failedRecordCount
            this.importedDataSize = x.importedDataSize
            this.importedRecordCount = x.importedRecordCount
            this.lastUpdatedAt = x.lastUpdatedAt
            this.latestUpdateAttemptAt = x.latestUpdateAttemptAt
            this.latestUpdateAttemptStatus = x.latestUpdateAttemptStatus
            this.message = x.message
            this.name = x.name
            this.parallelDataConfig = x.parallelDataConfig
            this.skippedRecordCount = x.skippedRecordCount
            this.sourceLanguageCode = x.sourceLanguageCode
            this.status = x.status
            this.targetLanguageCodes = x.targetLanguageCodes
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.translate.model.EncryptionKey] inside the given [block]
         */
        public fun encryptionKey(block: aws.sdk.kotlin.services.translate.model.EncryptionKey.Builder.() -> kotlin.Unit) {
            this.encryptionKey = aws.sdk.kotlin.services.translate.model.EncryptionKey.invoke(block)
        }

        /**
         * construct an [aws.sdk.kotlin.services.translate.model.ParallelDataConfig] inside the given [block]
         */
        public fun parallelDataConfig(block: aws.sdk.kotlin.services.translate.model.ParallelDataConfig.Builder.() -> kotlin.Unit) {
            this.parallelDataConfig = aws.sdk.kotlin.services.translate.model.ParallelDataConfig.invoke(block)
        }

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy