annotations.io.alauda.devops.api.model.DoneableBuildSpec Maven / Gradle / Ivy
package io.alauda.devops.api.model;
import io.alauda.kubernetes.api.builder.Function;
import io.alauda.kubernetes.api.model.Doneable;
public class DoneableBuildSpec extends BuildSpecFluentImpl implements Doneable{
private final BuildSpecBuilder builder;
private final io.alauda.kubernetes.api.builder.Function function;
public DoneableBuildSpec(io.alauda.kubernetes.api.builder.Function function){
super();this.builder=new BuildSpecBuilder(this);this.function=function;
}
public DoneableBuildSpec(BuildSpec item,io.alauda.kubernetes.api.builder.Function function){
super(item);this.builder=new BuildSpecBuilder(this, item);this.function=function;
}
public DoneableBuildSpec(BuildSpec item){
super(item);this.builder=new BuildSpecBuilder(this, item);this.function=new Function() {
public BuildSpec apply(BuildSpec item) {
return item;
}
}
;
}
public BuildSpec done(){
return function.apply(builder.build());
}
}