All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.flyte.api.v1.AutoValue_NamedEntityIdentifier Maven / Gradle / Ivy

There is a newer version: 0.4.60
Show newest version
package org.flyte.api.v1;

import javax.annotation.processing.Generated;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_NamedEntityIdentifier extends NamedEntityIdentifier {

  private final String domain;

  private final String project;

  private final String name;

  private AutoValue_NamedEntityIdentifier(
      String domain,
      String project,
      String name) {
    this.domain = domain;
    this.project = project;
    this.name = name;
  }

  @Override
  public String domain() {
    return domain;
  }

  @Override
  public String project() {
    return project;
  }

  @Override
  public String name() {
    return name;
  }

  @Override
  public String toString() {
    return "NamedEntityIdentifier{"
        + "domain=" + domain + ", "
        + "project=" + project + ", "
        + "name=" + name
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof NamedEntityIdentifier) {
      NamedEntityIdentifier that = (NamedEntityIdentifier) o;
      return this.domain.equals(that.domain())
          && this.project.equals(that.project())
          && this.name.equals(that.name());
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= domain.hashCode();
    h$ *= 1000003;
    h$ ^= project.hashCode();
    h$ *= 1000003;
    h$ ^= name.hashCode();
    return h$;
  }

  static final class Builder extends NamedEntityIdentifier.Builder {
    private String domain;
    private String project;
    private String name;
    Builder() {
    }
    @Override
    public NamedEntityIdentifier.Builder domain(String domain) {
      if (domain == null) {
        throw new NullPointerException("Null domain");
      }
      this.domain = domain;
      return this;
    }
    @Override
    public NamedEntityIdentifier.Builder project(String project) {
      if (project == null) {
        throw new NullPointerException("Null project");
      }
      this.project = project;
      return this;
    }
    @Override
    public NamedEntityIdentifier.Builder name(String name) {
      if (name == null) {
        throw new NullPointerException("Null name");
      }
      this.name = name;
      return this;
    }
    @Override
    public NamedEntityIdentifier build() {
      if (this.domain == null
          || this.project == null
          || this.name == null) {
        StringBuilder missing = new StringBuilder();
        if (this.domain == null) {
          missing.append(" domain");
        }
        if (this.project == null) {
          missing.append(" project");
        }
        if (this.name == null) {
          missing.append(" name");
        }
        throw new IllegalStateException("Missing required properties:" + missing);
      }
      return new AutoValue_NamedEntityIdentifier(
          this.domain,
          this.project,
          this.name);
    }
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy