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

commonMain.aws.sdk.kotlin.services.appflow.model.AggregationConfig.kt Maven / Gradle / Ivy

The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.appflow.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * The aggregation settings that you can use to customize the output format of your flow data.
 */
public class AggregationConfig private constructor(builder: Builder) {
    /**
     * Specifies whether Amazon AppFlow aggregates the flow records into a single file, or leave them unaggregated.
     */
    public val aggregationType: aws.sdk.kotlin.services.appflow.model.AggregationType? = builder.aggregationType
    /**
     * The desired file size, in MB, for each output file that Amazon AppFlow writes to the flow destination. For each file, Amazon AppFlow attempts to achieve the size that you specify. The actual file sizes might differ from this target based on the number and size of the records that each file contains.
     */
    public val targetFileSize: kotlin.Long? = builder.targetFileSize

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

    override fun toString(): kotlin.String = buildString {
        append("AggregationConfig(")
        append("aggregationType=$aggregationType,")
        append("targetFileSize=$targetFileSize")
        append(")")
    }

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

        if (aggregationType != other.aggregationType) return false
        if (targetFileSize != other.targetFileSize) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * Specifies whether Amazon AppFlow aggregates the flow records into a single file, or leave them unaggregated.
         */
        public var aggregationType: aws.sdk.kotlin.services.appflow.model.AggregationType? = null
        /**
         * The desired file size, in MB, for each output file that Amazon AppFlow writes to the flow destination. For each file, Amazon AppFlow attempts to achieve the size that you specify. The actual file sizes might differ from this target based on the number and size of the records that each file contains.
         */
        public var targetFileSize: kotlin.Long? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.appflow.model.AggregationConfig) : this() {
            this.aggregationType = x.aggregationType
            this.targetFileSize = x.targetFileSize
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy