com.pulumi.kubernetes.networking.v1beta1.outputs.IngressBackendPatch Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of kubernetes Show documentation
Show all versions of kubernetes Show documentation
A Pulumi package for creating and managing Kubernetes resources.
// *** 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.networking.v1beta1.outputs;
import com.pulumi.core.Either;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.kubernetes.core.v1.outputs.TypedLocalObjectReferencePatch;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class IngressBackendPatch {
/**
* @return Resource is an ObjectRef to another Kubernetes resource in the namespace of the Ingress object. If resource is specified, serviceName and servicePort must not be specified.
*
*/
private @Nullable TypedLocalObjectReferencePatch resource;
/**
* @return Specifies the name of the referenced service.
*
*/
private @Nullable String serviceName;
/**
* @return Specifies the port of the referenced service.
*
*/
private @Nullable Either servicePort;
private IngressBackendPatch() {}
/**
* @return Resource is an ObjectRef to another Kubernetes resource in the namespace of the Ingress object. If resource is specified, serviceName and servicePort must not be specified.
*
*/
public Optional resource() {
return Optional.ofNullable(this.resource);
}
/**
* @return Specifies the name of the referenced service.
*
*/
public Optional serviceName() {
return Optional.ofNullable(this.serviceName);
}
/**
* @return Specifies the port of the referenced service.
*
*/
public Optional> servicePort() {
return Optional.ofNullable(this.servicePort);
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(IngressBackendPatch defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable TypedLocalObjectReferencePatch resource;
private @Nullable String serviceName;
private @Nullable Either servicePort;
public Builder() {}
public Builder(IngressBackendPatch defaults) {
Objects.requireNonNull(defaults);
this.resource = defaults.resource;
this.serviceName = defaults.serviceName;
this.servicePort = defaults.servicePort;
}
@CustomType.Setter
public Builder resource(@Nullable TypedLocalObjectReferencePatch resource) {
this.resource = resource;
return this;
}
@CustomType.Setter
public Builder serviceName(@Nullable String serviceName) {
this.serviceName = serviceName;
return this;
}
@CustomType.Setter
public Builder servicePort(@Nullable Either servicePort) {
this.servicePort = servicePort;
return this;
}
public IngressBackendPatch build() {
final var _resultValue = new IngressBackendPatch();
_resultValue.resource = resource;
_resultValue.serviceName = serviceName;
_resultValue.servicePort = servicePort;
return _resultValue;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy