All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.fabric8.openshift.api.model.BuildOutputFluentImpl Maven / Gradle / Ivy

There is a newer version: 6.13.4
Show newest version
package io.fabric8.openshift.api.model;

import java.util.HashMap;
import java.io.Serializable;
import java.util.Map;
import java.util.Map;
import io.fabric8.kubernetes.api.model.LocalObjectReference;
import java.util.AbstractMap;
import io.fabric8.kubernetes.api.model.ObjectReference;
import io.fabric8.kubernetes.api.builder.Visitable;
import io.fabric8.kubernetes.api.builder.Builder;
import io.fabric8.kubernetes.api.model.LocalObjectReferenceFluentImpl;
import io.fabric8.kubernetes.api.model.LocalObjectReferenceFluent;
import io.fabric8.kubernetes.api.builder.Visitable;
import io.fabric8.kubernetes.api.builder.VisitableBuilder;
import io.fabric8.kubernetes.api.builder.BaseFluent;
import io.fabric8.kubernetes.api.builder.VisitableBuilder;
import io.fabric8.kubernetes.api.model.LocalObjectReferenceBuilder;
import io.fabric8.kubernetes.api.model.ObjectReferenceFluentImpl;
import io.fabric8.kubernetes.api.builder.Fluent;
import io.fabric8.kubernetes.api.builder.Nested;
import io.fabric8.kubernetes.api.model.ObjectReferenceFluent;
import io.fabric8.kubernetes.api.model.ObjectReferenceBuilder;

public class BuildOutputFluentImpl> extends BaseFluent implements BuildOutputFluent{

     VisitableBuilder pushSecret;     VisitableBuilder to;     Map additionalProperties = new HashMap();
public BuildOutputFluentImpl(){
    
}
public BuildOutputFluentImpl( BuildOutput instance ){
    this.withPushSecret(instance.getPushSecret()); this.withTo(instance.getTo()); 
}

    public LocalObjectReference getPushSecret(){
    return this.pushSecret!=null?this.pushSecret.build():null;
    }
    public T withPushSecret( LocalObjectReference pushSecret){
    if (pushSecret!=null){ this.pushSecret= new LocalObjectReferenceBuilder(pushSecret); _visitables.add(this.pushSecret);} return (T) this;
    }
    public PushSecretNested withNewPushSecret(){
    return new PushSecretNestedImpl();
    }
    public PushSecretNested withNewPushSecretLike( LocalObjectReference item){
    return new PushSecretNestedImpl(item);
    }
    public PushSecretNested editPushSecret(){
    return withNewPushSecretLike(getPushSecret());
    }
    public T withNewPushSecret( String name){
    return withPushSecret(new LocalObjectReference(name));
    }
    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 ToNestedImpl();
    }
    public ToNested withNewToLike( ObjectReference item){
    return new ToNestedImpl(item);
    }
    public ToNested editTo(){
    return withNewToLike(getTo());
    }
    public T addToAdditionalProperties( String key,  Object value){
    if(key != null && value != null) {this.additionalProperties.put(key, value);} return (T)this;
    }
    public T addToAdditionalProperties( Map map){
    if(map != null) { this.additionalProperties.putAll(map);} return (T)this;
    }
    public T removeFromAdditionalProperties( String key){
    if(key != null) {this.additionalProperties.remove(key);} return (T)this;
    }
    public T removeFromAdditionalProperties( Map map){
    if(map != null) { for(Object key : map.keySet()) {this.additionalProperties.remove(key);}} 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 boolean equals( Object o){
    
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
BuildOutputFluentImpl that = (BuildOutputFluentImpl) o;
if (pushSecret != null ? !pushSecret.equals(that.pushSecret) :that.pushSecret != null) return false;
if (to != null ? !to.equals(that.to) :that.to != null) return false;
if (additionalProperties != null ? !additionalProperties.equals(that.additionalProperties) :that.additionalProperties != null) return false;
return true;

    }

    public class PushSecretNestedImpl extends LocalObjectReferenceFluentImpl> implements PushSecretNested{

        private final LocalObjectReferenceBuilder builder;
    
             PushSecretNestedImpl (){
        this.builder = new LocalObjectReferenceBuilder(this);
        }
             PushSecretNestedImpl ( LocalObjectReference item){
        this.builder = new LocalObjectReferenceBuilder(this, item);
        }
    
            public N endPushSecret(){
            return and();
        }
            public N and(){
            return (N) BuildOutputFluentImpl.this.withPushSecret(builder.build());
        }
    
}
    public class ToNestedImpl extends ObjectReferenceFluentImpl> implements ToNested{

        private final ObjectReferenceBuilder builder;
    
             ToNestedImpl (){
        this.builder = new ObjectReferenceBuilder(this);
        }
             ToNestedImpl ( ObjectReference item){
        this.builder = new ObjectReferenceBuilder(this, item);
        }
    
            public N and(){
            return (N) BuildOutputFluentImpl.this.withTo(builder.build());
        }
            public N endTo(){
            return and();
        }
    
}


}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy