io.fabric8.kubernetes.api.model.EventFluentImpl Maven / Gradle / Ivy
package io.fabric8.kubernetes.api.model;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.lang.StringBuilder;
import io.fabric8.kubernetes.api.builder.Nested;
import java.lang.String;
import java.lang.Deprecated;
import io.fabric8.kubernetes.api.builder.BaseFluent;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.StringBuffer;
import java.lang.Object;
public class EventFluentImpl> extends io.fabric8.kubernetes.api.builder.BaseFluent implements EventFluent{
private String action;
private String apiVersion;
private Integer count;
private MicroTimeBuilder eventTime;
private String firstTimestamp;
private ObjectReferenceBuilder involvedObject;
private String kind;
private String lastTimestamp;
private String message;
private ObjectMetaBuilder metadata;
private String reason;
private ObjectReferenceBuilder related;
private String reportingComponent;
private String reportingInstance;
private EventSeriesBuilder series;
private EventSourceBuilder source;
private String type;
public EventFluentImpl(){
}
public EventFluentImpl(Event instance){
this.withAction(instance.getAction());
this.withApiVersion(instance.getApiVersion());
this.withCount(instance.getCount());
this.withEventTime(instance.getEventTime());
this.withFirstTimestamp(instance.getFirstTimestamp());
this.withInvolvedObject(instance.getInvolvedObject());
this.withKind(instance.getKind());
this.withLastTimestamp(instance.getLastTimestamp());
this.withMessage(instance.getMessage());
this.withMetadata(instance.getMetadata());
this.withReason(instance.getReason());
this.withRelated(instance.getRelated());
this.withReportingComponent(instance.getReportingComponent());
this.withReportingInstance(instance.getReportingInstance());
this.withSeries(instance.getSeries());
this.withSource(instance.getSource());
this.withType(instance.getType());
}
public String getAction(){
return this.action;
}
public A withAction(String action){
this.action=action; return (A) this;
}
public Boolean hasAction(){
return this.action != null;
}
public A withNewAction(String arg1){
return (A)withAction(new String(arg1));
}
public A withNewAction(StringBuilder arg1){
return (A)withAction(new String(arg1));
}
public A withNewAction(StringBuffer arg1){
return (A)withAction(new String(arg1));
}
public String getApiVersion(){
return this.apiVersion;
}
public A withApiVersion(String apiVersion){
this.apiVersion=apiVersion; return (A) this;
}
public Boolean hasApiVersion(){
return this.apiVersion != null;
}
public A withNewApiVersion(String arg1){
return (A)withApiVersion(new String(arg1));
}
public A withNewApiVersion(StringBuilder arg1){
return (A)withApiVersion(new String(arg1));
}
public A withNewApiVersion(StringBuffer arg1){
return (A)withApiVersion(new String(arg1));
}
public Integer getCount(){
return this.count;
}
public A withCount(Integer count){
this.count=count; return (A) this;
}
public Boolean hasCount(){
return this.count != null;
}
/**
* This method has been deprecated, please use method buildEventTime instead.
* @return The buildable object.
*/
@Deprecated public MicroTime getEventTime(){
return this.eventTime!=null?this.eventTime.build():null;
}
public MicroTime buildEventTime(){
return this.eventTime!=null?this.eventTime.build():null;
}
public A withEventTime(MicroTime eventTime){
_visitables.get("eventTime").remove(this.eventTime);
if (eventTime!=null){ this.eventTime= new MicroTimeBuilder(eventTime); _visitables.get("eventTime").add(this.eventTime);} return (A) this;
}
public Boolean hasEventTime(){
return this.eventTime != null;
}
public A withNewEventTime(String time){
return (A)withEventTime(new MicroTime(time));
}
public EventFluent.EventTimeNested withNewEventTime(){
return new EventTimeNestedImpl();
}
public EventFluent.EventTimeNested withNewEventTimeLike(MicroTime item){
return new EventTimeNestedImpl(item);
}
public EventFluent.EventTimeNested editEventTime(){
return withNewEventTimeLike(getEventTime());
}
public EventFluent.EventTimeNested editOrNewEventTime(){
return withNewEventTimeLike(getEventTime() != null ? getEventTime(): new MicroTimeBuilder().build());
}
public EventFluent.EventTimeNested editOrNewEventTimeLike(MicroTime item){
return withNewEventTimeLike(getEventTime() != null ? getEventTime(): item);
}
public String getFirstTimestamp(){
return this.firstTimestamp;
}
public A withFirstTimestamp(String firstTimestamp){
this.firstTimestamp=firstTimestamp; return (A) this;
}
public Boolean hasFirstTimestamp(){
return this.firstTimestamp != null;
}
public A withNewFirstTimestamp(String arg1){
return (A)withFirstTimestamp(new String(arg1));
}
public A withNewFirstTimestamp(StringBuilder arg1){
return (A)withFirstTimestamp(new String(arg1));
}
public A withNewFirstTimestamp(StringBuffer arg1){
return (A)withFirstTimestamp(new String(arg1));
}
/**
* This method has been deprecated, please use method buildInvolvedObject instead.
* @return The buildable object.
*/
@Deprecated public ObjectReference getInvolvedObject(){
return this.involvedObject!=null?this.involvedObject.build():null;
}
public ObjectReference buildInvolvedObject(){
return this.involvedObject!=null?this.involvedObject.build():null;
}
public A withInvolvedObject(ObjectReference involvedObject){
_visitables.get("involvedObject").remove(this.involvedObject);
if (involvedObject!=null){ this.involvedObject= new ObjectReferenceBuilder(involvedObject); _visitables.get("involvedObject").add(this.involvedObject);} return (A) this;
}
public Boolean hasInvolvedObject(){
return this.involvedObject != null;
}
public EventFluent.InvolvedObjectNested withNewInvolvedObject(){
return new InvolvedObjectNestedImpl();
}
public EventFluent.InvolvedObjectNested withNewInvolvedObjectLike(ObjectReference item){
return new InvolvedObjectNestedImpl(item);
}
public EventFluent.InvolvedObjectNested editInvolvedObject(){
return withNewInvolvedObjectLike(getInvolvedObject());
}
public EventFluent.InvolvedObjectNested editOrNewInvolvedObject(){
return withNewInvolvedObjectLike(getInvolvedObject() != null ? getInvolvedObject(): new ObjectReferenceBuilder().build());
}
public EventFluent.InvolvedObjectNested editOrNewInvolvedObjectLike(ObjectReference item){
return withNewInvolvedObjectLike(getInvolvedObject() != null ? getInvolvedObject(): item);
}
public String getKind(){
return this.kind;
}
public A withKind(String kind){
this.kind=kind; return (A) this;
}
public Boolean hasKind(){
return this.kind != null;
}
public A withNewKind(String arg1){
return (A)withKind(new String(arg1));
}
public A withNewKind(StringBuilder arg1){
return (A)withKind(new String(arg1));
}
public A withNewKind(StringBuffer arg1){
return (A)withKind(new String(arg1));
}
public String getLastTimestamp(){
return this.lastTimestamp;
}
public A withLastTimestamp(String lastTimestamp){
this.lastTimestamp=lastTimestamp; return (A) this;
}
public Boolean hasLastTimestamp(){
return this.lastTimestamp != null;
}
public A withNewLastTimestamp(String arg1){
return (A)withLastTimestamp(new String(arg1));
}
public A withNewLastTimestamp(StringBuilder arg1){
return (A)withLastTimestamp(new String(arg1));
}
public A withNewLastTimestamp(StringBuffer arg1){
return (A)withLastTimestamp(new String(arg1));
}
public String getMessage(){
return this.message;
}
public A withMessage(String message){
this.message=message; return (A) this;
}
public Boolean hasMessage(){
return this.message != null;
}
public A withNewMessage(String arg1){
return (A)withMessage(new String(arg1));
}
public A withNewMessage(StringBuilder arg1){
return (A)withMessage(new String(arg1));
}
public A withNewMessage(StringBuffer arg1){
return (A)withMessage(new String(arg1));
}
/**
* This method has been deprecated, please use method buildMetadata instead.
* @return The buildable object.
*/
@Deprecated public ObjectMeta getMetadata(){
return this.metadata!=null?this.metadata.build():null;
}
public ObjectMeta buildMetadata(){
return this.metadata!=null?this.metadata.build():null;
}
public A withMetadata(ObjectMeta metadata){
_visitables.get("metadata").remove(this.metadata);
if (metadata!=null){ this.metadata= new ObjectMetaBuilder(metadata); _visitables.get("metadata").add(this.metadata);} return (A) this;
}
public Boolean hasMetadata(){
return this.metadata != null;
}
public EventFluent.MetadataNested withNewMetadata(){
return new MetadataNestedImpl();
}
public EventFluent.MetadataNested withNewMetadataLike(ObjectMeta item){
return new MetadataNestedImpl(item);
}
public EventFluent.MetadataNested editMetadata(){
return withNewMetadataLike(getMetadata());
}
public EventFluent.MetadataNested editOrNewMetadata(){
return withNewMetadataLike(getMetadata() != null ? getMetadata(): new ObjectMetaBuilder().build());
}
public EventFluent.MetadataNested editOrNewMetadataLike(ObjectMeta item){
return withNewMetadataLike(getMetadata() != null ? getMetadata(): item);
}
public String getReason(){
return this.reason;
}
public A withReason(String reason){
this.reason=reason; return (A) this;
}
public Boolean hasReason(){
return this.reason != null;
}
public A withNewReason(String arg1){
return (A)withReason(new String(arg1));
}
public A withNewReason(StringBuilder arg1){
return (A)withReason(new String(arg1));
}
public A withNewReason(StringBuffer arg1){
return (A)withReason(new String(arg1));
}
/**
* This method has been deprecated, please use method buildRelated instead.
* @return The buildable object.
*/
@Deprecated public ObjectReference getRelated(){
return this.related!=null?this.related.build():null;
}
public ObjectReference buildRelated(){
return this.related!=null?this.related.build():null;
}
public A withRelated(ObjectReference related){
_visitables.get("related").remove(this.related);
if (related!=null){ this.related= new ObjectReferenceBuilder(related); _visitables.get("related").add(this.related);} return (A) this;
}
public Boolean hasRelated(){
return this.related != null;
}
public EventFluent.RelatedNested withNewRelated(){
return new RelatedNestedImpl();
}
public EventFluent.RelatedNested withNewRelatedLike(ObjectReference item){
return new RelatedNestedImpl(item);
}
public EventFluent.RelatedNested editRelated(){
return withNewRelatedLike(getRelated());
}
public EventFluent.RelatedNested editOrNewRelated(){
return withNewRelatedLike(getRelated() != null ? getRelated(): new ObjectReferenceBuilder().build());
}
public EventFluent.RelatedNested editOrNewRelatedLike(ObjectReference item){
return withNewRelatedLike(getRelated() != null ? getRelated(): item);
}
public String getReportingComponent(){
return this.reportingComponent;
}
public A withReportingComponent(String reportingComponent){
this.reportingComponent=reportingComponent; return (A) this;
}
public Boolean hasReportingComponent(){
return this.reportingComponent != null;
}
public A withNewReportingComponent(String arg1){
return (A)withReportingComponent(new String(arg1));
}
public A withNewReportingComponent(StringBuilder arg1){
return (A)withReportingComponent(new String(arg1));
}
public A withNewReportingComponent(StringBuffer arg1){
return (A)withReportingComponent(new String(arg1));
}
public String getReportingInstance(){
return this.reportingInstance;
}
public A withReportingInstance(String reportingInstance){
this.reportingInstance=reportingInstance; return (A) this;
}
public Boolean hasReportingInstance(){
return this.reportingInstance != null;
}
public A withNewReportingInstance(String arg1){
return (A)withReportingInstance(new String(arg1));
}
public A withNewReportingInstance(StringBuilder arg1){
return (A)withReportingInstance(new String(arg1));
}
public A withNewReportingInstance(StringBuffer arg1){
return (A)withReportingInstance(new String(arg1));
}
/**
* This method has been deprecated, please use method buildSeries instead.
* @return The buildable object.
*/
@Deprecated public EventSeries getSeries(){
return this.series!=null?this.series.build():null;
}
public EventSeries buildSeries(){
return this.series!=null?this.series.build():null;
}
public A withSeries(EventSeries series){
_visitables.get("series").remove(this.series);
if (series!=null){ this.series= new EventSeriesBuilder(series); _visitables.get("series").add(this.series);} return (A) this;
}
public Boolean hasSeries(){
return this.series != null;
}
public EventFluent.SeriesNested withNewSeries(){
return new SeriesNestedImpl();
}
public EventFluent.SeriesNested withNewSeriesLike(EventSeries item){
return new SeriesNestedImpl(item);
}
public EventFluent.SeriesNested editSeries(){
return withNewSeriesLike(getSeries());
}
public EventFluent.SeriesNested editOrNewSeries(){
return withNewSeriesLike(getSeries() != null ? getSeries(): new EventSeriesBuilder().build());
}
public EventFluent.SeriesNested editOrNewSeriesLike(EventSeries item){
return withNewSeriesLike(getSeries() != null ? getSeries(): item);
}
/**
* This method has been deprecated, please use method buildSource instead.
* @return The buildable object.
*/
@Deprecated public EventSource getSource(){
return this.source!=null?this.source.build():null;
}
public EventSource buildSource(){
return this.source!=null?this.source.build():null;
}
public A withSource(EventSource source){
_visitables.get("source").remove(this.source);
if (source!=null){ this.source= new EventSourceBuilder(source); _visitables.get("source").add(this.source);} return (A) this;
}
public Boolean hasSource(){
return this.source != null;
}
public A withNewSource(String component,String host){
return (A)withSource(new EventSource(component, host));
}
public EventFluent.SourceNested withNewSource(){
return new SourceNestedImpl();
}
public EventFluent.SourceNested withNewSourceLike(EventSource item){
return new SourceNestedImpl(item);
}
public EventFluent.SourceNested editSource(){
return withNewSourceLike(getSource());
}
public EventFluent.SourceNested editOrNewSource(){
return withNewSourceLike(getSource() != null ? getSource(): new EventSourceBuilder().build());
}
public EventFluent.SourceNested editOrNewSourceLike(EventSource item){
return withNewSourceLike(getSource() != null ? getSource(): item);
}
public String getType(){
return this.type;
}
public A withType(String type){
this.type=type; return (A) this;
}
public Boolean hasType(){
return this.type != null;
}
public A withNewType(String arg1){
return (A)withType(new String(arg1));
}
public A withNewType(StringBuilder arg1){
return (A)withType(new String(arg1));
}
public A withNewType(StringBuffer arg1){
return (A)withType(new String(arg1));
}
public boolean equals(Object o){
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
EventFluentImpl that = (EventFluentImpl) o;
if (action != null ? !action.equals(that.action) :that.action != null) return false;
if (apiVersion != null ? !apiVersion.equals(that.apiVersion) :that.apiVersion != null) return false;
if (count != null ? !count.equals(that.count) :that.count != null) return false;
if (eventTime != null ? !eventTime.equals(that.eventTime) :that.eventTime != null) return false;
if (firstTimestamp != null ? !firstTimestamp.equals(that.firstTimestamp) :that.firstTimestamp != null) return false;
if (involvedObject != null ? !involvedObject.equals(that.involvedObject) :that.involvedObject != null) return false;
if (kind != null ? !kind.equals(that.kind) :that.kind != null) return false;
if (lastTimestamp != null ? !lastTimestamp.equals(that.lastTimestamp) :that.lastTimestamp != null) return false;
if (message != null ? !message.equals(that.message) :that.message != null) return false;
if (metadata != null ? !metadata.equals(that.metadata) :that.metadata != null) return false;
if (reason != null ? !reason.equals(that.reason) :that.reason != null) return false;
if (related != null ? !related.equals(that.related) :that.related != null) return false;
if (reportingComponent != null ? !reportingComponent.equals(that.reportingComponent) :that.reportingComponent != null) return false;
if (reportingInstance != null ? !reportingInstance.equals(that.reportingInstance) :that.reportingInstance != null) return false;
if (series != null ? !series.equals(that.series) :that.series != null) return false;
if (source != null ? !source.equals(that.source) :that.source != null) return false;
if (type != null ? !type.equals(that.type) :that.type != null) return false;
return true;
}
public class EventTimeNestedImpl extends MicroTimeFluentImpl> implements EventFluent.EventTimeNested,io.fabric8.kubernetes.api.builder.Nested{
private final MicroTimeBuilder builder;
EventTimeNestedImpl(MicroTime item){
this.builder = new MicroTimeBuilder(this, item);
}
EventTimeNestedImpl(){
this.builder = new MicroTimeBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withEventTime(builder.build());
}
public N endEventTime(){
return and();
}
}
public class InvolvedObjectNestedImpl extends ObjectReferenceFluentImpl> implements EventFluent.InvolvedObjectNested,io.fabric8.kubernetes.api.builder.Nested{
private final ObjectReferenceBuilder builder;
InvolvedObjectNestedImpl(ObjectReference item){
this.builder = new ObjectReferenceBuilder(this, item);
}
InvolvedObjectNestedImpl(){
this.builder = new ObjectReferenceBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withInvolvedObject(builder.build());
}
public N endInvolvedObject(){
return and();
}
}
public class MetadataNestedImpl extends ObjectMetaFluentImpl> implements EventFluent.MetadataNested,io.fabric8.kubernetes.api.builder.Nested{
private final ObjectMetaBuilder builder;
MetadataNestedImpl(ObjectMeta item){
this.builder = new ObjectMetaBuilder(this, item);
}
MetadataNestedImpl(){
this.builder = new ObjectMetaBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withMetadata(builder.build());
}
public N endMetadata(){
return and();
}
}
public class RelatedNestedImpl extends ObjectReferenceFluentImpl> implements EventFluent.RelatedNested,io.fabric8.kubernetes.api.builder.Nested{
private final ObjectReferenceBuilder builder;
RelatedNestedImpl(ObjectReference item){
this.builder = new ObjectReferenceBuilder(this, item);
}
RelatedNestedImpl(){
this.builder = new ObjectReferenceBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withRelated(builder.build());
}
public N endRelated(){
return and();
}
}
public class SeriesNestedImpl extends EventSeriesFluentImpl> implements EventFluent.SeriesNested,io.fabric8.kubernetes.api.builder.Nested{
private final EventSeriesBuilder builder;
SeriesNestedImpl(EventSeries item){
this.builder = new EventSeriesBuilder(this, item);
}
SeriesNestedImpl(){
this.builder = new EventSeriesBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withSeries(builder.build());
}
public N endSeries(){
return and();
}
}
public class SourceNestedImpl extends EventSourceFluentImpl> implements EventFluent.SourceNested,io.fabric8.kubernetes.api.builder.Nested{
private final EventSourceBuilder builder;
SourceNestedImpl(EventSource item){
this.builder = new EventSourceBuilder(this, item);
}
SourceNestedImpl(){
this.builder = new EventSourceBuilder(this);
}
public N and(){
return (N) EventFluentImpl.this.withSource(builder.build());
}
public N endSource(){
return and();
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy