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

org.graylog2.rest.models.system.metrics.responses.$AutoValue_MetricsSummaryResponse Maven / Gradle / Ivy

There is a newer version: 5.2.7
Show newest version
package org.graylog2.rest.models.system.metrics.responses;

import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Collection;
import javax.annotation.Generated;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
abstract class $AutoValue_MetricsSummaryResponse extends MetricsSummaryResponse {

  private final int total;

  private final Collection metrics;

  $AutoValue_MetricsSummaryResponse(
      int total,
      Collection metrics) {
    this.total = total;
    if (metrics == null) {
      throw new NullPointerException("Null metrics");
    }
    this.metrics = metrics;
  }

  @JsonProperty
  @Override
  public int total() {
    return total;
  }

  @JsonProperty
  @Override
  public Collection metrics() {
    return metrics;
  }

  @Override
  public String toString() {
    return "MetricsSummaryResponse{"
         + "total=" + total + ", "
         + "metrics=" + metrics
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof MetricsSummaryResponse) {
      MetricsSummaryResponse that = (MetricsSummaryResponse) o;
      return this.total == that.total()
          && this.metrics.equals(that.metrics());
    }
    return false;
  }

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

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy