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

com.pulumi.kubernetes.discovery.v1beta1.kotlin.outputs.EndpointSlice.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 4.18.2.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.kubernetes.discovery.v1beta1.kotlin.outputs

import com.pulumi.kubernetes.meta.v1.kotlin.outputs.ObjectMeta
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List

/**
 * EndpointSlice represents a subset of the endpoints that implement a service. For a given service there may be multiple EndpointSlice objects, selected by labels, which must be joined to produce the full set of endpoints.
 * @property addressType addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name.
 * @property apiVersion APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
 * @property endpoints endpoints is a list of unique endpoints in this slice. Each slice may include a maximum of 1000 endpoints.
 * @property kind Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
 * @property metadata Standard object's metadata.
 * @property ports ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. When ports is empty, it indicates that there are no defined ports. When a port is defined with a nil port value, it indicates "all ports". Each slice may include a maximum of 100 ports.
 */
public data class EndpointSlice(
    public val addressType: String,
    public val apiVersion: String? = null,
    public val endpoints: List,
    public val kind: String? = null,
    public val metadata: ObjectMeta? = null,
    public val ports: List? = null,
) {
    public companion object {
        public fun toKotlin(javaType: com.pulumi.kubernetes.discovery.v1beta1.outputs.EndpointSlice): EndpointSlice = EndpointSlice(
            addressType = javaType.addressType(),
            apiVersion = javaType.apiVersion().map({ args0 -> args0 }).orElse(null),
            endpoints = javaType.endpoints().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.discovery.v1beta1.kotlin.outputs.Endpoint.Companion.toKotlin(args0)
                })
            }),
            kind = javaType.kind().map({ args0 -> args0 }).orElse(null),
            metadata = javaType.metadata().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.meta.v1.kotlin.outputs.ObjectMeta.Companion.toKotlin(args0)
                })
            }).orElse(null),
            ports = javaType.ports().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.discovery.v1beta1.kotlin.outputs.EndpointPort.Companion.toKotlin(args0)
                })
            }),
        )
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy