// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: bazel-out/local-fastbuild/bin/src/main/protobuf/libextra_actions_base_java_proto_srcjar.srcjar.preprocessed/extra_actions_base.proto

package com.google.devtools.build.lib.actions.extra;

/**
 * <pre>
 * Provides access to data that is specific to C++ compile actions.
 * Usually provided by actions using the "CppCompile" Mnemonic.
 * </pre>
 *
 * Protobuf type {@code blaze.CppCompileInfo}
 */
public  final class CppCompileInfo extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:blaze.CppCompileInfo)
    CppCompileInfoOrBuilder {
  // Use CppCompileInfo.newBuilder() to construct.
  private CppCompileInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private CppCompileInfo() {
    tool_ = "";
    compilerOption_ = com.google.protobuf.LazyStringArrayList.EMPTY;
    sourceFile_ = "";
    outputFile_ = "";
    sourcesAndHeaders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private CppCompileInfo(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    int mutable_bitField0_ = 0;
    com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          default: {
            if (!parseUnknownField(input, unknownFields,
                                   extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
          case 10: {
            com.google.protobuf.ByteString bs = input.readBytes();
            bitField0_ |= 0x00000001;
            tool_ = bs;
            break;
          }
          case 18: {
            com.google.protobuf.ByteString bs = input.readBytes();
            if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
              compilerOption_ = new com.google.protobuf.LazyStringArrayList();
              mutable_bitField0_ |= 0x00000002;
            }
            compilerOption_.add(bs);
            break;
          }
          case 26: {
            com.google.protobuf.ByteString bs = input.readBytes();
            bitField0_ |= 0x00000002;
            sourceFile_ = bs;
            break;
          }
          case 34: {
            com.google.protobuf.ByteString bs = input.readBytes();
            bitField0_ |= 0x00000004;
            outputFile_ = bs;
            break;
          }
          case 42: {
            com.google.protobuf.ByteString bs = input.readBytes();
            if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
              sourcesAndHeaders_ = new com.google.protobuf.LazyStringArrayList();
              mutable_bitField0_ |= 0x00000010;
            }
            sourcesAndHeaders_.add(bs);
            break;
          }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
        compilerOption_ = compilerOption_.getUnmodifiableView();
      }
      if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
        sourcesAndHeaders_ = sourcesAndHeaders_.getUnmodifiableView();
      }
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.google.devtools.build.lib.actions.extra.ExtraActionsBase.internal_static_blaze_CppCompileInfo_descriptor;
  }

  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.devtools.build.lib.actions.extra.ExtraActionsBase.internal_static_blaze_CppCompileInfo_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.devtools.build.lib.actions.extra.CppCompileInfo.class, com.google.devtools.build.lib.actions.extra.CppCompileInfo.Builder.class);
  }

  private int bitField0_;
  public static final int TOOL_FIELD_NUMBER = 1;
  private volatile java.lang.Object tool_;
  /**
   * <code>optional string tool = 1;</code>
   */
  public boolean hasTool() {
    return ((bitField0_ & 0x00000001) == 0x00000001);
  }
  /**
   * <code>optional string tool = 1;</code>
   */
  public java.lang.String getTool() {
    java.lang.Object ref = tool_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.google.protobuf.ByteString bs = 
          (com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      if (bs.isValidUtf8()) {
        tool_ = s;
      }
      return s;
    }
  }
  /**
   * <code>optional string tool = 1;</code>
   */
  public com.google.protobuf.ByteString
      getToolBytes() {
    java.lang.Object ref = tool_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      tool_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int COMPILER_OPTION_FIELD_NUMBER = 2;
  private com.google.protobuf.LazyStringList compilerOption_;
  /**
   * <code>repeated string compiler_option = 2;</code>
   */
  public com.google.protobuf.ProtocolStringList
      getCompilerOptionList() {
    return compilerOption_;
  }
  /**
   * <code>repeated string compiler_option = 2;</code>
   */
  public int getCompilerOptionCount() {
    return compilerOption_.size();
  }
  /**
   * <code>repeated string compiler_option = 2;</code>
   */
  public java.lang.String getCompilerOption(int index) {
    return compilerOption_.get(index);
  }
  /**
   * <code>repeated string compiler_option = 2;</code>
   */
  public com.google.protobuf.ByteString
      getCompilerOptionBytes(int index) {
    return compilerOption_.getByteString(index);
  }

  public static final int SOURCE_FILE_FIELD_NUMBER = 3;
  private volatile java.lang.Object sourceFile_;
  /**
   * <code>optional string source_file = 3;</code>
   */
  public boolean hasSourceFile() {
    return ((bitField0_ & 0x00000002) == 0x00000002);
  }
  /**
   * <code>optional string source_file = 3;</code>
   */
  public java.lang.String getSourceFile() {
    java.lang.Object ref = sourceFile_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.google.protobuf.ByteString bs = 
          (com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      if (bs.isValidUtf8()) {
        sourceFile_ = s;
      }
      return s;
    }
  }
  /**
   * <code>optional string source_file = 3;</code>
   */
  public com.google.protobuf.ByteString
      getSourceFileBytes() {
    java.lang.Object ref = sourceFile_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      sourceFile_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int OUTPUT_FILE_FIELD_NUMBER = 4;
  private volatile java.lang.Object outputFile_;
  /**
   * <code>optional string output_file = 4;</code>
   */
  public boolean hasOutputFile() {
    return ((bitField0_ & 0x00000004) == 0x00000004);
  }
  /**
   * <code>optional string output_file = 4;</code>
   */
  public java.lang.String getOutputFile() {
    java.lang.Object ref = outputFile_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.google.protobuf.ByteString bs = 
          (com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      if (bs.isValidUtf8()) {
        outputFile_ = s;
      }
      return s;
    }
  }
  /**
   * <code>optional string output_file = 4;</code>
   */
  public com.google.protobuf.ByteString
      getOutputFileBytes() {
    java.lang.Object ref = outputFile_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      outputFile_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SOURCES_AND_HEADERS_FIELD_NUMBER = 5;
  private com.google.protobuf.LazyStringList sourcesAndHeaders_;
  /**
   * <pre>
   * Due to header discovery, this won't include headers unless the build is
   * actually performed. If set, this field will include the value of
   * "source_file" in addition to the headers.
   * </pre>
   *
   * <code>repeated string sources_and_headers = 5;</code>
   */
  public com.google.protobuf.ProtocolStringList
      getSourcesAndHeadersList() {
    return sourcesAndHeaders_;
  }
  /**
   * <pre>
   * Due to header discovery, this won't include headers unless the build is
   * actually performed. If set, this field will include the value of
   * "source_file" in addition to the headers.
   * </pre>
   *
   * <code>repeated string sources_and_headers = 5;</code>
   */
  public int getSourcesAndHeadersCount() {
    return sourcesAndHeaders_.size();
  }
  /**
   * <pre>
   * Due to header discovery, this won't include headers unless the build is
   * actually performed. If set, this field will include the value of
   * "source_file" in addition to the headers.
   * </pre>
   *
   * <code>repeated string sources_and_headers = 5;</code>
   */
  public java.lang.String getSourcesAndHeaders(int index) {
    return sourcesAndHeaders_.get(index);
  }
  /**
   * <pre>
   * Due to header discovery, this won't include headers unless the build is
   * actually performed. If set, this field will include the value of
   * "source_file" in addition to the headers.
   * </pre>
   *
   * <code>repeated string sources_and_headers = 5;</code>
   */
  public com.google.protobuf.ByteString
      getSourcesAndHeadersBytes(int index) {
    return sourcesAndHeaders_.getByteString(index);
  }

  private byte memoizedIsInitialized = -1;
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (((bitField0_ & 0x00000001) == 0x00000001)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 1, tool_);
    }
    for (int i = 0; i < compilerOption_.size(); i++) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 2, compilerOption_.getRaw(i));
    }
    if (((bitField0_ & 0x00000002) == 0x00000002)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 3, sourceFile_);
    }
    if (((bitField0_ & 0x00000004) == 0x00000004)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 4, outputFile_);
    }
    for (int i = 0; i < sourcesAndHeaders_.size(); i++) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 5, sourcesAndHeaders_.getRaw(i));
    }
    unknownFields.writeTo(output);
  }

  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (((bitField0_ & 0x00000001) == 0x00000001)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, tool_);
    }
    {
      int dataSize = 0;
      for (int i = 0; i < compilerOption_.size(); i++) {
        dataSize += computeStringSizeNoTag(compilerOption_.getRaw(i));
      }
      size += dataSize;
      size += 1 * getCompilerOptionList().size();
    }
    if (((bitField0_ & 0x00000002) == 0x00000002)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, sourceFile_);
    }
    if (((bitField0_ & 0x00000004) == 0x00000004)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, outputFile_);
    }
    {
      int dataSize = 0;
      for (int i = 0; i < sourcesAndHeaders_.size(); i++) {
        dataSize += computeStringSizeNoTag(sourcesAndHeaders_.getRaw(i));
      }
      size += dataSize;
      size += 1 * getSourcesAndHeadersList().size();
    }
    size += unknownFields.getSerializedSize();
    memoizedSize = size;
    return size;
  }

  private static final long serialVersionUID = 0L;
  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof com.google.devtools.build.lib.actions.extra.CppCompileInfo)) {
      return super.equals(obj);
    }
    com.google.devtools.build.lib.actions.extra.CppCompileInfo other = (com.google.devtools.build.lib.actions.extra.CppCompileInfo) obj;

    boolean result = true;
    result = result && (hasTool() == other.hasTool());
    if (hasTool()) {
      result = result && getTool()
          .equals(other.getTool());
    }
    result = result && getCompilerOptionList()
        .equals(other.getCompilerOptionList());
    result = result && (hasSourceFile() == other.hasSourceFile());
    if (hasSourceFile()) {
      result = result && getSourceFile()
          .equals(other.getSourceFile());
    }
    result = result && (hasOutputFile() == other.hasOutputFile());
    if (hasOutputFile()) {
      result = result && getOutputFile()
          .equals(other.getOutputFile());
    }
    result = result && getSourcesAndHeadersList()
        .equals(other.getSourcesAndHeadersList());
    result = result && unknownFields.equals(other.unknownFields);
    return result;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptorForType().hashCode();
    if (hasTool()) {
      hash = (37 * hash) + TOOL_FIELD_NUMBER;
      hash = (53 * hash) + getTool().hashCode();
    }
    if (getCompilerOptionCount() > 0) {
      hash = (37 * hash) + COMPILER_OPTION_FIELD_NUMBER;
      hash = (53 * hash) + getCompilerOptionList().hashCode();
    }
    if (hasSourceFile()) {
      hash = (37 * hash) + SOURCE_FILE_FIELD_NUMBER;
      hash = (53 * hash) + getSourceFile().hashCode();
    }
    if (hasOutputFile()) {
      hash = (37 * hash) + OUTPUT_FILE_FIELD_NUMBER;
      hash = (53 * hash) + getOutputFile().hashCode();
    }
    if (getSourcesAndHeadersCount() > 0) {
      hash = (37 * hash) + SOURCES_AND_HEADERS_FIELD_NUMBER;
      hash = (53 * hash) + getSourcesAndHeadersList().hashCode();
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(com.google.devtools.build.lib.actions.extra.CppCompileInfo prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * <pre>
   * Provides access to data that is specific to C++ compile actions.
   * Usually provided by actions using the "CppCompile" Mnemonic.
   * </pre>
   *
   * Protobuf type {@code blaze.CppCompileInfo}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:blaze.CppCompileInfo)
      com.google.devtools.build.lib.actions.extra.CppCompileInfoOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.devtools.build.lib.actions.extra.ExtraActionsBase.internal_static_blaze_CppCompileInfo_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.devtools.build.lib.actions.extra.ExtraActionsBase.internal_static_blaze_CppCompileInfo_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.devtools.build.lib.actions.extra.CppCompileInfo.class, com.google.devtools.build.lib.actions.extra.CppCompileInfo.Builder.class);
    }

    // Construct using com.google.devtools.build.lib.actions.extra.CppCompileInfo.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
      }
    }
    public Builder clear() {
      super.clear();
      tool_ = "";
      bitField0_ = (bitField0_ & ~0x00000001);
      compilerOption_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000002);
      sourceFile_ = "";
      bitField0_ = (bitField0_ & ~0x00000004);
      outputFile_ = "";
      bitField0_ = (bitField0_ & ~0x00000008);
      sourcesAndHeaders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000010);
      return this;
    }

    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.google.devtools.build.lib.actions.extra.ExtraActionsBase.internal_static_blaze_CppCompileInfo_descriptor;
    }

    public com.google.devtools.build.lib.actions.extra.CppCompileInfo getDefaultInstanceForType() {
      return com.google.devtools.build.lib.actions.extra.CppCompileInfo.getDefaultInstance();
    }

    public com.google.devtools.build.lib.actions.extra.CppCompileInfo build() {
      com.google.devtools.build.lib.actions.extra.CppCompileInfo result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public com.google.devtools.build.lib.actions.extra.CppCompileInfo buildPartial() {
      com.google.devtools.build.lib.actions.extra.CppCompileInfo result = new com.google.devtools.build.lib.actions.extra.CppCompileInfo(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
        to_bitField0_ |= 0x00000001;
      }
      result.tool_ = tool_;
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        compilerOption_ = compilerOption_.getUnmodifiableView();
        bitField0_ = (bitField0_ & ~0x00000002);
      }
      result.compilerOption_ = compilerOption_;
      if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
        to_bitField0_ |= 0x00000002;
      }
      result.sourceFile_ = sourceFile_;
      if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
        to_bitField0_ |= 0x00000004;
      }
      result.outputFile_ = outputFile_;
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        sourcesAndHeaders_ = sourcesAndHeaders_.getUnmodifiableView();
        bitField0_ = (bitField0_ & ~0x00000010);
      }
      result.sourcesAndHeaders_ = sourcesAndHeaders_;
      result.bitField0_ = to_bitField0_;
      onBuilt();
      return result;
    }

    public Builder clone() {
      return (Builder) super.clone();
    }
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        Object value) {
      return (Builder) super.setField(field, value);
    }
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return (Builder) super.clearField(field);
    }
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return (Builder) super.clearOneof(oneof);
    }
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, Object value) {
      return (Builder) super.setRepeatedField(field, index, value);
    }
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        Object value) {
      return (Builder) super.addRepeatedField(field, value);
    }
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.google.devtools.build.lib.actions.extra.CppCompileInfo) {
        return mergeFrom((com.google.devtools.build.lib.actions.extra.CppCompileInfo)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.devtools.build.lib.actions.extra.CppCompileInfo other) {
      if (other == com.google.devtools.build.lib.actions.extra.CppCompileInfo.getDefaultInstance()) return this;
      if (other.hasTool()) {
        bitField0_ |= 0x00000001;
        tool_ = other.tool_;
        onChanged();
      }
      if (!other.compilerOption_.isEmpty()) {
        if (compilerOption_.isEmpty()) {
          compilerOption_ = other.compilerOption_;
          bitField0_ = (bitField0_ & ~0x00000002);
        } else {
          ensureCompilerOptionIsMutable();
          compilerOption_.addAll(other.compilerOption_);
        }
        onChanged();
      }
      if (other.hasSourceFile()) {
        bitField0_ |= 0x00000004;
        sourceFile_ = other.sourceFile_;
        onChanged();
      }
      if (other.hasOutputFile()) {
        bitField0_ |= 0x00000008;
        outputFile_ = other.outputFile_;
        onChanged();
      }
      if (!other.sourcesAndHeaders_.isEmpty()) {
        if (sourcesAndHeaders_.isEmpty()) {
          sourcesAndHeaders_ = other.sourcesAndHeaders_;
          bitField0_ = (bitField0_ & ~0x00000010);
        } else {
          ensureSourcesAndHeadersIsMutable();
          sourcesAndHeaders_.addAll(other.sourcesAndHeaders_);
        }
        onChanged();
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

    public final boolean isInitialized() {
      return true;
    }

    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.google.devtools.build.lib.actions.extra.CppCompileInfo parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.google.devtools.build.lib.actions.extra.CppCompileInfo) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int bitField0_;

    private java.lang.Object tool_ = "";
    /**
     * <code>optional string tool = 1;</code>
     */
    public boolean hasTool() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>optional string tool = 1;</code>
     */
    public java.lang.String getTool() {
      java.lang.Object ref = tool_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          tool_ = s;
        }
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <code>optional string tool = 1;</code>
     */
    public com.google.protobuf.ByteString
        getToolBytes() {
      java.lang.Object ref = tool_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        tool_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <code>optional string tool = 1;</code>
     */
    public Builder setTool(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
      tool_ = value;
      onChanged();
      return this;
    }
    /**
     * <code>optional string tool = 1;</code>
     */
    public Builder clearTool() {
      bitField0_ = (bitField0_ & ~0x00000001);
      tool_ = getDefaultInstance().getTool();
      onChanged();
      return this;
    }
    /**
     * <code>optional string tool = 1;</code>
     */
    public Builder setToolBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
      tool_ = value;
      onChanged();
      return this;
    }

    private com.google.protobuf.LazyStringList compilerOption_ = com.google.protobuf.LazyStringArrayList.EMPTY;
    private void ensureCompilerOptionIsMutable() {
      if (!((bitField0_ & 0x00000002) == 0x00000002)) {
        compilerOption_ = new com.google.protobuf.LazyStringArrayList(compilerOption_);
        bitField0_ |= 0x00000002;
       }
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public com.google.protobuf.ProtocolStringList
        getCompilerOptionList() {
      return compilerOption_.getUnmodifiableView();
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public int getCompilerOptionCount() {
      return compilerOption_.size();
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public java.lang.String getCompilerOption(int index) {
      return compilerOption_.get(index);
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public com.google.protobuf.ByteString
        getCompilerOptionBytes(int index) {
      return compilerOption_.getByteString(index);
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public Builder setCompilerOption(
        int index, java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureCompilerOptionIsMutable();
      compilerOption_.set(index, value);
      onChanged();
      return this;
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public Builder addCompilerOption(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureCompilerOptionIsMutable();
      compilerOption_.add(value);
      onChanged();
      return this;
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public Builder addAllCompilerOption(
        java.lang.Iterable<java.lang.String> values) {
      ensureCompilerOptionIsMutable();
      com.google.protobuf.AbstractMessageLite.Builder.addAll(
          values, compilerOption_);
      onChanged();
      return this;
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public Builder clearCompilerOption() {
      compilerOption_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000002);
      onChanged();
      return this;
    }
    /**
     * <code>repeated string compiler_option = 2;</code>
     */
    public Builder addCompilerOptionBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureCompilerOptionIsMutable();
      compilerOption_.add(value);
      onChanged();
      return this;
    }

    private java.lang.Object sourceFile_ = "";
    /**
     * <code>optional string source_file = 3;</code>
     */
    public boolean hasSourceFile() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional string source_file = 3;</code>
     */
    public java.lang.String getSourceFile() {
      java.lang.Object ref = sourceFile_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          sourceFile_ = s;
        }
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <code>optional string source_file = 3;</code>
     */
    public com.google.protobuf.ByteString
        getSourceFileBytes() {
      java.lang.Object ref = sourceFile_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        sourceFile_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <code>optional string source_file = 3;</code>
     */
    public Builder setSourceFile(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
      sourceFile_ = value;
      onChanged();
      return this;
    }
    /**
     * <code>optional string source_file = 3;</code>
     */
    public Builder clearSourceFile() {
      bitField0_ = (bitField0_ & ~0x00000004);
      sourceFile_ = getDefaultInstance().getSourceFile();
      onChanged();
      return this;
    }
    /**
     * <code>optional string source_file = 3;</code>
     */
    public Builder setSourceFileBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
      sourceFile_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object outputFile_ = "";
    /**
     * <code>optional string output_file = 4;</code>
     */
    public boolean hasOutputFile() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional string output_file = 4;</code>
     */
    public java.lang.String getOutputFile() {
      java.lang.Object ref = outputFile_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          outputFile_ = s;
        }
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <code>optional string output_file = 4;</code>
     */
    public com.google.protobuf.ByteString
        getOutputFileBytes() {
      java.lang.Object ref = outputFile_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        outputFile_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <code>optional string output_file = 4;</code>
     */
    public Builder setOutputFile(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000008;
      outputFile_ = value;
      onChanged();
      return this;
    }
    /**
     * <code>optional string output_file = 4;</code>
     */
    public Builder clearOutputFile() {
      bitField0_ = (bitField0_ & ~0x00000008);
      outputFile_ = getDefaultInstance().getOutputFile();
      onChanged();
      return this;
    }
    /**
     * <code>optional string output_file = 4;</code>
     */
    public Builder setOutputFileBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000008;
      outputFile_ = value;
      onChanged();
      return this;
    }

    private com.google.protobuf.LazyStringList sourcesAndHeaders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
    private void ensureSourcesAndHeadersIsMutable() {
      if (!((bitField0_ & 0x00000010) == 0x00000010)) {
        sourcesAndHeaders_ = new com.google.protobuf.LazyStringArrayList(sourcesAndHeaders_);
        bitField0_ |= 0x00000010;
       }
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public com.google.protobuf.ProtocolStringList
        getSourcesAndHeadersList() {
      return sourcesAndHeaders_.getUnmodifiableView();
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public int getSourcesAndHeadersCount() {
      return sourcesAndHeaders_.size();
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public java.lang.String getSourcesAndHeaders(int index) {
      return sourcesAndHeaders_.get(index);
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public com.google.protobuf.ByteString
        getSourcesAndHeadersBytes(int index) {
      return sourcesAndHeaders_.getByteString(index);
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public Builder setSourcesAndHeaders(
        int index, java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureSourcesAndHeadersIsMutable();
      sourcesAndHeaders_.set(index, value);
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public Builder addSourcesAndHeaders(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureSourcesAndHeadersIsMutable();
      sourcesAndHeaders_.add(value);
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public Builder addAllSourcesAndHeaders(
        java.lang.Iterable<java.lang.String> values) {
      ensureSourcesAndHeadersIsMutable();
      com.google.protobuf.AbstractMessageLite.Builder.addAll(
          values, sourcesAndHeaders_);
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public Builder clearSourcesAndHeaders() {
      sourcesAndHeaders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      bitField0_ = (bitField0_ & ~0x00000010);
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Due to header discovery, this won't include headers unless the build is
     * actually performed. If set, this field will include the value of
     * "source_file" in addition to the headers.
     * </pre>
     *
     * <code>repeated string sources_and_headers = 5;</code>
     */
    public Builder addSourcesAndHeadersBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  ensureSourcesAndHeadersIsMutable();
      sourcesAndHeaders_.add(value);
      onChanged();
      return this;
    }
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:blaze.CppCompileInfo)
  }

  // @@protoc_insertion_point(class_scope:blaze.CppCompileInfo)
  private static final com.google.devtools.build.lib.actions.extra.CppCompileInfo DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new com.google.devtools.build.lib.actions.extra.CppCompileInfo();
  }

  public static com.google.devtools.build.lib.actions.extra.CppCompileInfo getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  @java.lang.Deprecated public static final com.google.protobuf.Parser<CppCompileInfo>
      PARSER = new com.google.protobuf.AbstractParser<CppCompileInfo>() {
    public CppCompileInfo parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
        return new CppCompileInfo(input, extensionRegistry);
    }
  };

  public static com.google.protobuf.Parser<CppCompileInfo> parser() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.protobuf.Parser<CppCompileInfo> getParserForType() {
    return PARSER;
  }

  public com.google.devtools.build.lib.actions.extra.CppCompileInfo getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

  public static final int CPP_COMPILE_INFO_FIELD_NUMBER = 1001;
  /**
   * <code>extend .blaze.ExtraActionInfo { ... }</code>
   */
  public static final
    com.google.protobuf.GeneratedMessage.GeneratedExtension<
      com.google.devtools.build.lib.actions.extra.ExtraActionInfo,
      com.google.devtools.build.lib.actions.extra.CppCompileInfo> cppCompileInfo = com.google.protobuf.GeneratedMessage
          .newMessageScopedGeneratedExtension(
        com.google.devtools.build.lib.actions.extra.CppCompileInfo.getDefaultInstance(),
        0,
        com.google.devtools.build.lib.actions.extra.CppCompileInfo.class,
        com.google.devtools.build.lib.actions.extra.CppCompileInfo.getDefaultInstance());
}

