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

commonMain.aws.sdk.kotlin.services.pipes.model.PipeTargetParameters.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.pipes.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * The parameters required to set up a target for your pipe.
 *
 * For more information about pipe target parameters, including how to use dynamic path parameters, see [Target parameters](https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-pipes-event-target.html) in the *Amazon EventBridge User Guide*.
 */
public class PipeTargetParameters private constructor(builder: Builder) {
    /**
     * The parameters for using an Batch job as a target.
     */
    public val batchJobParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetBatchJobParameters? = builder.batchJobParameters
    /**
     * The parameters for using an CloudWatch Logs log stream as a target.
     */
    public val cloudWatchLogsParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetCloudWatchLogsParameters? = builder.cloudWatchLogsParameters
    /**
     * The parameters for using an Amazon ECS task as a target.
     */
    public val ecsTaskParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetEcsTaskParameters? = builder.ecsTaskParameters
    /**
     * The parameters for using an EventBridge event bus as a target.
     */
    public val eventBridgeEventBusParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetEventBridgeEventBusParameters? = builder.eventBridgeEventBusParameters
    /**
     * These are custom parameter to be used when the target is an API Gateway REST APIs or EventBridge ApiDestinations.
     */
    public val httpParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetHttpParameters? = builder.httpParameters
    /**
     * Valid JSON text passed to the target. In this case, nothing from the event itself is passed to the target. For more information, see [The JavaScript Object Notation (JSON) Data Interchange Format](http://www.rfc-editor.org/rfc/rfc7159.txt).
     *
     * To remove an input template, specify an empty string.
     */
    public val inputTemplate: kotlin.String? = builder.inputTemplate
    /**
     * The parameters for using a Kinesis stream as a target.
     */
    public val kinesisStreamParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetKinesisStreamParameters? = builder.kinesisStreamParameters
    /**
     * The parameters for using a Lambda function as a target.
     */
    public val lambdaFunctionParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetLambdaFunctionParameters? = builder.lambdaFunctionParameters
    /**
     * These are custom parameters to be used when the target is a Amazon Redshift cluster to invoke the Amazon Redshift Data API BatchExecuteStatement.
     */
    public val redshiftDataParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetRedshiftDataParameters? = builder.redshiftDataParameters
    /**
     * The parameters for using a SageMaker pipeline as a target.
     */
    public val sageMakerPipelineParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetSageMakerPipelineParameters? = builder.sageMakerPipelineParameters
    /**
     * The parameters for using a Amazon SQS stream as a target.
     */
    public val sqsQueueParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetSqsQueueParameters? = builder.sqsQueueParameters
    /**
     * The parameters for using a Step Functions state machine as a target.
     */
    public val stepFunctionStateMachineParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetStateMachineParameters? = builder.stepFunctionStateMachineParameters

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

