commonMain.aws.sdk.kotlin.services.proton.model.RepositorySyncDefinition.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of proton-jvm Show documentation
Show all versions of proton-jvm Show documentation
The AWS SDK for Kotlin client for Proton
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.proton.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* A repository sync definition.
*/
public class RepositorySyncDefinition private constructor(builder: Builder) {
/**
* The repository branch.
*/
public val branch: kotlin.String = requireNotNull(builder.branch) { "A non-null value must be provided for branch" }
/**
* The directory in the repository.
*/
public val directory: kotlin.String = requireNotNull(builder.directory) { "A non-null value must be provided for directory" }
/**
* The resource that is synced from.
*/
public val parent: kotlin.String = requireNotNull(builder.parent) { "A non-null value must be provided for parent" }
/**
* The resource that is synced to.
*/
public val target: kotlin.String = requireNotNull(builder.target) { "A non-null value must be provided for target" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.proton.model.RepositorySyncDefinition = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("RepositorySyncDefinition(")
append("branch=$branch,")
append("directory=$directory,")
append("parent=$parent,")
append("target=$target")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = branch.hashCode()
result = 31 * result + (directory.hashCode())
result = 31 * result + (parent.hashCode())
result = 31 * result + (target.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 RepositorySyncDefinition
if (branch != other.branch) return false
if (directory != other.directory) return false
if (parent != other.parent) return false
if (target != other.target) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.proton.model.RepositorySyncDefinition = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The repository branch.
*/
public var branch: kotlin.String? = null
/**
* The directory in the repository.
*/
public var directory: kotlin.String? = null
/**
* The resource that is synced from.
*/
public var parent: kotlin.String? = null
/**
* The resource that is synced to.
*/
public var target: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.proton.model.RepositorySyncDefinition) : this() {
this.branch = x.branch
this.directory = x.directory
this.parent = x.parent
this.target = x.target
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.proton.model.RepositorySyncDefinition = RepositorySyncDefinition(this)
internal fun correctErrors(): Builder {
if (branch == null) branch = ""
if (directory == null) directory = ""
if (parent == null) parent = ""
if (target == null) target = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy