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

com.google.gerrit.server.patch.AutoValue_GitPositionTransformer_Mapping Maven / Gradle / Ivy

There is a newer version: 3.10.1
Show newest version
package com.google.gerrit.server.patch;

import com.google.common.collect.ImmutableSet;
import javax.annotation.processing.Generated;

@Generated("com.google.auto.value.processor.AutoValueProcessor")
final class AutoValue_GitPositionTransformer_Mapping extends GitPositionTransformer.Mapping {

  private final GitPositionTransformer.FileMapping file;

  private final ImmutableSet ranges;

  AutoValue_GitPositionTransformer_Mapping(
      GitPositionTransformer.FileMapping file,
      ImmutableSet ranges) {
    if (file == null) {
      throw new NullPointerException("Null file");
    }
    this.file = file;
    if (ranges == null) {
      throw new NullPointerException("Null ranges");
    }
    this.ranges = ranges;
  }

  @Override
  public GitPositionTransformer.FileMapping file() {
    return file;
  }

  @Override
  public ImmutableSet ranges() {
    return ranges;
  }

  @Override
  public String toString() {
    return "Mapping{"
        + "file=" + file + ", "
        + "ranges=" + ranges
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof GitPositionTransformer.Mapping) {
      GitPositionTransformer.Mapping that = (GitPositionTransformer.Mapping) o;
      return this.file.equals(that.file())
          && this.ranges.equals(that.ranges());
    }
    return false;
  }

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

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy