com.google.javascript.jscomp.AutoValue_TypeMismatch_LazyError Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of closure-compiler-unshaded Show documentation
Show all versions of closure-compiler-unshaded Show documentation
Closure Compiler is a JavaScript optimizing compiler. It parses your
JavaScript, analyzes it, removes dead code and rewrites and minimizes
what's left. It also checks syntax, variable references, and types, and
warns about common JavaScript pitfalls. It is used in many of Google's
JavaScript apps, including Gmail, Google Web Search, Google Maps, and
Google Docs.
package com.google.javascript.jscomp;
import com.google.javascript.rhino.Node;
import com.google.javascript.rhino.jstype.JSType;
import javax.annotation.Generated;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_TypeMismatch_LazyError extends TypeMismatch.LazyError {
private final String message;
private final Node node;
private final JSType sourceType;
private final JSType targetType;
AutoValue_TypeMismatch_LazyError(
String message,
Node node,
JSType sourceType,
JSType targetType) {
if (message == null) {
throw new NullPointerException("Null message");
}
this.message = message;
if (node == null) {
throw new NullPointerException("Null node");
}
this.node = node;
if (sourceType == null) {
throw new NullPointerException("Null sourceType");
}
this.sourceType = sourceType;
if (targetType == null) {
throw new NullPointerException("Null targetType");
}
this.targetType = targetType;
}
@Override
String message() {
return message;
}
@Override
Node node() {
return node;
}
@Override
JSType sourceType() {
return sourceType;
}
@Override
JSType targetType() {
return targetType;
}
@Override
public String toString() {
return "LazyError{"
+ "message=" + message + ", "
+ "node=" + node + ", "
+ "sourceType=" + sourceType + ", "
+ "targetType=" + targetType
+ "}";
}
@Override
public boolean equals(Object o) {
if (o == this) {
return true;
}
if (o instanceof TypeMismatch.LazyError) {
TypeMismatch.LazyError that = (TypeMismatch.LazyError) o;
return (this.message.equals(that.message()))
&& (this.node.equals(that.node()))
&& (this.sourceType.equals(that.sourceType()))
&& (this.targetType.equals(that.targetType()));
}
return false;
}
@Override
public int hashCode() {
int h = 1;
h *= 1000003;
h ^= this.message.hashCode();
h *= 1000003;
h ^= this.node.hashCode();
h *= 1000003;
h ^= this.sourceType.hashCode();
h *= 1000003;
h ^= this.targetType.hashCode();
return h;
}
}