Class FieldMask.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
All Implemented Interfaces:
FieldMaskOrBuilder, Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, MessageOrBuilder, Cloneable
Enclosing class:
FieldMask

public static final class FieldMask.Builder extends GeneratedMessage.Builder<FieldMask.Builder> implements FieldMaskOrBuilder
Protobuf type google.protobuf.FieldMask
  • Method Details

    • getDescriptor

      public static final Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Description copied from class: GeneratedMessage.Builder
      Get the FieldAccessorTable for this type. We can't have the message class pass this in to the constructor because of bootstrapping trouble with DescriptorProtos.
      Specified by:
      internalGetFieldAccessorTable in class GeneratedMessage.Builder<FieldMask.Builder>
    • clear

      public FieldMask.Builder clear()
      Description copied from class: GeneratedMessage.Builder
      Called by the initialization and clear code paths to allow subclasses to reset any of their builtin fields back to the initial values.
      Specified by:
      clear in interface Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class GeneratedMessage.Builder<FieldMask.Builder>
    • getDescriptorForType

      public Descriptors.Descriptor getDescriptorForType()
      Description copied from interface: Message.Builder
      Get the message's type's descriptor. See MessageOrBuilder.getDescriptorForType().
      Specified by:
      getDescriptorForType in interface Message.Builder
      Specified by:
      getDescriptorForType in interface MessageOrBuilder
      Overrides:
      getDescriptorForType in class GeneratedMessage.Builder<FieldMask.Builder>
    • getDefaultInstanceForType

      public FieldMask getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface MessageOrBuilder
    • build

      public FieldMask build()
      Specified by:
      build in interface Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public FieldMask buildPartial()
      Specified by:
      buildPartial in interface Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public FieldMask.Builder mergeFrom(Message other)
      Description copied from interface: Message.Builder
      Merge other into the message being built. other must have the exact same type as this (i.e. getDescriptorForType() == other.getDescriptorForType()).

      Merging occurs as follows. For each field:
      * For singular primitive fields, if the field is set in other, then other's value overwrites the value in this message.
      * For singular message fields, if the field is set in other, it is merged into the corresponding sub-message of this message using the same merging rules.
      * For repeated fields, the elements in other are concatenated with the elements in this message.
      * For oneof groups, if the other message has one of the fields set, the group of this message is cleared and replaced by the field of the other message, so that the oneof constraint is preserved.

      This is equivalent to the Message::MergeFrom method in C++.

      Specified by:
      mergeFrom in interface Message.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<FieldMask.Builder>
    • mergeFrom

      public FieldMask.Builder mergeFrom(FieldMask other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class GeneratedMessage.Builder<FieldMask.Builder>
    • mergeFrom

      public FieldMask.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<FieldMask.Builder>
      Throws:
      IOException
    • getPathsList

      public com.google.protobuf.ProtocolStringList getPathsList()
      repeated string paths = 1 [json_name = "paths"];
      Specified by:
      getPathsList in interface FieldMaskOrBuilder
      Returns:
      A list containing the paths.
    • getPathsCount

      public int getPathsCount()
      repeated string paths = 1 [json_name = "paths"];
      Specified by:
      getPathsCount in interface FieldMaskOrBuilder
      Returns:
      The count of paths.
    • getPaths

      public String getPaths(int index)
      repeated string paths = 1 [json_name = "paths"];
      Specified by:
      getPaths in interface FieldMaskOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The paths at the given index.
    • getPathsBytes

      public com.google.protobuf.ByteString getPathsBytes(int index)
      repeated string paths = 1 [json_name = "paths"];
      Specified by:
      getPathsBytes in interface FieldMaskOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the paths at the given index.
    • setPaths

      public FieldMask.Builder setPaths(int index, String value)
      repeated string paths = 1 [json_name = "paths"];
      Parameters:
      index - The index to set the value at.
      value - The paths to set.
      Returns:
      This builder for chaining.
    • addPaths

      public FieldMask.Builder addPaths(String value)
      repeated string paths = 1 [json_name = "paths"];
      Parameters:
      value - The paths to add.
      Returns:
      This builder for chaining.
    • addAllPaths

      public FieldMask.Builder addAllPaths(Iterable<String> values)
      repeated string paths = 1 [json_name = "paths"];
      Parameters:
      values - The paths to add.
      Returns:
      This builder for chaining.
    • clearPaths

      public FieldMask.Builder clearPaths()
      repeated string paths = 1 [json_name = "paths"];
      Returns:
      This builder for chaining.
    • addPathsBytes

      public FieldMask.Builder addPathsBytes(com.google.protobuf.ByteString value)
      repeated string paths = 1 [json_name = "paths"];
      Parameters:
      value - The bytes of the paths to add.
      Returns:
      This builder for chaining.