org.graylog2.rest.models.system.responses.AutoValue_LocalesResponse_LocaleDescription Maven / Gradle / Ivy
package org.graylog2.rest.models.system.responses;
import com.fasterxml.jackson.annotation.JsonProperty;
import javax.annotation.Generated;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_LocalesResponse_LocaleDescription extends LocalesResponse.LocaleDescription {
private final String languageTag;
private final String displayName;
AutoValue_LocalesResponse_LocaleDescription(
String languageTag,
String displayName) {
if (languageTag == null) {
throw new NullPointerException("Null languageTag");
}
this.languageTag = languageTag;
if (displayName == null) {
throw new NullPointerException("Null displayName");
}
this.displayName = displayName;
}
@JsonProperty(value = "language_tag")
@Override
public String languageTag() {
return languageTag;
}
@JsonProperty(value = "display_name")
@Override
public String displayName() {
return displayName;
}
@Override
public String toString() {
return "LocaleDescription{"
+ "languageTag=" + languageTag + ", "
+ "displayName=" + displayName
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof LocalesResponse.LocaleDescription) {
LocalesResponse.LocaleDescription that = (LocalesResponse.LocaleDescription) o;
return (this.languageTag.equals(that.languageTag()))
&& (this.displayName.equals(that.displayName()));
}
return false;
}
@Override
public int hashCode() {
int h = 1;
h *= 1000003;
h ^= this.languageTag.hashCode();
h *= 1000003;
h ^= this.displayName.hashCode();
return h;
}
}