org.molgenis.api.data.v3.AutoValue_Entities Maven / Gradle / Ivy
package org.molgenis.api.data.v3;
import java.util.List;
import javax.annotation.Generated;
import org.molgenis.data.Entity;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_Entities extends Entities {
private final List entities;
private final int total;
private AutoValue_Entities(
List entities,
int total) {
this.entities = entities;
this.total = total;
}
@Override
List getEntities() {
return entities;
}
@Override
int getTotal() {
return total;
}
@Override
public String toString() {
return "Entities{"
+ "entities=" + entities + ", "
+ "total=" + total
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof Entities) {
Entities that = (Entities) o;
return (this.entities.equals(that.getEntities()))
&& (this.total == that.getTotal());
}
return false;
}
@Override
public int hashCode() {
int h = 1;
h *= 1000003;
h ^= this.entities.hashCode();
h *= 1000003;
h ^= this.total;
return h;
}
static final class Builder extends Entities.Builder {
private List entities;
private Integer total;
Builder() {
}
@Override
public Entities.Builder setEntities(List entities) {
if (entities == null) {
throw new NullPointerException("Null entities");
}
this.entities = entities;
return this;
}
@Override
public Entities.Builder setTotal(int total) {
this.total = total;
return this;
}
@Override
public Entities build() {
String missing = "";
if (this.entities == null) {
missing += " entities";
}
if (this.total == null) {
missing += " total";
}
if (!missing.isEmpty()) {
throw new IllegalStateException("Missing required properties:" + missing);
}
return new AutoValue_Entities(
this.entities,
this.total);
}
}
}