com.google.gerrit.server.patch.AutoValue_MagicFile Maven / Gradle / Ivy
package com.google.gerrit.server.patch;
import javax.annotation.processing.Generated;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_MagicFile extends MagicFile {
private final String generatedContent;
private final String modifiableContent;
private AutoValue_MagicFile(
String generatedContent,
String modifiableContent) {
this.generatedContent = generatedContent;
this.modifiableContent = modifiableContent;
}
@Override
public String generatedContent() {
return generatedContent;
}
@Override
public String modifiableContent() {
return modifiableContent;
}
@Override
public String toString() {
return "MagicFile{"
+ "generatedContent=" + generatedContent + ", "
+ "modifiableContent=" + modifiableContent
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof MagicFile) {
MagicFile that = (MagicFile) o;
return this.generatedContent.equals(that.generatedContent())
&& this.modifiableContent.equals(that.modifiableContent());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= generatedContent.hashCode();
h$ *= 1000003;
h$ ^= modifiableContent.hashCode();
return h$;
}
static final class Builder extends MagicFile.Builder {
private String generatedContent;
private String modifiableContent;
Builder() {
}
@Override
public MagicFile.Builder generatedContent(String generatedContent) {
if (generatedContent == null) {
throw new NullPointerException("Null generatedContent");
}
this.generatedContent = generatedContent;
return this;
}
@Override
String generatedContent() {
if (generatedContent == null) {
throw new IllegalStateException("Property \"generatedContent\" has not been set");
}
return generatedContent;
}
@Override
public MagicFile.Builder modifiableContent(String modifiableContent) {
if (modifiableContent == null) {
throw new NullPointerException("Null modifiableContent");
}
this.modifiableContent = modifiableContent;
return this;
}
@Override
String modifiableContent() {
if (modifiableContent == null) {
throw new IllegalStateException("Property \"modifiableContent\" has not been set");
}
return modifiableContent;
}
@Override
MagicFile autoBuild() {
String missing = "";
if (this.generatedContent == null) {
missing += " generatedContent";
}
if (this.modifiableContent == null) {
missing += " modifiableContent";
}
if (!missing.isEmpty()) {
throw new IllegalStateException("Missing required properties:" + missing);
}
return new AutoValue_MagicFile(
this.generatedContent,
this.modifiableContent);
}
}
}