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

io.fabric8.knative.duck.v1beta1.DestinationBuilder Maven / Gradle / Ivy

package io.fabric8.knative.duck.v1beta1;

import io.fabric8.kubernetes.api.builder.VisitableBuilder;
import java.lang.Object;
import java.lang.Boolean;

public class DestinationBuilder extends io.fabric8.knative.duck.v1beta1.DestinationFluentImpl implements VisitableBuilder{

    io.fabric8.knative.duck.v1beta1.DestinationFluent fluent;
    Boolean validationEnabled;

    public DestinationBuilder(){
            this(true);
    }
    public DestinationBuilder(Boolean validationEnabled){
            this(new Destination(), validationEnabled);
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.DestinationFluent fluent){
            this(fluent, true);
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.DestinationFluent fluent,Boolean validationEnabled){
            this(fluent, new Destination(), validationEnabled);
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.DestinationFluent fluent,io.fabric8.knative.duck.v1beta1.Destination instance){
            this(fluent, instance, true);
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.DestinationFluent fluent,io.fabric8.knative.duck.v1beta1.Destination instance,Boolean validationEnabled){
            this.fluent = fluent; 
            fluent.withApiVersion(instance.getApiVersion()); 
            fluent.withKind(instance.getKind()); 
            fluent.withName(instance.getName()); 
            fluent.withNamespace(instance.getNamespace()); 
            fluent.withRef(instance.getRef()); 
            fluent.withUri(instance.getUri()); 
            this.validationEnabled = validationEnabled; 
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.Destination instance){
            this(instance,true);
    }
    public DestinationBuilder(io.fabric8.knative.duck.v1beta1.Destination instance,Boolean validationEnabled){
            this.fluent = this; 
            this.withApiVersion(instance.getApiVersion()); 
            this.withKind(instance.getKind()); 
            this.withName(instance.getName()); 
            this.withNamespace(instance.getNamespace()); 
            this.withRef(instance.getRef()); 
            this.withUri(instance.getUri()); 
            this.validationEnabled = validationEnabled; 
    }

    public io.fabric8.knative.duck.v1beta1.Destination build(){
            Destination buildable = new Destination(fluent.getApiVersion(),fluent.getKind(),fluent.getName(),fluent.getNamespace(),fluent.getRef(),fluent.getUri());
            return buildable;
    }

    public boolean equals(Object o){
            if (this == o) return true;
            if (o == null || getClass() != o.getClass()) return false;
            if (!super.equals(o)) return false;
            DestinationBuilder that = (DestinationBuilder) o;
            if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false;

            if (validationEnabled != null ? !validationEnabled.equals(that.validationEnabled) :that.validationEnabled != null) return false;
            return true;
    }




}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy