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

org.graylog.plugins.views.migrations.V20191125144500_MigrateDashboardsToViewsSupport.viewwidgets.AutoValue_Series Maven / Gradle / Ivy

There is a newer version: 6.0.2
Show newest version
package org.graylog.plugins.views.migrations.V20191125144500_MigrateDashboardsToViewsSupport.viewwidgets;

import com.fasterxml.jackson.annotation.JsonProperty;
import javax.annotation.processing.Generated;

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

  private final SeriesConfig config;

  private final String function;

  private AutoValue_Series(
      SeriesConfig config,
      String function) {
    this.config = config;
    this.function = function;
  }

  @JsonProperty("config")
  @Override
  public SeriesConfig config() {
    return config;
  }

  @JsonProperty("function")
  @Override
  public String function() {
    return function;
  }

  @Override
  public String toString() {
    return "Series{"
        + "config=" + config + ", "
        + "function=" + function
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof Series) {
      Series that = (Series) o;
      return this.config.equals(that.config())
          && this.function.equals(that.function());
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= config.hashCode();
    h$ *= 1000003;
    h$ ^= function.hashCode();
    return h$;
  }

  static final class Builder extends Series.Builder {
    private SeriesConfig config;
    private String function;
    Builder() {
    }
    @Override
    public Series.Builder config(SeriesConfig config) {
      if (config == null) {
        throw new NullPointerException("Null config");
      }
      this.config = config;
      return this;
    }
    @Override
    public Series.Builder function(String function) {
      if (function == null) {
        throw new NullPointerException("Null function");
      }
      this.function = function;
      return this;
    }
    @Override
    public Series build() {
      String missing = "";
      if (this.config == null) {
        missing += " config";
      }
      if (this.function == null) {
        missing += " function";
      }
      if (!missing.isEmpty()) {
        throw new IllegalStateException("Missing required properties:" + missing);
      }
      return new AutoValue_Series(
          this.config,
          this.function);
    }
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy