io.fabric8.kubernetes.api.model.base.LifecycleFluent Maven / Gradle / Ivy
package io.fabric8.kubernetes.api.model.base;
import java.util.HashMap;
import java.util.Map;
import io.fabric8.common.Fluent;
import io.fabric8.common.Nested;
public class LifecycleFluent> implements Fluent{
private Handler postStart ;
private Handler preStop ;
private Map additionalProperties = new HashMap();
public Handler getPostStart(){
return this.postStart;
}
public T withPostStart(Handler postStart){
this.postStart=postStart; return (T) this;
}
public Handler getPreStop(){
return this.preStop;
}
public T withPreStop(Handler preStop){
this.preStop=preStop; 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 PostStartNested withNewPostStart(){
return new PostStartNested();
}
public PreStopNested withNewPreStop(){
return new PreStopNested();
}
public T addToAdditionalProperties(String key, Object value){
if(key != null && value != null) {this.additionalProperties.put(key, value);} return (T)this;
}
public class PostStartNested extends HandlerFluent> implements Nested{
private final HandlerBuilder builder = new HandlerBuilder(this);
public N endPostStart(){
return and();
}
public N and(){
return (N) LifecycleFluent.this.withPostStart(builder.build());
}
}
public class PreStopNested extends HandlerFluent> implements Nested{
private final HandlerBuilder builder = new HandlerBuilder(this);
public N endPreStop(){
return and();
}
public N and(){
return (N) LifecycleFluent.this.withPreStop(builder.build());
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy