Class EnvVar.Builder
- java.lang.Object
-
- com.marcnuri.yakc.model.io.k8s.api.core.v1.EnvVar.Builder
-
- Enclosing class:
- EnvVar
public static class EnvVar.Builder extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EnvVar
build()
EnvVar.Builder
name(@NonNull java.lang.String name)
Name of the environment variable.java.lang.String
toString()
EnvVar.Builder
value(java.lang.String value)
Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables.EnvVar.Builder
valueFrom(EnvVarSource valueFrom)
-
-
-
Method Detail
-
name
public EnvVar.Builder name(@NonNull @NonNull java.lang.String name)
Name of the environment variable. Must be a C_IDENTIFIER.- Returns:
this
.
-
value
public EnvVar.Builder value(java.lang.String value)
Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. "$$(VAR_NAME)" will produce the string literal "$(VAR_NAME)". Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to "".- Returns:
this
.
-
valueFrom
public EnvVar.Builder valueFrom(EnvVarSource valueFrom)
- Returns:
this
.
-
build
public EnvVar build()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-