Class Range.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
com.google.spanner.v1.Range.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, RangeOrBuilder, Cloneable
Enclosing class:
Range

public static final class Range.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder> implements RangeOrBuilder
 A `Range` represents a range of keys in a database. The keys themselves
 are encoded in "sortable string format", also known as ssformat. Consult
 Spanner's open source client libraries for details on the encoding.

 Each range represents a contiguous range of rows, possibly from multiple
 tables/indexes. Each range is associated with a single paxos group (known as
 a "group" throughout this API), a split (which names the exact range within
 the group), and a generation that can be used to determine whether a given
 `Range` represents a newer or older location for the key range.
 
Protobuf type google.spanner.v1.Range
  • Method Summary

    Modifier and Type
    Method
    Description
    addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
     
     
     
     
    clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
     
    `generation` indicates the freshness of the range information contained in this proto.
    The UID of the paxos group where this range is stored.
    The limit key of the range, exclusive.
    clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
     
    A group can store multiple ranges of keys.
    The start key of the range, inclusive.
     
     
    static final com.google.protobuf.Descriptors.Descriptor
     
    com.google.protobuf.Descriptors.Descriptor
     
    com.google.protobuf.ByteString
    `generation` indicates the freshness of the range information contained in this proto.
    long
    The UID of the paxos group where this range is stored.
    com.google.protobuf.ByteString
    The limit key of the range, exclusive.
    long
    A group can store multiple ranges of keys.
    com.google.protobuf.ByteString
    The start key of the range, inclusive.
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
     
    final boolean
     
    mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    mergeFrom(com.google.protobuf.Message other)
     
     
    mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
     
    setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
     
    setGeneration(com.google.protobuf.ByteString value)
    `generation` indicates the freshness of the range information contained in this proto.
    setGroupUid(long value)
    The UID of the paxos group where this range is stored.
    setLimitKey(com.google.protobuf.ByteString value)
    The limit key of the range, exclusive.
    setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
     
    setSplitId(long value)
    A group can store multiple ranges of keys.
    setStartKey(com.google.protobuf.ByteString value)
    The start key of the range, inclusive.
    setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
     

    Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder

    getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3

    Methods inherited from class com.google.protobuf.AbstractMessage.Builder

    findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString

    Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder

    addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.google.protobuf.Message.Builder

    mergeDelimitedFrom, mergeDelimitedFrom

    Methods inherited from interface com.google.protobuf.MessageLite.Builder

    mergeFrom

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • clear

      public Range.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • getDefaultInstanceForType

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

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

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

      public Range.Builder clone()
      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • setField

      public Range.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • clearField

      public Range.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • clearOneof

      public Range.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • setRepeatedField

      public Range.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • addRepeatedField

      public Range.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • mergeFrom

      public Range.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Range.Builder>
    • mergeFrom

      public Range.Builder mergeFrom(Range other)
    • isInitialized

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

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

      public com.google.protobuf.ByteString getStartKey()
       The start key of the range, inclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes start_key = 1;
      Specified by:
      getStartKey in interface RangeOrBuilder
      Returns:
      The startKey.
    • setStartKey

      public Range.Builder setStartKey(com.google.protobuf.ByteString value)
       The start key of the range, inclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes start_key = 1;
      Parameters:
      value - The startKey to set.
      Returns:
      This builder for chaining.
    • clearStartKey

      public Range.Builder clearStartKey()
       The start key of the range, inclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes start_key = 1;
      Returns:
      This builder for chaining.
    • getLimitKey

      public com.google.protobuf.ByteString getLimitKey()
       The limit key of the range, exclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes limit_key = 2;
      Specified by:
      getLimitKey in interface RangeOrBuilder
      Returns:
      The limitKey.
    • setLimitKey

      public Range.Builder setLimitKey(com.google.protobuf.ByteString value)
       The limit key of the range, exclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes limit_key = 2;
      Parameters:
      value - The limitKey to set.
      Returns:
      This builder for chaining.
    • clearLimitKey

      public Range.Builder clearLimitKey()
       The limit key of the range, exclusive. Encoded in "sortable string format"
       (ssformat).
       
      bytes limit_key = 2;
      Returns:
      This builder for chaining.
    • getGroupUid

      public long getGroupUid()
       The UID of the paxos group where this range is stored. UIDs are unique
       within the database. References `Group.group_uid`.
       
      uint64 group_uid = 3;
      Specified by:
      getGroupUid in interface RangeOrBuilder
      Returns:
      The groupUid.
    • setGroupUid

      public Range.Builder setGroupUid(long value)
       The UID of the paxos group where this range is stored. UIDs are unique
       within the database. References `Group.group_uid`.
       
      uint64 group_uid = 3;
      Parameters:
      value - The groupUid to set.
      Returns:
      This builder for chaining.
    • clearGroupUid

      public Range.Builder clearGroupUid()
       The UID of the paxos group where this range is stored. UIDs are unique
       within the database. References `Group.group_uid`.
       
      uint64 group_uid = 3;
      Returns:
      This builder for chaining.
    • getSplitId

      public long getSplitId()
       A group can store multiple ranges of keys. Each key range is named by an
       ID (the split ID). Within a group, split IDs are unique. The `split_id`
       names the exact split in `group_uid` where this range is stored.
       
      uint64 split_id = 4;
      Specified by:
      getSplitId in interface RangeOrBuilder
      Returns:
      The splitId.
    • setSplitId

      public Range.Builder setSplitId(long value)
       A group can store multiple ranges of keys. Each key range is named by an
       ID (the split ID). Within a group, split IDs are unique. The `split_id`
       names the exact split in `group_uid` where this range is stored.
       
      uint64 split_id = 4;
      Parameters:
      value - The splitId to set.
      Returns:
      This builder for chaining.
    • clearSplitId

      public Range.Builder clearSplitId()
       A group can store multiple ranges of keys. Each key range is named by an
       ID (the split ID). Within a group, split IDs are unique. The `split_id`
       names the exact split in `group_uid` where this range is stored.
       
      uint64 split_id = 4;
      Returns:
      This builder for chaining.
    • getGeneration

      public com.google.protobuf.ByteString getGeneration()
       `generation` indicates the freshness of the range information contained
       in this proto. Generations can be compared lexicographically; if generation
       A is greater than generation B, then the `Range` corresponding to A is
       newer than the `Range` corresponding to B, and should be used
       preferentially.
       
      bytes generation = 5;
      Specified by:
      getGeneration in interface RangeOrBuilder
      Returns:
      The generation.
    • setGeneration

      public Range.Builder setGeneration(com.google.protobuf.ByteString value)
       `generation` indicates the freshness of the range information contained
       in this proto. Generations can be compared lexicographically; if generation
       A is greater than generation B, then the `Range` corresponding to A is
       newer than the `Range` corresponding to B, and should be used
       preferentially.
       
      bytes generation = 5;
      Parameters:
      value - The generation to set.
      Returns:
      This builder for chaining.
    • clearGeneration

      public Range.Builder clearGeneration()
       `generation` indicates the freshness of the range information contained
       in this proto. Generations can be compared lexicographically; if generation
       A is greater than generation B, then the `Range` corresponding to A is
       newer than the `Range` corresponding to B, and should be used
       preferentially.
       
      bytes generation = 5;
      Returns:
      This builder for chaining.
    • setUnknownFields

      public final Range.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>
    • mergeUnknownFields

      public final Range.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Range.Builder>