com.google.javascript.jscomp.modules.AutoValue_Binding 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.
The newest version!
package com.google.javascript.jscomp.modules;
import com.google.javascript.rhino.Node;
import javax.annotation.processing.Generated;
import org.jspecify.nullness.Nullable;
@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_Binding extends Binding {
private final ModuleMetadataMap.ModuleMetadata metadata;
private final @Nullable Node sourceNode;
private final @Nullable Export originatingExport;
private final boolean isModuleNamespace;
private final @Nullable String closureNamespace;
private final Binding.CreatedBy createdBy;
AutoValue_Binding(
ModuleMetadataMap.ModuleMetadata metadata,
@Nullable Node sourceNode,
@Nullable Export originatingExport,
boolean isModuleNamespace,
@Nullable String closureNamespace,
Binding.CreatedBy createdBy) {
if (metadata == null) {
throw new NullPointerException("Null metadata");
}
this.metadata = metadata;
this.sourceNode = sourceNode;
this.originatingExport = originatingExport;
this.isModuleNamespace = isModuleNamespace;
this.closureNamespace = closureNamespace;
if (createdBy == null) {
throw new NullPointerException("Null createdBy");
}
this.createdBy = createdBy;
}
@Override
public ModuleMetadataMap.ModuleMetadata metadata() {
return metadata;
}
@Override
public @Nullable Node sourceNode() {
return sourceNode;
}
@Override
public @Nullable Export originatingExport() {
return originatingExport;
}
@Override
public boolean isModuleNamespace() {
return isModuleNamespace;
}
@Override
public @Nullable String closureNamespace() {
return closureNamespace;
}
@Override
public Binding.CreatedBy createdBy() {
return createdBy;
}
@Override
public String toString() {
return "Binding{"
+ "metadata=" + metadata + ", "
+ "sourceNode=" + sourceNode + ", "
+ "originatingExport=" + originatingExport + ", "
+ "isModuleNamespace=" + isModuleNamespace + ", "
+ "closureNamespace=" + closureNamespace + ", "
+ "createdBy=" + createdBy
+ "}";
}
@Override
public boolean equals(@Nullable Object o) {
if (o == this) {
return true;
}
if (o instanceof Binding) {
Binding that = (Binding) o;
return this.metadata.equals(that.metadata())
&& (this.sourceNode == null ? that.sourceNode() == null : this.sourceNode.equals(that.sourceNode()))
&& (this.originatingExport == null ? that.originatingExport() == null : this.originatingExport.equals(that.originatingExport()))
&& this.isModuleNamespace == that.isModuleNamespace()
&& (this.closureNamespace == null ? that.closureNamespace() == null : this.closureNamespace.equals(that.closureNamespace()))
&& this.createdBy.equals(that.createdBy());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= metadata.hashCode();
h$ *= 1000003;
h$ ^= (sourceNode == null) ? 0 : sourceNode.hashCode();
h$ *= 1000003;
h$ ^= (originatingExport == null) ? 0 : originatingExport.hashCode();
h$ *= 1000003;
h$ ^= isModuleNamespace ? 1231 : 1237;
h$ *= 1000003;
h$ ^= (closureNamespace == null) ? 0 : closureNamespace.hashCode();
h$ *= 1000003;
h$ ^= createdBy.hashCode();
return h$;
}
}