
com.google.javascript.jscomp.modules.AutoValue_Import Maven / Gradle / Ivy
package com.google.javascript.jscomp.modules;
import com.google.javascript.jscomp.deps.ModuleLoader;
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_Import extends Import {
private final String moduleRequest;
private final String importName;
private final String localName;
private final ModuleLoader.@Nullable ModulePath modulePath;
private final Node importNode;
private final Node nameNode;
private AutoValue_Import(
String moduleRequest,
String importName,
String localName,
ModuleLoader.@Nullable ModulePath modulePath,
Node importNode,
Node nameNode) {
this.moduleRequest = moduleRequest;
this.importName = importName;
this.localName = localName;
this.modulePath = modulePath;
this.importNode = importNode;
this.nameNode = nameNode;
}
@Override
public String moduleRequest() {
return moduleRequest;
}
@Override
public String importName() {
return importName;
}
@Override
public String localName() {
return localName;
}
@Override
public ModuleLoader.@Nullable ModulePath modulePath() {
return modulePath;
}
@Override
public Node importNode() {
return importNode;
}
@Override
public Node nameNode() {
return nameNode;
}
@Override
public String toString() {
return "Import{"
+ "moduleRequest=" + moduleRequest + ", "
+ "importName=" + importName + ", "
+ "localName=" + localName + ", "
+ "modulePath=" + modulePath + ", "
+ "importNode=" + importNode + ", "
+ "nameNode=" + nameNode
+ "}";
}
@Override
public boolean equals(@Nullable Object o) {
if (o == this) {
return true;
}
if (o instanceof Import) {
Import that = (Import) o;
return this.moduleRequest.equals(that.moduleRequest())
&& this.importName.equals(that.importName())
&& this.localName.equals(that.localName())
&& (this.modulePath == null ? that.modulePath() == null : this.modulePath.equals(that.modulePath()))
&& this.importNode.equals(that.importNode())
&& this.nameNode.equals(that.nameNode());
}
return false;
}
@Override
public int hashCode() {
int h$ = 1;
h$ *= 1000003;
h$ ^= moduleRequest.hashCode();
h$ *= 1000003;
h$ ^= importName.hashCode();
h$ *= 1000003;
h$ ^= localName.hashCode();
h$ *= 1000003;
h$ ^= (modulePath == null) ? 0 : modulePath.hashCode();
h$ *= 1000003;
h$ ^= importNode.hashCode();
h$ *= 1000003;
h$ ^= nameNode.hashCode();
return h$;
}
static final class Builder extends Import.Builder {
private @Nullable String moduleRequest;
private @Nullable String importName;
private @Nullable String localName;
private ModuleLoader.@Nullable ModulePath modulePath;
private @Nullable Node importNode;
private @Nullable Node nameNode;
Builder() {
}
@Override
Import.Builder moduleRequest(String moduleRequest) {
if (moduleRequest == null) {
throw new NullPointerException("Null moduleRequest");
}
this.moduleRequest = moduleRequest;
return this;
}
@Override
Import.Builder importName(String importName) {
if (importName == null) {
throw new NullPointerException("Null importName");
}
this.importName = importName;
return this;
}
@Override
Import.Builder localName(String localName) {
if (localName == null) {
throw new NullPointerException("Null localName");
}
this.localName = localName;
return this;
}
@Override
Import.Builder modulePath(ModuleLoader.ModulePath modulePath) {
this.modulePath = modulePath;
return this;
}
@Override
Import.Builder importNode(Node importNode) {
if (importNode == null) {
throw new NullPointerException("Null importNode");
}
this.importNode = importNode;
return this;
}
@Override
Import.Builder nameNode(Node nameNode) {
if (nameNode == null) {
throw new NullPointerException("Null nameNode");
}
this.nameNode = nameNode;
return this;
}
@Override
Import build() {
if (this.moduleRequest == null
|| this.importName == null
|| this.localName == null
|| this.importNode == null
|| this.nameNode == null) {
StringBuilder missing = new StringBuilder();
if (this.moduleRequest == null) {
missing.append(" moduleRequest");
}
if (this.importName == null) {
missing.append(" importName");
}
if (this.localName == null) {
missing.append(" localName");
}
if (this.importNode == null) {
missing.append(" importNode");
}
if (this.nameNode == null) {
missing.append(" nameNode");
}
throw new IllegalStateException("Missing required properties:" + missing);
}
return new AutoValue_Import(
this.moduleRequest,
this.importName,
this.localName,
this.modulePath,
this.importNode,
this.nameNode);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy