io.fabric8.kubernetes.api.model.EphemeralContainerBuilder Maven / Gradle / Ivy
package io.fabric8.kubernetes.api.model;
import io.fabric8.kubernetes.api.builder.VisitableBuilder;
import java.lang.Object;
import java.lang.Boolean;
public class EphemeralContainerBuilder extends EphemeralContainerFluentImpl implements VisitableBuilder{
EphemeralContainerFluent> fluent;
Boolean validationEnabled;
public EphemeralContainerBuilder(){
this(true);
}
public EphemeralContainerBuilder(Boolean validationEnabled){
this(new EphemeralContainer(), validationEnabled);
}
public EphemeralContainerBuilder(EphemeralContainerFluent> fluent){
this(fluent, true);
}
public EphemeralContainerBuilder(EphemeralContainerFluent> fluent,Boolean validationEnabled){
this(fluent, new EphemeralContainer(), validationEnabled);
}
public EphemeralContainerBuilder(EphemeralContainerFluent> fluent,EphemeralContainer instance){
this(fluent, instance, true);
}
public EphemeralContainerBuilder(EphemeralContainerFluent> fluent,EphemeralContainer instance,Boolean validationEnabled){
this.fluent = fluent;
fluent.withArgs(instance.getArgs());
fluent.withCommand(instance.getCommand());
fluent.withEnv(instance.getEnv());
fluent.withEnvFrom(instance.getEnvFrom());
fluent.withImage(instance.getImage());
fluent.withImagePullPolicy(instance.getImagePullPolicy());
fluent.withLifecycle(instance.getLifecycle());
fluent.withLivenessProbe(instance.getLivenessProbe());
fluent.withName(instance.getName());
fluent.withPorts(instance.getPorts());
fluent.withReadinessProbe(instance.getReadinessProbe());
fluent.withResources(instance.getResources());
fluent.withSecurityContext(instance.getSecurityContext());
fluent.withStartupProbe(instance.getStartupProbe());
fluent.withStdin(instance.getStdin());
fluent.withStdinOnce(instance.getStdinOnce());
fluent.withTargetContainerName(instance.getTargetContainerName());
fluent.withTerminationMessagePath(instance.getTerminationMessagePath());
fluent.withTerminationMessagePolicy(instance.getTerminationMessagePolicy());
fluent.withTty(instance.getTty());
fluent.withVolumeDevices(instance.getVolumeDevices());
fluent.withVolumeMounts(instance.getVolumeMounts());
fluent.withWorkingDir(instance.getWorkingDir());
this.validationEnabled = validationEnabled;
}
public EphemeralContainerBuilder(EphemeralContainer instance){
this(instance,true);
}
public EphemeralContainerBuilder(EphemeralContainer instance,Boolean validationEnabled){
this.fluent = this;
this.withArgs(instance.getArgs());
this.withCommand(instance.getCommand());
this.withEnv(instance.getEnv());
this.withEnvFrom(instance.getEnvFrom());
this.withImage(instance.getImage());
this.withImagePullPolicy(instance.getImagePullPolicy());
this.withLifecycle(instance.getLifecycle());
this.withLivenessProbe(instance.getLivenessProbe());
this.withName(instance.getName());
this.withPorts(instance.getPorts());
this.withReadinessProbe(instance.getReadinessProbe());
this.withResources(instance.getResources());
this.withSecurityContext(instance.getSecurityContext());
this.withStartupProbe(instance.getStartupProbe());
this.withStdin(instance.getStdin());
this.withStdinOnce(instance.getStdinOnce());
this.withTargetContainerName(instance.getTargetContainerName());
this.withTerminationMessagePath(instance.getTerminationMessagePath());
this.withTerminationMessagePolicy(instance.getTerminationMessagePolicy());
this.withTty(instance.getTty());
this.withVolumeDevices(instance.getVolumeDevices());
this.withVolumeMounts(instance.getVolumeMounts());
this.withWorkingDir(instance.getWorkingDir());
this.validationEnabled = validationEnabled;
}
public EphemeralContainer build(){
EphemeralContainer buildable = new EphemeralContainer(fluent.getArgs(),fluent.getCommand(),fluent.getEnv(),fluent.getEnvFrom(),fluent.getImage(),fluent.getImagePullPolicy(),fluent.getLifecycle(),fluent.getLivenessProbe(),fluent.getName(),fluent.getPorts(),fluent.getReadinessProbe(),fluent.getResources(),fluent.getSecurityContext(),fluent.getStartupProbe(),fluent.isStdin(),fluent.isStdinOnce(),fluent.getTargetContainerName(),fluent.getTerminationMessagePath(),fluent.getTerminationMessagePolicy(),fluent.isTty(),fluent.getVolumeDevices(),fluent.getVolumeMounts(),fluent.getWorkingDir());
return buildable;
}
public boolean equals(Object o){
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
if (!super.equals(o)) return false;
EphemeralContainerBuilder that = (EphemeralContainerBuilder) o;
if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false;
if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false;
return true;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy