
io.fabric8.kubernetes.api.model.FSGroupStrategyOptionsFluentImpl Maven / Gradle / Ivy
package io.fabric8.kubernetes.api.model;
import io.fabric8.kubernetes.api.builder.BaseFluent;
import io.fabric8.kubernetes.api.builder.VisitableBuilder;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;
import javax.validation.Valid;
import java.util.ArrayList;
import java.lang.String;
import java.lang.Long;
import java.lang.Object;
import io.fabric8.kubernetes.api.builder.Nested;
public class FSGroupStrategyOptionsFluentImpl> extends BaseFluent implements FSGroupStrategyOptionsFluent{
private List> ranges = new ArrayList>();
private String type;
public FSGroupStrategyOptionsFluentImpl(){
}
public FSGroupStrategyOptionsFluentImpl(FSGroupStrategyOptions instance){
this.withRanges(instance.getRanges());
this.withType(instance.getType());
}
public A addToRanges(IDRange... items){
for (IDRange item : items) {IDRangeBuilder builder = new IDRangeBuilder(item);_visitables.add(builder);this.ranges.add(builder);} return (A)this;
}
public A removeFromRanges(IDRange... items){
for (IDRange item : items) {IDRangeBuilder builder = new IDRangeBuilder(item);_visitables.remove(builder);this.ranges.remove(builder);} return (A)this;
}
public List getRanges(){
return build(ranges);
}
public A withRanges(List ranges){
this.ranges.clear();
if (ranges != null) {for (IDRange item : ranges){this.addToRanges(item);}} return (A) this;
}
public A withRanges(IDRange... ranges){
this.ranges.clear(); if (ranges != null) {for (IDRange item :ranges){ this.addToRanges(item);}} return (A) this;
}
public FSGroupStrategyOptionsFluent.RangesNested addNewRange(){
return new RangesNestedImpl();
}
public FSGroupStrategyOptionsFluent.RangesNested addNewRangeLike(IDRange item){
return new RangesNestedImpl(item);
}
public A addNewRange(Long max,Long min){
return (A)addToRanges(new IDRange(max, min));
}
public String getType(){
return this.type;
}
public A withType(String type){
this.type=type; return (A) this;
}
public boolean equals(Object o){
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
if (!super.equals(o)) return false;
FSGroupStrategyOptionsFluentImpl that = (FSGroupStrategyOptionsFluentImpl) o;
if (ranges != null ? !ranges.equals(that.ranges) :that.ranges != null) return false;
if (type != null ? !type.equals(that.type) :that.type != null) return false;
return true;
}
public class RangesNestedImpl extends IDRangeFluentImpl> implements FSGroupStrategyOptionsFluent.RangesNested,Nested{
private final IDRangeBuilder builder;
RangesNestedImpl(){
this.builder = new IDRangeBuilder(this);
}
RangesNestedImpl(IDRange item){
this.builder = new IDRangeBuilder(this, item);
}
public N endRange(){
return and();
}
public N and(){
return (N) FSGroupStrategyOptionsFluentImpl.this.addToRanges(builder.build());
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy