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

com.github.kristofa.brave.AutoValue_ServerTracer Maven / Gradle / Ivy

There is a newer version: 4.13.6
Show newest version

package com.github.kristofa.brave;

import javax.annotation.Generated;

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

  private final Recorder recorder;
  private final ServerSpanThreadBinder currentSpan;
  private final SpanFactory spanFactory;

  AutoValue_ServerTracer(
      Recorder recorder,
      ServerSpanThreadBinder currentSpan,
      SpanFactory spanFactory) {
    if (recorder == null) {
      throw new NullPointerException("Null recorder");
    }
    this.recorder = recorder;
    if (currentSpan == null) {
      throw new NullPointerException("Null currentSpan");
    }
    this.currentSpan = currentSpan;
    if (spanFactory == null) {
      throw new NullPointerException("Null spanFactory");
    }
    this.spanFactory = spanFactory;
  }

  @Override
  Recorder recorder() {
    return recorder;
  }

  @Override
  ServerSpanThreadBinder currentSpan() {
    return currentSpan;
  }

  @Override
  SpanFactory spanFactory() {
    return spanFactory;
  }

  @Override
  public String toString() {
    return "ServerTracer{"
        + "recorder=" + recorder + ", "
        + "currentSpan=" + currentSpan + ", "
        + "spanFactory=" + spanFactory
        + "}";
  }

  @Override
  public boolean equals(Object o) {
    if (o == this) {
      return true;
    }
    if (o instanceof ServerTracer) {
      ServerTracer that = (ServerTracer) o;
      return (this.recorder.equals(that.recorder()))
           && (this.currentSpan.equals(that.currentSpan()))
           && (this.spanFactory.equals(that.spanFactory()));
    }
    return false;
  }

  @Override
  public int hashCode() {
    int h = 1;
    h *= 1000003;
    h ^= this.recorder.hashCode();
    h *= 1000003;
    h ^= this.currentSpan.hashCode();
    h *= 1000003;
    h ^= this.spanFactory.hashCode();
    return h;
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy