com.google.cloud.bigquery.AutoValue_ReadClientConnectionConfiguration Maven / Gradle / Ivy
package com.google.cloud.bigquery;
import javax.annotation.Generated;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_ReadClientConnectionConfiguration extends ReadClientConnectionConfiguration {
private final Long totalToPageRowCountRatio;
private final Long minResultSize;
private final Long bufferSize;
private AutoValue_ReadClientConnectionConfiguration(
Long totalToPageRowCountRatio,
Long minResultSize,
Long bufferSize) {
this.totalToPageRowCountRatio = totalToPageRowCountRatio;
this.minResultSize = minResultSize;
this.bufferSize = bufferSize;
}
@Override
public Long getTotalToPageRowCountRatio() {
return totalToPageRowCountRatio;
}
@Override
public Long getMinResultSize() {
return minResultSize;
}
@Override
public Long getBufferSize() {
return bufferSize;
}
@Override
public String toString() {
return "ReadClientConnectionConfiguration{"
+ "totalToPageRowCountRatio=" + totalToPageRowCountRatio + ", "
+ "minResultSize=" + minResultSize + ", "
+ "bufferSize=" + bufferSize
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof ReadClientConnectionConfiguration) {
ReadClientConnectionConfiguration that = (ReadClientConnectionConfiguration) o;
return this.totalToPageRowCountRatio.equals(that.getTotalToPageRowCountRatio())
&& this.minResultSize.equals(that.getMinResultSize())
&& this.bufferSize.equals(that.getBufferSize());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= totalToPageRowCountRatio.hashCode();
h$ *= 1000003;
h$ ^= minResultSize.hashCode();
h$ *= 1000003;
h$ ^= bufferSize.hashCode();
return h$;
}
@Override
public ReadClientConnectionConfiguration.Builder toBuilder() {
return new Builder(this);
}
static final class Builder extends ReadClientConnectionConfiguration.Builder {
private Long totalToPageRowCountRatio;
private Long minResultSize;
private Long bufferSize;
Builder() {
}
private Builder(ReadClientConnectionConfiguration source) {
this.totalToPageRowCountRatio = source.getTotalToPageRowCountRatio();
this.minResultSize = source.getMinResultSize();
this.bufferSize = source.getBufferSize();
}
@Override
public ReadClientConnectionConfiguration.Builder setTotalToPageRowCountRatio(Long totalToPageRowCountRatio) {
if (totalToPageRowCountRatio == null) {
throw new NullPointerException("Null totalToPageRowCountRatio");
}
this.totalToPageRowCountRatio = totalToPageRowCountRatio;
return this;
}
@Override
public ReadClientConnectionConfiguration.Builder setMinResultSize(Long minResultSize) {
if (minResultSize == null) {
throw new NullPointerException("Null minResultSize");
}
this.minResultSize = minResultSize;
return this;
}
@Override
public ReadClientConnectionConfiguration.Builder setBufferSize(Long bufferSize) {
if (bufferSize == null) {
throw new NullPointerException("Null bufferSize");
}
this.bufferSize = bufferSize;
return this;
}
@Override
public ReadClientConnectionConfiguration build() {
if (this.totalToPageRowCountRatio == null
|| this.minResultSize == null
|| this.bufferSize == null) {
StringBuilder missing = new StringBuilder();
if (this.totalToPageRowCountRatio == null) {
missing.append(" totalToPageRowCountRatio");
}
if (this.minResultSize == null) {
missing.append(" minResultSize");
}
if (this.bufferSize == null) {
missing.append(" bufferSize");
}
throw new IllegalStateException("Missing required properties:" + missing);
}
return new AutoValue_ReadClientConnectionConfiguration(
this.totalToPageRowCountRatio,
this.minResultSize,
this.bufferSize);
}
}
}