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

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

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

import com.google.common.collect.ImmutableList;
import com.google.errorprone.annotations.concurrent.LazyInit;
import com.google.gerrit.entities.Project;
import com.google.gerrit.server.logging.TraceContext;
import java.lang.Override;
import java.lang.String;
import java.lang.SuppressWarnings;
import java.util.Optional;
import javax.annotation.processing.Generated;

@Generated("com.google.auto.value.extension.memoized.processor.MemoizeExtension")
final class AutoValue_RequestInfo extends $AutoValue_RequestInfo {
  @LazyInit
  @SuppressWarnings("Immutable")
  private transient volatile Optional redactedRequestUri;

  @LazyInit
  @SuppressWarnings("Immutable")
  private transient volatile String formatForLogging;

  AutoValue_RequestInfo(String requestType$, Optional requestUri$,
      Optional requestQueryString$, ImmutableList headers$,
      CurrentUser callingUser$, TraceContext traceContext$, Optional project$) {
    super(requestType$, requestUri$, requestQueryString$, headers$, callingUser$, traceContext$, project$);
  }

  @Override
  public Optional redactedRequestUri() {
    if (redactedRequestUri == null) {
      synchronized (this) {
        if (redactedRequestUri == null) {
          redactedRequestUri = super.redactedRequestUri();
          if (redactedRequestUri == null) {
            throw new NullPointerException("redactedRequestUri() cannot return null");
          }
        }
      }
    }
    return redactedRequestUri;
  }

  @Override
  public String formatForLogging() {
    if (formatForLogging == null) {
      synchronized (this) {
        if (formatForLogging == null) {
          formatForLogging = super.formatForLogging();
          if (formatForLogging == null) {
            throw new NullPointerException("formatForLogging() cannot return null");
          }
        }
      }
    }
    return formatForLogging;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy