io.fabric8.openshift.api.model.RouteSpecFluent Maven / Gradle / Ivy
package io.fabric8.openshift.api.model;
import io.fabric8.kubernetes.api.model.ObjectReference;
import java.util.HashMap;
import java.util.Map;
import io.fabric8.common.Nested;
import io.fabric8.common.Builder;
import io.fabric8.kubernetes.api.model.ObjectReferenceFluent;
import io.fabric8.common.Fluent;
import io.fabric8.common.BaseFluent;
import io.fabric8.common.Visitable;
import io.fabric8.kubernetes.api.model.ObjectReferenceBuilder;
public class RouteSpecFluent> extends BaseFluent implements Fluent{
String host; String path; TLSConfigBuilder tls; ObjectReferenceBuilder to; Map additionalProperties = new HashMap();
public String getHost(){
return this.host;
}
public T withHost( String host){
this.host=host; return (T) this;
}
public String getPath(){
return this.path;
}
public T withPath( String path){
this.path=path; return (T) this;
}
public TLSConfig getTls(){
return this.tls!=null?this.tls.build():null;
}
public T withTls( TLSConfig tls){
if (tls!=null){ this.tls= new TLSConfigBuilder(tls); _visitables.add(this.tls);} return (T) this;
}
public TlsNested withNewTls(){
return new TlsNested();
}
public T withNewTls( String caCertificate, String certificate, String destinationCACertificate, String key, String termination){
return withTls(new TLSConfig(caCertificate, certificate, destinationCACertificate, key, termination));
}
public ObjectReference getTo(){
return this.to!=null?this.to.build():null;
}
public T withTo( ObjectReference to){
if (to!=null){ this.to= new ObjectReferenceBuilder(to); _visitables.add(this.to);} return (T) this;
}
public ToNested withNewTo(){
return new ToNested();
}
public T addToAdditionalProperties( String key, Object value){
if(key != null && value != null) {this.additionalProperties.put(key, value);} return (T)this;
}
public Map getAdditionalProperties(){
return this.additionalProperties;
}
public T withAdditionalProperties( Map additionalProperties){
this.additionalProperties.clear();if (additionalProperties != null) {this.additionalProperties.putAll(additionalProperties);} return (T) this;
}
public class TlsNested extends TLSConfigFluent> implements Nested{
private final TLSConfigBuilder builder = new TLSConfigBuilder(this);
public N and(){
return (N) RouteSpecFluent.this.withTls(builder.build());
}
public N endTls(){
return and();
}
}
public class ToNested extends ObjectReferenceFluent> implements Nested{
private final ObjectReferenceBuilder builder = new ObjectReferenceBuilder(this);
public N and(){
return (N) RouteSpecFluent.this.withTo(builder.build());
}
public N endTo(){
return and();
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy