func ExistsInVersion(gvk *schema.GroupVersionKind, version *cluster.ServerVersion) bool {
	if gvk == nil || gvk.Empty() {
		return false
	}
	addedIn := AddedInVersion(gvk)
	return version.Compare(*addedIn) >= 0
}
ExistsInVersion returns true if the given GVK exists in the given k8s version.
package kinds
import (
	"fmt"
	"strings"
	"github.com/pulumi/pulumi-kubernetes/provider/v3/pkg/cluster"
	"k8s.io/apimachinery/pkg/runtime/schema"
)
var v18 = cluster.ServerVersion{Major: 1, Minor: 8}
var v19 = cluster.ServerVersion{Major: 1, Minor: 9}
var v110 = cluster.ServerVersion{Major: 1, Minor: 10}
var v111 = cluster.ServerVersion{Major: 1, Minor: 11}
var v112 = cluster.ServerVersion{Major: 1, Minor: 12}
var v113 = cluster.ServerVersion{Major: 1, Minor: 13}
var v114 = cluster.ServerVersion{Major: 1, Minor: 14}
var v116 = cluster.ServerVersion{Major: 1, Minor: 16}
var v117 = cluster.ServerVersion{Major: 1, Minor: 17}
var v118 = cluster.ServerVersion{Major: 1, Minor: 18}
var v119 = cluster.ServerVersion{Major: 1, Minor: 19}
var v120 = cluster.ServerVersion{Major: 1, Minor: 20}
var v121 = cluster.ServerVersion{Major: 1, Minor: 21}
var v122 = cluster.ServerVersion{Major: 1, Minor: 22}
var v125 = cluster.ServerVersion{Major: 1, Minor: 25}
func gvkStr(gvk schema.GroupVersionKind) string {
	return gvk.GroupVersion().String() + "/" + gvk.Kind
}
func gvkFromStr(str string) (gvk schema.GroupVersionKind) {
	parts := strings.Split(str, "/")
	if len(parts) == 3 {
		return schema.GroupVersionKind{Group: parts[0], Version: parts[1], Kind: parts[2]}
	}
	return
}
func DeprecatedAPIVersion(gvk schema.GroupVersionKind, version *cluster.ServerVersion) bool {
	suggestedGVKString := SuggestedAPIVersion(gvk)
	if version == nil {
		return suggestedGVKString != gvkStr(gvk)
	}
	suggestedGVK := gvkFromStr(suggestedGVKString)
	suggestedGVKExists := ExistsInVersion(&suggestedGVK, version)
	return suggestedGVKExists && suggestedGVKString != gvkStr(gvk)
}
func AddedInVersion(gvk *schema.GroupVersionKind) *cluster.ServerVersion {
	gv, k := groupVersion(gvk.GroupVersion().String()), Kind(gvk.Kind)
	switch gv {
	case AdmissionregistrationV1:
		switch k {
		case MutatingWebhookConfiguration, MutatingWebhookConfigurationList, ValidatingWebhookConfiguration, ValidatingWebhookConfigurationList:
			return &v116
		}
	case ApiextensionsV1B1:
		switch k {
		case CustomResourceDefinition, CustomResourceDefinitionList:
			return &v111
		}
	case ApiextensionsV1:
		switch k {
		case CustomResourceDefinition, CustomResourceDefinitionList:
			return &v116
		}
	case ApiregistrationV1, ApiregistrationV1B1:
		switch k {
		case APIService, APIServiceList:
			return &v111
		}
	case AuditregistrationV1A1:
		switch k {
		case AuditSink, AuditSinkList:
			return &v113
		}
	case AuthenticationV1:
		switch k {
		case TokenRequest:
			return &v116
		}
	case AutoscalingV2B2:
		switch k {
		case HorizontalPodAutoscaler, HorizontalPodAutoscalerList:
			return &v112
		}
	case BatchV1:
		switch k {
		case CronJob, CronJobList:
			return &v121
		}
	case CoordinationV1B1:
		switch k {
		case Lease, LeaseList:
			return &v112
		}
	case CoordinationV1:
		switch k {
		case Lease, LeaseList:
			return &v114
		}
	case DiscoveryV1B1:
		switch k {
		case EndpointSlice, EndpointSliceList:
			return &v117
		}
	case DiscoveryV1:
		switch k {
		case EndpointSlice, EndpointSliceList:
			return &v121
		}
	case FlowcontrolV1A1:
		switch k {
		case FlowSchema, FlowSchemaList, PriorityLevelConfiguration, PriorityLevelConfigurationList:
			return &v117
		}
	case NetworkingV1B1:
		switch k {
		case Ingress, IngressList:
			return &v114
		case IngressClass, IngressClassList:
			return &v118
		}
	case NodeV1A1, NodeV1B1:
		switch k {
		case RuntimeClass, RuntimeClassList:
			return &v114
		}
	case PolicyV1B1:
		switch k {
		case PodSecurityPolicy, PodSecurityPolicyList:
			return &v110
		}
	case PolicyV1:
		switch k {
		case PodDisruptionBudget, PodDisruptionBudgetList:
			return &v121
		}
	case SchedulingV1B1:
		switch k {
		case PriorityClass, PriorityClassList:
			return &v111
		}
	case SchedulingV1:
		switch k {
		case PriorityClass, PriorityClassList:
			return &v114
		}
	case StorageV1A1:
		switch k {
		case CSIStorageCapacity, CSIStorageCapacityList:
			return &v121
		}
	case StorageV1B1:
		switch k {
		case VolumeAttachment, VolumeAttachmentList:
			return &v110
		case CSIDriver, CSIDriverList, CSINode, CSINodeList:
			return &v114
		case CSIStorageCapacity, CSIStorageCapacityList:
			return &v121
		}
	case StorageV1:
		switch k {
		case VolumeAttachment, VolumeAttachmentList:
			return &v113
		case CSINode, CSINodeList:
			return &v117
		case CSIDriver, CSIDriverList:
			return &v118
		}
	}
	return &v19
}