    override fun toString(): kotlin.String = buildString {
        append("PipeTargetParameters(")
        append("batchJobParameters=$batchJobParameters,")
        append("cloudWatchLogsParameters=$cloudWatchLogsParameters,")
        append("ecsTaskParameters=$ecsTaskParameters,")
        append("eventBridgeEventBusParameters=$eventBridgeEventBusParameters,")
        append("httpParameters=$httpParameters,")
        append("inputTemplate=*** Sensitive Data Redacted ***,")
        append("kinesisStreamParameters=$kinesisStreamParameters,")
        append("lambdaFunctionParameters=$lambdaFunctionParameters,")
        append("redshiftDataParameters=$redshiftDataParameters,")
        append("sageMakerPipelineParameters=$sageMakerPipelineParameters,")
        append("sqsQueueParameters=$sqsQueueParameters,")
        append("stepFunctionStateMachineParameters=$stepFunctionStateMachineParameters")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = batchJobParameters?.hashCode() ?: 0
        result = 31 * result + (cloudWatchLogsParameters?.hashCode() ?: 0)
        result = 31 * result + (ecsTaskParameters?.hashCode() ?: 0)
        result = 31 * result + (eventBridgeEventBusParameters?.hashCode() ?: 0)
        result = 31 * result + (httpParameters?.hashCode() ?: 0)
        result = 31 * result + (inputTemplate?.hashCode() ?: 0)
        result = 31 * result + (kinesisStreamParameters?.hashCode() ?: 0)
        result = 31 * result + (lambdaFunctionParameters?.hashCode() ?: 0)
        result = 31 * result + (redshiftDataParameters?.hashCode() ?: 0)
        result = 31 * result + (sageMakerPipelineParameters?.hashCode() ?: 0)
        result = 31 * result + (sqsQueueParameters?.hashCode() ?: 0)
        result = 31 * result + (stepFunctionStateMachineParameters?.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 PipeTargetParameters

        if (batchJobParameters != other.batchJobParameters) return false
        if (cloudWatchLogsParameters != other.cloudWatchLogsParameters) return false
        if (ecsTaskParameters != other.ecsTaskParameters) return false
        if (eventBridgeEventBusParameters != other.eventBridgeEventBusParameters) return false
        if (httpParameters != other.httpParameters) return false
        if (inputTemplate != other.inputTemplate) return false
        if (kinesisStreamParameters != other.kinesisStreamParameters) return false
        if (lambdaFunctionParameters != other.lambdaFunctionParameters) return false
        if (redshiftDataParameters != other.redshiftDataParameters) return false
        if (sageMakerPipelineParameters != other.sageMakerPipelineParameters) return false
        if (sqsQueueParameters != other.sqsQueueParameters) return false
        if (stepFunctionStateMachineParameters != other.stepFunctionStateMachineParameters) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The parameters for using an Batch job as a target.
         */
        public var batchJobParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetBatchJobParameters? = null
        /**
         * The parameters for using an CloudWatch Logs log stream as a target.
         */
        public var cloudWatchLogsParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetCloudWatchLogsParameters? = null
        /**
         * The parameters for using an Amazon ECS task as a target.
         */
        public var ecsTaskParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetEcsTaskParameters? = null
        /**
         * The parameters for using an EventBridge event bus as a target.
         */
        public var eventBridgeEventBusParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetEventBridgeEventBusParameters? = null
        /**
         * These are custom parameter to be used when the target is an API Gateway REST APIs or EventBridge ApiDestinations.
         */
        public var httpParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetHttpParameters? = null
        /**
         * Valid JSON text passed to the target. In this case, nothing from the event itself is passed to the target. For more information, see [The JavaScript Object Notation (JSON) Data Interchange Format](http://www.rfc-editor.org/rfc/rfc7159.txt).
         *
         * To remove an input template, specify an empty string.
         */
        public var inputTemplate: kotlin.String? = null
        /**
         * The parameters for using a Kinesis stream as a target.
         */
        public var kinesisStreamParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetKinesisStreamParameters? = null
        /**
         * The parameters for using a Lambda function as a target.
         */
        public var lambdaFunctionParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetLambdaFunctionParameters? = null
        /**
         * These are custom parameters to be used when the target is a Amazon Redshift cluster to invoke the Amazon Redshift Data API BatchExecuteStatement.
         */
        public var redshiftDataParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetRedshiftDataParameters? = null
        /**
         * The parameters for using a SageMaker pipeline as a target.
         */
        public var sageMakerPipelineParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetSageMakerPipelineParameters? = null
        /**
         * The parameters for using a Amazon SQS stream as a target.
         */
        public var sqsQueueParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetSqsQueueParameters? = null
        /**
         * The parameters for using a Step Functions state machine as a target.
         */
        public var stepFunctionStateMachineParameters: aws.sdk.kotlin.services.pipes.model.PipeTargetStateMachineParameters? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.pipes.model.PipeTargetParameters) : this() {
            this.batchJobParameters = x.batchJobParameters
            this.cloudWatchLogsParameters = x.cloudWatchLogsParameters
            this.ecsTaskParameters = x.ecsTaskParameters
            this.eventBridgeEventBusParameters = x.eventBridgeEventBusParameters
            this.httpParameters = x.httpParameters
            this.inputTemplate = x.inputTemplate
            this.kinesisStreamParameters = x.kinesisStreamParameters
            this.lambdaFunctionParameters = x.lambdaFunctionParameters
            this.redshiftDataParameters = x.redshiftDataParameters
            this.sageMakerPipelineParameters = x.sageMakerPipelineParameters
            this.sqsQueueParameters = x.sqsQueueParameters
            this.stepFunctionStateMachineParameters = x.stepFunctionStateMachineParameters
        }

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

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

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

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

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

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

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

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

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

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

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy