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

org.graylog.scheduler.AutoValue_JobTriggerUpdate Maven / Gradle / Ivy

There is a newer version: 6.0.1
Show newest version
package org.graylog.scheduler;

import java.util.Optional;
import javax.annotation.Nullable;
import javax.annotation.processing.Generated;
import org.joda.time.DateTime;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_JobTriggerUpdate extends JobTriggerUpdate {

  private final Optional nextTime;

  private final Optional data;

  private final Optional status;

  private AutoValue_JobTriggerUpdate(
      Optional nextTime,
      Optional data,
      Optional status) {
    this.nextTime = nextTime;
    this.data = data;
    this.status = status;
  }

  @Override
  public Optional nextTime() {
    return nextTime;
  }

  @Override
  public Optional data() {
    return data;
  }

  @Override
  public Optional status() {
    return status;
  }

  @Override
  public String toString() {
    return "JobTriggerUpdate{"
        + "nextTime=" + nextTime + ", "
        + "data=" + data + ", "
        + "status=" + status
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof JobTriggerUpdate) {
      JobTriggerUpdate that = (JobTriggerUpdate) o;
      return this.nextTime.equals(that.nextTime())
          && this.data.equals(that.data())
          && this.status.equals(that.status());
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= nextTime.hashCode();
    h$ *= 1000003;
    h$ ^= data.hashCode();
    h$ *= 1000003;
    h$ ^= status.hashCode();
    return h$;
  }

  @Override
  public JobTriggerUpdate.Builder toBuilder() {
    return new Builder(this);
  }

  static final class Builder extends JobTriggerUpdate.Builder {
    private Optional nextTime = Optional.empty();
    private Optional data = Optional.empty();
    private Optional status = Optional.empty();
    Builder() {
    }
    private Builder(JobTriggerUpdate source) {
      this.nextTime = source.nextTime();
      this.data = source.data();
      this.status = source.status();
    }
    @Override
    public JobTriggerUpdate.Builder nextTime(@Nullable DateTime nextTime) {
      this.nextTime = Optional.ofNullable(nextTime);
      return this;
    }
    @Override
    public JobTriggerUpdate.Builder data(@Nullable JobTriggerData data) {
      this.data = Optional.ofNullable(data);
      return this;
    }
    @Override
    public JobTriggerUpdate.Builder status(@Nullable JobTriggerStatus status) {
      this.status = Optional.ofNullable(status);
      return this;
    }
    @Override
    public JobTriggerUpdate build() {
      return new AutoValue_JobTriggerUpdate(
          this.nextTime,
          this.data,
          this.status);
    }
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy