
commonMain.aws.sdk.kotlin.services.directconnect.model.NewTransitVirtualInterfaceAllocation.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.directconnect.model
/**
* Information about a transit virtual interface to be provisioned on a connection.
*/
public class NewTransitVirtualInterfaceAllocation private constructor(builder: Builder) {
/**
* The address family for the BGP peer.
*/
public val addressFamily: aws.sdk.kotlin.services.directconnect.model.AddressFamily? = builder.addressFamily
/**
* The IP address assigned to the Amazon interface.
*/
public val amazonAddress: kotlin.String? = builder.amazonAddress
/**
* The autonomous system (AS) number for Border Gateway Protocol (BGP) configuration.
*
* The valid values are 1-2147483647.
*/
public val asn: kotlin.Int = builder.asn
/**
* The authentication key for BGP configuration. This string has a minimum length of 6 characters and and a maximun lenth of 80 characters.
*/
public val authKey: kotlin.String? = builder.authKey
/**
* The IP address assigned to the customer interface.
*/
public val customerAddress: kotlin.String? = builder.customerAddress
/**
* The maximum transmission unit (MTU), in bytes. The supported values are 1500 and 8500. The default value is 1500
*/
public val mtu: kotlin.Int? = builder.mtu
/**
* The tags associated with the transitive virtual interface.
*/
public val tags: List? = builder.tags
/**
* The name of the virtual interface assigned by the customer network. The name has a maximum of 100 characters. The following are valid characters: a-z, 0-9 and a hyphen (-).
*/
public val virtualInterfaceName: kotlin.String? = builder.virtualInterfaceName
/**
* The ID of the VLAN.
*/
public val vlan: kotlin.Int = builder.vlan
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.directconnect.model.NewTransitVirtualInterfaceAllocation = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("NewTransitVirtualInterfaceAllocation(")
append("addressFamily=$addressFamily,")
append("amazonAddress=$amazonAddress,")
append("asn=$asn,")
append("authKey=$authKey,")
append("customerAddress=$customerAddress,")
append("mtu=$mtu,")
append("tags=$tags,")
append("virtualInterfaceName=$virtualInterfaceName,")
append("vlan=$vlan")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = addressFamily?.hashCode() ?: 0
result = 31 * result + (amazonAddress?.hashCode() ?: 0)
result = 31 * result + (asn)
result = 31 * result + (authKey?.hashCode() ?: 0)
result = 31 * result + (customerAddress?.hashCode() ?: 0)
result = 31 * result + (mtu ?: 0)
result = 31 * result + (tags?.hashCode() ?: 0)
result = 31 * result + (virtualInterfaceName?.hashCode() ?: 0)
result = 31 * result + (vlan)
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 NewTransitVirtualInterfaceAllocation
if (addressFamily != other.addressFamily) return false
if (amazonAddress != other.amazonAddress) return false
if (asn != other.asn) return false
if (authKey != other.authKey) return false
if (customerAddress != other.customerAddress) return false
if (mtu != other.mtu) return false
if (tags != other.tags) return false
if (virtualInterfaceName != other.virtualInterfaceName) return false
if (vlan != other.vlan) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.directconnect.model.NewTransitVirtualInterfaceAllocation = Builder(this).apply(block).build()
public class Builder {
/**
* The address family for the BGP peer.
*/
public var addressFamily: aws.sdk.kotlin.services.directconnect.model.AddressFamily? = null
/**
* The IP address assigned to the Amazon interface.
*/
public var amazonAddress: kotlin.String? = null
/**
* The autonomous system (AS) number for Border Gateway Protocol (BGP) configuration.
*
* The valid values are 1-2147483647.
*/
public var asn: kotlin.Int = 0
/**
* The authentication key for BGP configuration. This string has a minimum length of 6 characters and and a maximun lenth of 80 characters.
*/
public var authKey: kotlin.String? = null
/**
* The IP address assigned to the customer interface.
*/
public var customerAddress: kotlin.String? = null
/**
* The maximum transmission unit (MTU), in bytes. The supported values are 1500 and 8500. The default value is 1500
*/
public var mtu: kotlin.Int? = null
/**
* The tags associated with the transitive virtual interface.
*/
public var tags: List? = null
/**
* The name of the virtual interface assigned by the customer network. The name has a maximum of 100 characters. The following are valid characters: a-z, 0-9 and a hyphen (-).
*/
public var virtualInterfaceName: kotlin.String? = null
/**
* The ID of the VLAN.
*/
public var vlan: kotlin.Int = 0
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.directconnect.model.NewTransitVirtualInterfaceAllocation) : this() {
this.addressFamily = x.addressFamily
this.amazonAddress = x.amazonAddress
this.asn = x.asn
this.authKey = x.authKey
this.customerAddress = x.customerAddress
this.mtu = x.mtu
this.tags = x.tags
this.virtualInterfaceName = x.virtualInterfaceName
this.vlan = x.vlan
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.directconnect.model.NewTransitVirtualInterfaceAllocation = NewTransitVirtualInterfaceAllocation(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy