// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/cloud/videointelligence/v1beta1/video_intelligence.proto

package com.google.cloud.videointelligence.v1beta1;

/**
 * <pre>
 * Face annotation.
 * </pre>
 *
 * Protobuf type {@code google.cloud.videointelligence.v1beta1.FaceAnnotation}
 */
public  final class FaceAnnotation extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:google.cloud.videointelligence.v1beta1.FaceAnnotation)
    FaceAnnotationOrBuilder {
private static final long serialVersionUID = 0L;
  // Use FaceAnnotation.newBuilder() to construct.
  private FaceAnnotation(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private FaceAnnotation() {
    thumbnail_ = "";
    segments_ = java.util.Collections.emptyList();
    locations_ = java.util.Collections.emptyList();
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private FaceAnnotation(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    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 (!parseUnknownFieldProto3(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
          case 10: {
            java.lang.String s = input.readStringRequireUtf8();

            thumbnail_ = s;
            break;
          }
          case 18: {
            if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
              segments_ = new java.util.ArrayList<com.google.cloud.videointelligence.v1beta1.VideoSegment>();
              mutable_bitField0_ |= 0x00000002;
            }
            segments_.add(
                input.readMessage(com.google.cloud.videointelligence.v1beta1.VideoSegment.parser(), extensionRegistry));
            break;
          }
          case 26: {
            if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
              locations_ = new java.util.ArrayList<com.google.cloud.videointelligence.v1beta1.FaceLocation>();
              mutable_bitField0_ |= 0x00000004;
            }
            locations_.add(
                input.readMessage(com.google.cloud.videointelligence.v1beta1.FaceLocation.parser(), extensionRegistry));
            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)) {
        segments_ = java.util.Collections.unmodifiableList(segments_);
      }
      if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
        locations_ = java.util.Collections.unmodifiableList(locations_);
      }
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.google.cloud.videointelligence.v1beta1.VideoIntelligenceServiceProto.internal_static_google_cloud_videointelligence_v1beta1_FaceAnnotation_descriptor;
  }

  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.cloud.videointelligence.v1beta1.VideoIntelligenceServiceProto.internal_static_google_cloud_videointelligence_v1beta1_FaceAnnotation_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.cloud.videointelligence.v1beta1.FaceAnnotation.class, com.google.cloud.videointelligence.v1beta1.FaceAnnotation.Builder.class);
  }

  private int bitField0_;
  public static final int THUMBNAIL_FIELD_NUMBER = 1;
  private volatile java.lang.Object thumbnail_;
  /**
   * <pre>
   * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
   * </pre>
   *
   * <code>string thumbnail = 1;</code>
   */
  public java.lang.String getThumbnail() {
    java.lang.Object ref = thumbnail_;
    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();
      thumbnail_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
   * </pre>
   *
   * <code>string thumbnail = 1;</code>
   */
  public com.google.protobuf.ByteString
      getThumbnailBytes() {
    java.lang.Object ref = thumbnail_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      thumbnail_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SEGMENTS_FIELD_NUMBER = 2;
  private java.util.List<com.google.cloud.videointelligence.v1beta1.VideoSegment> segments_;
  /**
   * <pre>
   * All locations where a face was detected.
   * Faces are detected and tracked on a per-video basis
   * (as opposed to across multiple videos).
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
   */
  public java.util.List<com.google.cloud.videointelligence.v1beta1.VideoSegment> getSegmentsList() {
    return segments_;
  }
  /**
   * <pre>
   * All locations where a face was detected.
   * Faces are detected and tracked on a per-video basis
   * (as opposed to across multiple videos).
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
   */
  public java.util.List<? extends com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder> 
      getSegmentsOrBuilderList() {
    return segments_;
  }
  /**
   * <pre>
   * All locations where a face was detected.
   * Faces are detected and tracked on a per-video basis
   * (as opposed to across multiple videos).
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
   */
  public int getSegmentsCount() {
    return segments_.size();
  }
  /**
   * <pre>
   * All locations where a face was detected.
   * Faces are detected and tracked on a per-video basis
   * (as opposed to across multiple videos).
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
   */
  public com.google.cloud.videointelligence.v1beta1.VideoSegment getSegments(int index) {
    return segments_.get(index);
  }
  /**
   * <pre>
   * All locations where a face was detected.
   * Faces are detected and tracked on a per-video basis
   * (as opposed to across multiple videos).
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
   */
  public com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder getSegmentsOrBuilder(
      int index) {
    return segments_.get(index);
  }

  public static final int LOCATIONS_FIELD_NUMBER = 3;
  private java.util.List<com.google.cloud.videointelligence.v1beta1.FaceLocation> locations_;
  /**
   * <pre>
   * Face locations at one frame per second.
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
   */
  public java.util.List<com.google.cloud.videointelligence.v1beta1.FaceLocation> getLocationsList() {
    return locations_;
  }
  /**
   * <pre>
   * Face locations at one frame per second.
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
   */
  public java.util.List<? extends com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder> 
      getLocationsOrBuilderList() {
    return locations_;
  }
  /**
   * <pre>
   * Face locations at one frame per second.
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
   */
  public int getLocationsCount() {
    return locations_.size();
  }
  /**
   * <pre>
   * Face locations at one frame per second.
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
   */
  public com.google.cloud.videointelligence.v1beta1.FaceLocation getLocations(int index) {
    return locations_.get(index);
  }
  /**
   * <pre>
   * Face locations at one frame per second.
   * </pre>
   *
   * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
   */
  public com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder getLocationsOrBuilder(
      int index) {
    return locations_.get(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 (!getThumbnailBytes().isEmpty()) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 1, thumbnail_);
    }
    for (int i = 0; i < segments_.size(); i++) {
      output.writeMessage(2, segments_.get(i));
    }
    for (int i = 0; i < locations_.size(); i++) {
      output.writeMessage(3, locations_.get(i));
    }
    unknownFields.writeTo(output);
  }

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

    size = 0;
    if (!getThumbnailBytes().isEmpty()) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, thumbnail_);
    }
    for (int i = 0; i < segments_.size(); i++) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(2, segments_.get(i));
    }
    for (int i = 0; i < locations_.size(); i++) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(3, locations_.get(i));
    }
    size += unknownFields.getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof com.google.cloud.videointelligence.v1beta1.FaceAnnotation)) {
      return super.equals(obj);
    }
    com.google.cloud.videointelligence.v1beta1.FaceAnnotation other = (com.google.cloud.videointelligence.v1beta1.FaceAnnotation) obj;

    boolean result = true;
    result = result && getThumbnail()
        .equals(other.getThumbnail());
    result = result && getSegmentsList()
        .equals(other.getSegmentsList());
    result = result && getLocationsList()
        .equals(other.getLocationsList());
    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) + getDescriptor().hashCode();
    hash = (37 * hash) + THUMBNAIL_FIELD_NUMBER;
    hash = (53 * hash) + getThumbnail().hashCode();
    if (getSegmentsCount() > 0) {
      hash = (37 * hash) + SEGMENTS_FIELD_NUMBER;
      hash = (53 * hash) + getSegmentsList().hashCode();
    }
    if (getLocationsCount() > 0) {
      hash = (37 * hash) + LOCATIONS_FIELD_NUMBER;
      hash = (53 * hash) + getLocationsList().hashCode();
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation 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.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation 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.cloud.videointelligence.v1beta1.FaceAnnotation parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation 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.cloud.videointelligence.v1beta1.FaceAnnotation parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation 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.cloud.videointelligence.v1beta1.FaceAnnotation 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>
   * Face annotation.
   * </pre>
   *
   * Protobuf type {@code google.cloud.videointelligence.v1beta1.FaceAnnotation}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:google.cloud.videointelligence.v1beta1.FaceAnnotation)
      com.google.cloud.videointelligence.v1beta1.FaceAnnotationOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.cloud.videointelligence.v1beta1.VideoIntelligenceServiceProto.internal_static_google_cloud_videointelligence_v1beta1_FaceAnnotation_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.cloud.videointelligence.v1beta1.VideoIntelligenceServiceProto.internal_static_google_cloud_videointelligence_v1beta1_FaceAnnotation_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.cloud.videointelligence.v1beta1.FaceAnnotation.class, com.google.cloud.videointelligence.v1beta1.FaceAnnotation.Builder.class);
    }

    // Construct using com.google.cloud.videointelligence.v1beta1.FaceAnnotation.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
        getSegmentsFieldBuilder();
        getLocationsFieldBuilder();
      }
    }
    public Builder clear() {
      super.clear();
      thumbnail_ = "";

      if (segmentsBuilder_ == null) {
        segments_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000002);
      } else {
        segmentsBuilder_.clear();
      }
      if (locationsBuilder_ == null) {
        locations_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000004);
      } else {
        locationsBuilder_.clear();
      }
      return this;
    }

    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.google.cloud.videointelligence.v1beta1.VideoIntelligenceServiceProto.internal_static_google_cloud_videointelligence_v1beta1_FaceAnnotation_descriptor;
    }

    public com.google.cloud.videointelligence.v1beta1.FaceAnnotation getDefaultInstanceForType() {
      return com.google.cloud.videointelligence.v1beta1.FaceAnnotation.getDefaultInstance();
    }

    public com.google.cloud.videointelligence.v1beta1.FaceAnnotation build() {
      com.google.cloud.videointelligence.v1beta1.FaceAnnotation result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public com.google.cloud.videointelligence.v1beta1.FaceAnnotation buildPartial() {
      com.google.cloud.videointelligence.v1beta1.FaceAnnotation result = new com.google.cloud.videointelligence.v1beta1.FaceAnnotation(this);
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      result.thumbnail_ = thumbnail_;
      if (segmentsBuilder_ == null) {
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          segments_ = java.util.Collections.unmodifiableList(segments_);
          bitField0_ = (bitField0_ & ~0x00000002);
        }
        result.segments_ = segments_;
      } else {
        result.segments_ = segmentsBuilder_.build();
      }
      if (locationsBuilder_ == null) {
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          locations_ = java.util.Collections.unmodifiableList(locations_);
          bitField0_ = (bitField0_ & ~0x00000004);
        }
        result.locations_ = locations_;
      } else {
        result.locations_ = locationsBuilder_.build();
      }
      result.bitField0_ = to_bitField0_;
      onBuilt();
      return result;
    }

    public Builder clone() {
      return (Builder) super.clone();
    }
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.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, java.lang.Object value) {
      return (Builder) super.setRepeatedField(field, index, value);
    }
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return (Builder) super.addRepeatedField(field, value);
    }
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.google.cloud.videointelligence.v1beta1.FaceAnnotation) {
        return mergeFrom((com.google.cloud.videointelligence.v1beta1.FaceAnnotation)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.cloud.videointelligence.v1beta1.FaceAnnotation other) {
      if (other == com.google.cloud.videointelligence.v1beta1.FaceAnnotation.getDefaultInstance()) return this;
      if (!other.getThumbnail().isEmpty()) {
        thumbnail_ = other.thumbnail_;
        onChanged();
      }
      if (segmentsBuilder_ == null) {
        if (!other.segments_.isEmpty()) {
          if (segments_.isEmpty()) {
            segments_ = other.segments_;
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            ensureSegmentsIsMutable();
            segments_.addAll(other.segments_);
          }
          onChanged();
        }
      } else {
        if (!other.segments_.isEmpty()) {
          if (segmentsBuilder_.isEmpty()) {
            segmentsBuilder_.dispose();
            segmentsBuilder_ = null;
            segments_ = other.segments_;
            bitField0_ = (bitField0_ & ~0x00000002);
            segmentsBuilder_ = 
              com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                 getSegmentsFieldBuilder() : null;
          } else {
            segmentsBuilder_.addAllMessages(other.segments_);
          }
        }
      }
      if (locationsBuilder_ == null) {
        if (!other.locations_.isEmpty()) {
          if (locations_.isEmpty()) {
            locations_ = other.locations_;
            bitField0_ = (bitField0_ & ~0x00000004);
          } else {
            ensureLocationsIsMutable();
            locations_.addAll(other.locations_);
          }
          onChanged();
        }
      } else {
        if (!other.locations_.isEmpty()) {
          if (locationsBuilder_.isEmpty()) {
            locationsBuilder_.dispose();
            locationsBuilder_ = null;
            locations_ = other.locations_;
            bitField0_ = (bitField0_ & ~0x00000004);
            locationsBuilder_ = 
              com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                 getLocationsFieldBuilder() : null;
          } else {
            locationsBuilder_.addAllMessages(other.locations_);
          }
        }
      }
      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.cloud.videointelligence.v1beta1.FaceAnnotation parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.google.cloud.videointelligence.v1beta1.FaceAnnotation) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int bitField0_;

    private java.lang.Object thumbnail_ = "";
    /**
     * <pre>
     * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
     * </pre>
     *
     * <code>string thumbnail = 1;</code>
     */
    public java.lang.String getThumbnail() {
      java.lang.Object ref = thumbnail_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        thumbnail_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
     * </pre>
     *
     * <code>string thumbnail = 1;</code>
     */
    public com.google.protobuf.ByteString
        getThumbnailBytes() {
      java.lang.Object ref = thumbnail_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        thumbnail_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
     * </pre>
     *
     * <code>string thumbnail = 1;</code>
     */
    public Builder setThumbnail(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      thumbnail_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
     * </pre>
     *
     * <code>string thumbnail = 1;</code>
     */
    public Builder clearThumbnail() {
      
      thumbnail_ = getDefaultInstance().getThumbnail();
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Thumbnail of a representative face view (in JPEG format). Encoding: base64.
     * </pre>
     *
     * <code>string thumbnail = 1;</code>
     */
    public Builder setThumbnailBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      thumbnail_ = value;
      onChanged();
      return this;
    }

    private java.util.List<com.google.cloud.videointelligence.v1beta1.VideoSegment> segments_ =
      java.util.Collections.emptyList();
    private void ensureSegmentsIsMutable() {
      if (!((bitField0_ & 0x00000002) == 0x00000002)) {
        segments_ = new java.util.ArrayList<com.google.cloud.videointelligence.v1beta1.VideoSegment>(segments_);
        bitField0_ |= 0x00000002;
       }
    }

    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.cloud.videointelligence.v1beta1.VideoSegment, com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder, com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder> segmentsBuilder_;

    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public java.util.List<com.google.cloud.videointelligence.v1beta1.VideoSegment> getSegmentsList() {
      if (segmentsBuilder_ == null) {
        return java.util.Collections.unmodifiableList(segments_);
      } else {
        return segmentsBuilder_.getMessageList();
      }
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public int getSegmentsCount() {
      if (segmentsBuilder_ == null) {
        return segments_.size();
      } else {
        return segmentsBuilder_.getCount();
      }
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.VideoSegment getSegments(int index) {
      if (segmentsBuilder_ == null) {
        return segments_.get(index);
      } else {
        return segmentsBuilder_.getMessage(index);
      }
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder setSegments(
        int index, com.google.cloud.videointelligence.v1beta1.VideoSegment value) {
      if (segmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureSegmentsIsMutable();
        segments_.set(index, value);
        onChanged();
      } else {
        segmentsBuilder_.setMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder setSegments(
        int index, com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder builderForValue) {
      if (segmentsBuilder_ == null) {
        ensureSegmentsIsMutable();
        segments_.set(index, builderForValue.build());
        onChanged();
      } else {
        segmentsBuilder_.setMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder addSegments(com.google.cloud.videointelligence.v1beta1.VideoSegment value) {
      if (segmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureSegmentsIsMutable();
        segments_.add(value);
        onChanged();
      } else {
        segmentsBuilder_.addMessage(value);
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder addSegments(
        int index, com.google.cloud.videointelligence.v1beta1.VideoSegment value) {
      if (segmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureSegmentsIsMutable();
        segments_.add(index, value);
        onChanged();
      } else {
        segmentsBuilder_.addMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder addSegments(
        com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder builderForValue) {
      if (segmentsBuilder_ == null) {
        ensureSegmentsIsMutable();
        segments_.add(builderForValue.build());
        onChanged();
      } else {
        segmentsBuilder_.addMessage(builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder addSegments(
        int index, com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder builderForValue) {
      if (segmentsBuilder_ == null) {
        ensureSegmentsIsMutable();
        segments_.add(index, builderForValue.build());
        onChanged();
      } else {
        segmentsBuilder_.addMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder addAllSegments(
        java.lang.Iterable<? extends com.google.cloud.videointelligence.v1beta1.VideoSegment> values) {
      if (segmentsBuilder_ == null) {
        ensureSegmentsIsMutable();
        com.google.protobuf.AbstractMessageLite.Builder.addAll(
            values, segments_);
        onChanged();
      } else {
        segmentsBuilder_.addAllMessages(values);
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder clearSegments() {
      if (segmentsBuilder_ == null) {
        segments_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000002);
        onChanged();
      } else {
        segmentsBuilder_.clear();
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public Builder removeSegments(int index) {
      if (segmentsBuilder_ == null) {
        ensureSegmentsIsMutable();
        segments_.remove(index);
        onChanged();
      } else {
        segmentsBuilder_.remove(index);
      }
      return this;
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder getSegmentsBuilder(
        int index) {
      return getSegmentsFieldBuilder().getBuilder(index);
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder getSegmentsOrBuilder(
        int index) {
      if (segmentsBuilder_ == null) {
        return segments_.get(index);  } else {
        return segmentsBuilder_.getMessageOrBuilder(index);
      }
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public java.util.List<? extends com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder> 
         getSegmentsOrBuilderList() {
      if (segmentsBuilder_ != null) {
        return segmentsBuilder_.getMessageOrBuilderList();
      } else {
        return java.util.Collections.unmodifiableList(segments_);
      }
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder addSegmentsBuilder() {
      return getSegmentsFieldBuilder().addBuilder(
          com.google.cloud.videointelligence.v1beta1.VideoSegment.getDefaultInstance());
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder addSegmentsBuilder(
        int index) {
      return getSegmentsFieldBuilder().addBuilder(
          index, com.google.cloud.videointelligence.v1beta1.VideoSegment.getDefaultInstance());
    }
    /**
     * <pre>
     * All locations where a face was detected.
     * Faces are detected and tracked on a per-video basis
     * (as opposed to across multiple videos).
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.VideoSegment segments = 2;</code>
     */
    public java.util.List<com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder> 
         getSegmentsBuilderList() {
      return getSegmentsFieldBuilder().getBuilderList();
    }
    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.cloud.videointelligence.v1beta1.VideoSegment, com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder, com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder> 
        getSegmentsFieldBuilder() {
      if (segmentsBuilder_ == null) {
        segmentsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
            com.google.cloud.videointelligence.v1beta1.VideoSegment, com.google.cloud.videointelligence.v1beta1.VideoSegment.Builder, com.google.cloud.videointelligence.v1beta1.VideoSegmentOrBuilder>(
                segments_,
                ((bitField0_ & 0x00000002) == 0x00000002),
                getParentForChildren(),
                isClean());
        segments_ = null;
      }
      return segmentsBuilder_;
    }

    private java.util.List<com.google.cloud.videointelligence.v1beta1.FaceLocation> locations_ =
      java.util.Collections.emptyList();
    private void ensureLocationsIsMutable() {
      if (!((bitField0_ & 0x00000004) == 0x00000004)) {
        locations_ = new java.util.ArrayList<com.google.cloud.videointelligence.v1beta1.FaceLocation>(locations_);
        bitField0_ |= 0x00000004;
       }
    }

    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.cloud.videointelligence.v1beta1.FaceLocation, com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder, com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder> locationsBuilder_;

    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public java.util.List<com.google.cloud.videointelligence.v1beta1.FaceLocation> getLocationsList() {
      if (locationsBuilder_ == null) {
        return java.util.Collections.unmodifiableList(locations_);
      } else {
        return locationsBuilder_.getMessageList();
      }
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public int getLocationsCount() {
      if (locationsBuilder_ == null) {
        return locations_.size();
      } else {
        return locationsBuilder_.getCount();
      }
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.FaceLocation getLocations(int index) {
      if (locationsBuilder_ == null) {
        return locations_.get(index);
      } else {
        return locationsBuilder_.getMessage(index);
      }
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder setLocations(
        int index, com.google.cloud.videointelligence.v1beta1.FaceLocation value) {
      if (locationsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureLocationsIsMutable();
        locations_.set(index, value);
        onChanged();
      } else {
        locationsBuilder_.setMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder setLocations(
        int index, com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder builderForValue) {
      if (locationsBuilder_ == null) {
        ensureLocationsIsMutable();
        locations_.set(index, builderForValue.build());
        onChanged();
      } else {
        locationsBuilder_.setMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder addLocations(com.google.cloud.videointelligence.v1beta1.FaceLocation value) {
      if (locationsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureLocationsIsMutable();
        locations_.add(value);
        onChanged();
      } else {
        locationsBuilder_.addMessage(value);
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder addLocations(
        int index, com.google.cloud.videointelligence.v1beta1.FaceLocation value) {
      if (locationsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureLocationsIsMutable();
        locations_.add(index, value);
        onChanged();
      } else {
        locationsBuilder_.addMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder addLocations(
        com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder builderForValue) {
      if (locationsBuilder_ == null) {
        ensureLocationsIsMutable();
        locations_.add(builderForValue.build());
        onChanged();
      } else {
        locationsBuilder_.addMessage(builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder addLocations(
        int index, com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder builderForValue) {
      if (locationsBuilder_ == null) {
        ensureLocationsIsMutable();
        locations_.add(index, builderForValue.build());
        onChanged();
      } else {
        locationsBuilder_.addMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder addAllLocations(
        java.lang.Iterable<? extends com.google.cloud.videointelligence.v1beta1.FaceLocation> values) {
      if (locationsBuilder_ == null) {
        ensureLocationsIsMutable();
        com.google.protobuf.AbstractMessageLite.Builder.addAll(
            values, locations_);
        onChanged();
      } else {
        locationsBuilder_.addAllMessages(values);
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder clearLocations() {
      if (locationsBuilder_ == null) {
        locations_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000004);
        onChanged();
      } else {
        locationsBuilder_.clear();
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public Builder removeLocations(int index) {
      if (locationsBuilder_ == null) {
        ensureLocationsIsMutable();
        locations_.remove(index);
        onChanged();
      } else {
        locationsBuilder_.remove(index);
      }
      return this;
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder getLocationsBuilder(
        int index) {
      return getLocationsFieldBuilder().getBuilder(index);
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder getLocationsOrBuilder(
        int index) {
      if (locationsBuilder_ == null) {
        return locations_.get(index);  } else {
        return locationsBuilder_.getMessageOrBuilder(index);
      }
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public java.util.List<? extends com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder> 
         getLocationsOrBuilderList() {
      if (locationsBuilder_ != null) {
        return locationsBuilder_.getMessageOrBuilderList();
      } else {
        return java.util.Collections.unmodifiableList(locations_);
      }
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder addLocationsBuilder() {
      return getLocationsFieldBuilder().addBuilder(
          com.google.cloud.videointelligence.v1beta1.FaceLocation.getDefaultInstance());
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder addLocationsBuilder(
        int index) {
      return getLocationsFieldBuilder().addBuilder(
          index, com.google.cloud.videointelligence.v1beta1.FaceLocation.getDefaultInstance());
    }
    /**
     * <pre>
     * Face locations at one frame per second.
     * </pre>
     *
     * <code>repeated .google.cloud.videointelligence.v1beta1.FaceLocation locations = 3;</code>
     */
    public java.util.List<com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder> 
         getLocationsBuilderList() {
      return getLocationsFieldBuilder().getBuilderList();
    }
    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.cloud.videointelligence.v1beta1.FaceLocation, com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder, com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder> 
        getLocationsFieldBuilder() {
      if (locationsBuilder_ == null) {
        locationsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
            com.google.cloud.videointelligence.v1beta1.FaceLocation, com.google.cloud.videointelligence.v1beta1.FaceLocation.Builder, com.google.cloud.videointelligence.v1beta1.FaceLocationOrBuilder>(
                locations_,
                ((bitField0_ & 0x00000004) == 0x00000004),
                getParentForChildren(),
                isClean());
        locations_ = null;
      }
      return locationsBuilder_;
    }
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFieldsProto3(unknownFields);
    }

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


    // @@protoc_insertion_point(builder_scope:google.cloud.videointelligence.v1beta1.FaceAnnotation)
  }

  // @@protoc_insertion_point(class_scope:google.cloud.videointelligence.v1beta1.FaceAnnotation)
  private static final com.google.cloud.videointelligence.v1beta1.FaceAnnotation DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new com.google.cloud.videointelligence.v1beta1.FaceAnnotation();
  }

  public static com.google.cloud.videointelligence.v1beta1.FaceAnnotation getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

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

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

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

  public com.google.cloud.videointelligence.v1beta1.FaceAnnotation getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}

