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

io.fabric8.docker.client.ProgressEventBuilder Maven / Gradle / Ivy

There is a newer version: 1.3.1
Show newest version
package io.fabric8.docker.client;

import java.io.Serializable;
import io.sundr.builder.Builder;
import io.sundr.builder.Visitable;
import io.sundr.builder.VisitableBuilder;
import io.sundr.builder.Visitable;
import io.sundr.builder.Fluent;
import io.sundr.builder.BaseFluent;

public class ProgressEventBuilder extends ProgressEventFluentImpl implements VisitableBuilder{

     ProgressEventFluent fluent;

    public ProgressEventBuilder(){
        this(new ProgressEvent());
    }
    public ProgressEventBuilder( ProgressEventFluent fluent ){
        this(fluent, new ProgressEvent());
    }
    public ProgressEventBuilder( ProgressEventFluent fluent , ProgressEvent instance ){
        this.fluent = fluent; fluent.withStream(instance.getStream()); fluent.withErrorDetail(instance.getErrorDetail()); fluent.withError(instance.getError()); 
    }
    public ProgressEventBuilder( ProgressEvent instance ){
        this.fluent = this; this.withStream(instance.getStream()); this.withErrorDetail(instance.getErrorDetail()); this.withError(instance.getError()); 
    }

public EditableProgressEvent build(){
    EditableProgressEvent buildable = new EditableProgressEvent(fluent.getStream(),fluent.getErrorDetail(),fluent.getError());
validate(buildable);
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;
ProgressEventBuilder that = (ProgressEventBuilder) o;
if (fluent != null &&fluent != this ? !fluent.equals(that.fluent) :that.fluent != null &&fluent != this ) return false;
return true;

}

private  void validate(T item) {}


}
    




© 2015 - 2024 Weber Informatics LLC | Privacy Policy