edu.stanford.protege.webprotege.watches.AutoValue_Watch Maven / Gradle / Ivy
The newest version!
package edu.stanford.protege.webprotege.watches;
import edu.stanford.protege.webprotege.common.UserId;
import javax.annotation.Nonnull;
import javax.annotation.processing.Generated;
import org.semanticweb.owlapi.model.OWLEntity;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_Watch extends Watch {
private final UserId userId;
private final OWLEntity entity;
private final WatchType type;
AutoValue_Watch(
UserId userId,
OWLEntity entity,
WatchType type) {
if (userId == null) {
throw new NullPointerException("Null userId");
}
this.userId = userId;
if (entity == null) {
throw new NullPointerException("Null entity");
}
this.entity = entity;
if (type == null) {
throw new NullPointerException("Null type");
}
this.type = type;
}
@Nonnull
@Override
public UserId getUserId() {
return userId;
}
@Nonnull
@Override
public OWLEntity getEntity() {
return entity;
}
@Nonnull
@Override
public WatchType getType() {
return type;
}
@Override
public String toString() {
return "Watch{"
+ "userId=" + userId + ", "
+ "entity=" + entity + ", "
+ "type=" + type
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof Watch) {
Watch that = (Watch) o;
return this.userId.equals(that.getUserId())
&& this.entity.equals(that.getEntity())
&& this.type.equals(that.getType());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= userId.hashCode();
h$ *= 1000003;
h$ ^= entity.hashCode();
h$ *= 1000003;
h$ ^= type.hashCode();
return h$;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy