org.graylog.plugins.views.search.views.AutoValue_PluginMetadataSummary Maven / Gradle / Ivy
package org.graylog.plugins.views.search.views;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.github.zafarkhaja.semver.Version;
import java.net.URI;
import javax.annotation.Generated;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_PluginMetadataSummary extends PluginMetadataSummary {
private final String uniqueId;
private final String name;
private final String author;
private final URI url;
private final Version version;
private final String description;
AutoValue_PluginMetadataSummary(
String uniqueId,
String name,
String author,
URI url,
Version version,
String description) {
if (uniqueId == null) {
throw new NullPointerException("Null uniqueId");
}
this.uniqueId = uniqueId;
if (name == null) {
throw new NullPointerException("Null name");
}
this.name = name;
if (author == null) {
throw new NullPointerException("Null author");
}
this.author = author;
if (url == null) {
throw new NullPointerException("Null url");
}
this.url = url;
if (version == null) {
throw new NullPointerException("Null version");
}
this.version = version;
if (description == null) {
throw new NullPointerException("Null description");
}
this.description = description;
}
@JsonProperty("unique_id")
@Override
public String uniqueId() {
return uniqueId;
}
@JsonProperty
@Override
public String name() {
return name;
}
@JsonProperty
@Override
public String author() {
return author;
}
@JsonProperty
@Override
public URI url() {
return url;
}
@JsonProperty
@JsonSerialize(using = VersionSerializer.class)
@Override
public Version version() {
return version;
}
@JsonProperty
@Override
public String description() {
return description;
}
@Override
public String toString() {
return "PluginMetadataSummary{"
+ "uniqueId=" + uniqueId + ", "
+ "name=" + name + ", "
+ "author=" + author + ", "
+ "url=" + url + ", "
+ "version=" + version + ", "
+ "description=" + description
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof PluginMetadataSummary) {
PluginMetadataSummary that = (PluginMetadataSummary) o;
return this.uniqueId.equals(that.uniqueId())
&& this.name.equals(that.name())
&& this.author.equals(that.author())
&& this.url.equals(that.url())
&& this.version.equals(that.version())
&& this.description.equals(that.description());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= uniqueId.hashCode();
h$ *= 1000003;
h$ ^= name.hashCode();
h$ *= 1000003;
h$ ^= author.hashCode();
h$ *= 1000003;
h$ ^= url.hashCode();
h$ *= 1000003;
h$ ^= version.hashCode();
h$ *= 1000003;
h$ ^= description.hashCode();
return h$;
}
}