annotations.me.snowdrop.istio.api.model.v1.routing.L4FaultInjectionFluentImpl Maven / Gradle / Ivy
package me.snowdrop.istio.api.model.v1.routing;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.fabric8.kubernetes.api.builder.Nested;
import java.lang.Deprecated;
import javax.validation.Valid;
import io.fabric8.kubernetes.api.builder.BaseFluent;
import java.lang.Object;
import java.lang.Boolean;
public class L4FaultInjectionFluentImpl> extends io.fabric8.kubernetes.api.builder.BaseFluent implements L4FaultInjectionFluent{
private TerminateBuilder terminate;
private ThrottleBuilder throttle;
public L4FaultInjectionFluentImpl(){
}
public L4FaultInjectionFluentImpl(L4FaultInjection instance){
this.withTerminate(instance.getTerminate());
this.withThrottle(instance.getThrottle());
}
/**
* This method has been deprecated, please use method buildTerminate instead.
*/
@Deprecated public Terminate getTerminate(){
return this.terminate!=null?this.terminate.build():null;
}
public Terminate buildTerminate(){
return this.terminate!=null?this.terminate.build():null;
}
public A withTerminate(Terminate terminate){
_visitables.remove(this.terminate);
if (terminate!=null){ this.terminate= new TerminateBuilder(terminate); _visitables.add(this.terminate);} return (A) this;
}
public Boolean hasTerminate(){
return this.terminate != null;
}
public L4FaultInjectionFluent.TerminateNested withNewTerminate(){
return new TerminateNestedImpl();
}
public L4FaultInjectionFluent.TerminateNested withNewTerminateLike(Terminate item){
return new TerminateNestedImpl(item);
}
public L4FaultInjectionFluent.TerminateNested editTerminate(){
return withNewTerminateLike(getTerminate());
}
public L4FaultInjectionFluent.TerminateNested editOrNewTerminate(){
return withNewTerminateLike(getTerminate() != null ? getTerminate(): new TerminateBuilder().build());
}
public L4FaultInjectionFluent.TerminateNested editOrNewTerminateLike(Terminate item){
return withNewTerminateLike(getTerminate() != null ? getTerminate(): item);
}
/**
* This method has been deprecated, please use method buildThrottle instead.
*/
@Deprecated public Throttle getThrottle(){
return this.throttle!=null?this.throttle.build():null;
}
public Throttle buildThrottle(){
return this.throttle!=null?this.throttle.build():null;
}
public A withThrottle(Throttle throttle){
_visitables.remove(this.throttle);
if (throttle!=null){ this.throttle= new ThrottleBuilder(throttle); _visitables.add(this.throttle);} return (A) this;
}
public Boolean hasThrottle(){
return this.throttle != null;
}
public L4FaultInjectionFluent.ThrottleNested withNewThrottle(){
return new ThrottleNestedImpl();
}
public L4FaultInjectionFluent.ThrottleNested withNewThrottleLike(Throttle item){
return new ThrottleNestedImpl(item);
}
public L4FaultInjectionFluent.ThrottleNested editThrottle(){
return withNewThrottleLike(getThrottle());
}
public L4FaultInjectionFluent.ThrottleNested editOrNewThrottle(){
return withNewThrottleLike(getThrottle() != null ? getThrottle(): new ThrottleBuilder().build());
}
public L4FaultInjectionFluent.ThrottleNested editOrNewThrottleLike(Throttle item){
return withNewThrottleLike(getThrottle() != null ? getThrottle(): item);
}
public boolean equals(Object o){
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
if (!super.equals(o)) return false;
L4FaultInjectionFluentImpl that = (L4FaultInjectionFluentImpl) o;
if (terminate != null ? !terminate.equals(that.terminate) :that.terminate != null) return false;
if (throttle != null ? !throttle.equals(that.throttle) :that.throttle != null) return false;
return true;
}
public class TerminateNestedImpl extends TerminateFluentImpl> implements L4FaultInjectionFluent.TerminateNested,io.fabric8.kubernetes.api.builder.Nested{
private final TerminateBuilder builder;
TerminateNestedImpl(Terminate item){
this.builder = new TerminateBuilder(this, item);
}
TerminateNestedImpl(){
this.builder = new TerminateBuilder(this);
}
public N and(){
return (N) L4FaultInjectionFluentImpl.this.withTerminate(builder.build());
}
public N endTerminate(){
return and();
}
}
public class ThrottleNestedImpl extends ThrottleFluentImpl> implements L4FaultInjectionFluent.ThrottleNested,io.fabric8.kubernetes.api.builder.Nested{
private final ThrottleBuilder builder;
ThrottleNestedImpl(Throttle item){
this.builder = new ThrottleBuilder(this, item);
}
ThrottleNestedImpl(){
this.builder = new ThrottleBuilder(this);
}
public N and(){
return (N) L4FaultInjectionFluentImpl.this.withThrottle(builder.build());
}
public N endThrottle(){
return and();
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy