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

commonMain.aws.sdk.kotlin.services.kinesisvideo.model.ChannelNameCondition.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.kinesisvideo.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * An optional input parameter for the `ListSignalingChannels` API. When this parameter is specified while invoking `ListSignalingChannels`, the API returns only the channels that satisfy a condition specified in `ChannelNameCondition`.
 */
public class ChannelNameCondition private constructor(builder: Builder) {
    /**
     * A comparison operator. Currently, you can only specify the `BEGINS_WITH` operator, which finds signaling channels whose names begin with a given prefix.
     */
    public val comparisonOperator: aws.sdk.kotlin.services.kinesisvideo.model.ComparisonOperator? = builder.comparisonOperator
    /**
     * A value to compare.
     */
    public val comparisonValue: kotlin.String? = builder.comparisonValue

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

    override fun toString(): kotlin.String = buildString {
        append("ChannelNameCondition(")
        append("comparisonOperator=$comparisonOperator,")
        append("comparisonValue=$comparisonValue")
        append(")")
    }

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

        if (comparisonOperator != other.comparisonOperator) return false
        if (comparisonValue != other.comparisonValue) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * A comparison operator. Currently, you can only specify the `BEGINS_WITH` operator, which finds signaling channels whose names begin with a given prefix.
         */
        public var comparisonOperator: aws.sdk.kotlin.services.kinesisvideo.model.ComparisonOperator? = null
        /**
         * A value to compare.
         */
        public var comparisonValue: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kinesisvideo.model.ChannelNameCondition) : this() {
            this.comparisonOperator = x.comparisonOperator
            this.comparisonValue = x.comparisonValue
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy