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

com.google.gerrit.server.AutoValue_ReviewerStatusUpdate Maven / Gradle / Ivy

There is a newer version: 3.10.0-rc4
Show newest version


package com.google.gerrit.server;

import com.google.gerrit.reviewdb.client.Account;
import com.google.gerrit.server.notedb.ReviewerStateInternal;
import java.sql.Timestamp;
import javax.annotation.Generated;

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

  private final Timestamp date;

  private final Account.Id updatedBy;

  private final Account.Id reviewer;

  private final ReviewerStateInternal state;

  AutoValue_ReviewerStatusUpdate(
      Timestamp date,
      Account.Id updatedBy,
      Account.Id reviewer,
      ReviewerStateInternal state) {
    if (date == null) {
      throw new NullPointerException("Null date");
    }
    this.date = date;
    if (updatedBy == null) {
      throw new NullPointerException("Null updatedBy");
    }
    this.updatedBy = updatedBy;
    if (reviewer == null) {
      throw new NullPointerException("Null reviewer");
    }
    this.reviewer = reviewer;
    if (state == null) {
      throw new NullPointerException("Null state");
    }
    this.state = state;
  }

  @Override
  public Timestamp date() {
    return date;
  }

  @Override
  public Account.Id updatedBy() {
    return updatedBy;
  }

  @Override
  public Account.Id reviewer() {
    return reviewer;
  }

  @Override
  public ReviewerStateInternal state() {
    return state;
  }

  @Override
  public String toString() {
    return "ReviewerStatusUpdate{"
         + "date=" + date + ", "
         + "updatedBy=" + updatedBy + ", "
         + "reviewer=" + reviewer + ", "
         + "state=" + state
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof ReviewerStatusUpdate) {
      ReviewerStatusUpdate that = (ReviewerStatusUpdate) o;
      return (this.date.equals(that.date()))
           && (this.updatedBy.equals(that.updatedBy()))
           && (this.reviewer.equals(that.reviewer()))
           && (this.state.equals(that.state()));
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h$ = 1;
    h$ *= 1000003;
    h$ ^= date.hashCode();
    h$ *= 1000003;
    h$ ^= updatedBy.hashCode();
    h$ *= 1000003;
    h$ ^= reviewer.hashCode();
    h$ *= 1000003;
    h$ ^= state.hashCode();
    return h$;
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy