io.fabric8.openshift.api.model.RouteFluent Maven / Gradle / Ivy
package io.fabric8.openshift.api.model;
import io.fabric8.kubernetes.api.model.ObjectMeta;
import java.util.HashMap;
import java.util.Map;
import io.fabric8.kubernetes.api.model.ObjectMetaBuilder;
import io.fabric8.common.Nested;
import io.fabric8.common.Builder;
import io.fabric8.common.Fluent;
import io.fabric8.common.Visitable;
import io.fabric8.common.BaseFluent;
import io.fabric8.kubernetes.api.model.ObjectMetaFluent;
public class RouteFluent> extends BaseFluent implements Fluent{
Route.ApiVersion apiVersion; String kind; ObjectMetaBuilder metadata; RouteSpecBuilder spec; RouteStatusBuilder status; Map additionalProperties = new HashMap();
public Route.ApiVersion getApiVersion(){
return this.apiVersion;
}
public T withApiVersion( Route.ApiVersion apiVersion){
this.apiVersion=apiVersion; return (T) this;
}
public String getKind(){
return this.kind;
}
public T withKind( String kind){
this.kind=kind; return (T) this;
}
public ObjectMeta getMetadata(){
return this.metadata!=null?this.metadata.build():null;
}
public T withMetadata( ObjectMeta metadata){
if (metadata!=null){ this.metadata= new ObjectMetaBuilder(metadata); _visitables.add(this.metadata);} return (T) this;
}
public MetadataNested withNewMetadata(){
return new MetadataNested();
}
public RouteSpec getSpec(){
return this.spec!=null?this.spec.build():null;
}
public T withSpec( RouteSpec spec){
if (spec!=null){ this.spec= new RouteSpecBuilder(spec); _visitables.add(this.spec);} return (T) this;
}
public SpecNested withNewSpec(){
return new SpecNested();
}
public RouteStatus getStatus(){
return this.status!=null?this.status.build():null;
}
public T withStatus( RouteStatus status){
if (status!=null){ this.status= new RouteStatusBuilder(status); _visitables.add(this.status);} return (T) this;
}
public StatusNested withNewStatus(){
return new StatusNested();
}
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 MetadataNested extends ObjectMetaFluent> implements Nested{
private final ObjectMetaBuilder builder = new ObjectMetaBuilder(this);
public N and(){
return (N) RouteFluent.this.withMetadata(builder.build());
}
public N endMetadata(){
return and();
}
}
public class SpecNested extends RouteSpecFluent> implements Nested{
private final RouteSpecBuilder builder = new RouteSpecBuilder(this);
public N endSpec(){
return and();
}
public N and(){
return (N) RouteFluent.this.withSpec(builder.build());
}
}
public class StatusNested extends RouteStatusFluent> implements Nested{
private final RouteStatusBuilder builder = new RouteStatusBuilder(this);
public N endStatus(){
return and();
}
public N and(){
return (N) RouteFluent.this.withStatus(builder.build());
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy