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

com.google.gerrit.server.change.AutoValue_ChangeTriplet Maven / Gradle / Ivy

There is a newer version: 3.11.0-rc3
Show newest version
package com.google.gerrit.server.change;

import com.google.gerrit.entities.BranchNameKey;
import com.google.gerrit.entities.Change;
import javax.annotation.processing.Generated;

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

  private final BranchNameKey branch;

  private final Change.Key id;

  AutoValue_ChangeTriplet(
      BranchNameKey branch,
      Change.Key id) {
    if (branch == null) {
      throw new NullPointerException("Null branch");
    }
    this.branch = branch;
    if (id == null) {
      throw new NullPointerException("Null id");
    }
    this.id = id;
  }

  @Override
  public BranchNameKey branch() {
    return branch;
  }

  @Override
  public Change.Key id() {
    return id;
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof ChangeTriplet) {
      ChangeTriplet that = (ChangeTriplet) o;
      return this.branch.equals(that.branch())
          && this.id.equals(that.id());
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= branch.hashCode();
    h$ *= 1000003;
    h$ ^= id.hashCode();
    return h$;
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy