// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.kubernetes.extensions.v1beta1.outputs;

import com.pulumi.core.annotations.CustomType;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class RuntimeClassStrategyOptions {
    /**
     * @return allowedRuntimeClassNames is a whitelist of RuntimeClass names that may be specified on a pod. A value of &#34;*&#34; means that any RuntimeClass name is allowed, and must be the only item in the list. An empty list requires the RuntimeClassName field to be unset.
     * 
     */
    private List<String> allowedRuntimeClassNames;
    /**
     * @return defaultRuntimeClassName is the default RuntimeClassName to set on the pod. The default MUST be allowed by the allowedRuntimeClassNames list. A value of nil does not mutate the Pod.
     * 
     */
    private @Nullable String defaultRuntimeClassName;

    private RuntimeClassStrategyOptions() {}
    /**
     * @return allowedRuntimeClassNames is a whitelist of RuntimeClass names that may be specified on a pod. A value of &#34;*&#34; means that any RuntimeClass name is allowed, and must be the only item in the list. An empty list requires the RuntimeClassName field to be unset.
     * 
     */
    public List<String> allowedRuntimeClassNames() {
        return this.allowedRuntimeClassNames;
    }
    /**
     * @return defaultRuntimeClassName is the default RuntimeClassName to set on the pod. The default MUST be allowed by the allowedRuntimeClassNames list. A value of nil does not mutate the Pod.
     * 
     */
    public Optional<String> defaultRuntimeClassName() {
        return Optional.ofNullable(this.defaultRuntimeClassName);
    }

    public static Builder builder() {
        return new Builder();
    }

    public static Builder builder(RuntimeClassStrategyOptions defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private List<String> allowedRuntimeClassNames;
        private @Nullable String defaultRuntimeClassName;
        public Builder() {}
        public Builder(RuntimeClassStrategyOptions defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.allowedRuntimeClassNames = defaults.allowedRuntimeClassNames;
    	      this.defaultRuntimeClassName = defaults.defaultRuntimeClassName;
        }

        @CustomType.Setter
        public Builder allowedRuntimeClassNames(List<String> allowedRuntimeClassNames) {
            this.allowedRuntimeClassNames = Objects.requireNonNull(allowedRuntimeClassNames);
            return this;
        }
        public Builder allowedRuntimeClassNames(String... allowedRuntimeClassNames) {
            return allowedRuntimeClassNames(List.of(allowedRuntimeClassNames));
        }
        @CustomType.Setter
        public Builder defaultRuntimeClassName(@Nullable String defaultRuntimeClassName) {
            this.defaultRuntimeClassName = defaultRuntimeClassName;
            return this;
        }
        public RuntimeClassStrategyOptions build() {
            final var o = new RuntimeClassStrategyOptions();
            o.allowedRuntimeClassNames = allowedRuntimeClassNames;
            o.defaultRuntimeClassName = defaultRuntimeClassName;
            return o;
        }
    }
}
