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

com.google.common.truth.extensions.proto.AutoValue_DiffResult Maven / Gradle / Ivy

The newest version!
package com.google.common.truth.extensions.proto;

import com.google.common.base.Optional;
import com.google.common.collect.ImmutableListMultimap;
import com.google.errorprone.annotations.concurrent.LazyInit;
import com.google.protobuf.Message;
import java.lang.Integer;
import java.lang.Iterable;
import java.lang.Override;
import java.lang.SuppressWarnings;

final class AutoValue_DiffResult extends $AutoValue_DiffResult {
  @LazyInit
  @SuppressWarnings("Immutable")
  private transient volatile Iterable childEntities;

  AutoValue_DiffResult(Message actual, Message expected,
      ImmutableListMultimap singularFields,
      ImmutableListMultimap repeatedFields,
      Optional unknownFields) {
    super(actual, expected, singularFields, repeatedFields, unknownFields);
  }

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy