Class FsImageProto.SnapshotSection.Builder

java.lang.Object
org.apache.hadoop.thirdparty.protobuf.AbstractMessageLite.Builder
org.apache.hadoop.thirdparty.protobuf.AbstractMessage.Builder<BuilderT>
org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
org.apache.hadoop.hdfs.server.namenode.FsImageProto.SnapshotSection.Builder
All Implemented Interfaces:
Cloneable, FsImageProto.SnapshotSectionOrBuilder, org.apache.hadoop.thirdparty.protobuf.Message.Builder, org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder, org.apache.hadoop.thirdparty.protobuf.MessageLiteOrBuilder, org.apache.hadoop.thirdparty.protobuf.MessageOrBuilder
Enclosing class:
FsImageProto.SnapshotSection

public static final class FsImageProto.SnapshotSection.Builder extends org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder> implements FsImageProto.SnapshotSectionOrBuilder

 This section records the information about snapshot
 NAME: SNAPSHOT
 
Protobuf type hadoop.hdfs.fsimage.SnapshotSection
  • Method Details

    • getDescriptor

      public static final org.apache.hadoop.thirdparty.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • clear

      Specified by:
      clear in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      clear in interface org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder
      Overrides:
      clear in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • getDescriptorForType

      public org.apache.hadoop.thirdparty.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface org.apache.hadoop.thirdparty.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • getDefaultInstanceForType

      public FsImageProto.SnapshotSection getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface org.apache.hadoop.thirdparty.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface org.apache.hadoop.thirdparty.protobuf.MessageOrBuilder
    • build

      Specified by:
      build in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      build in interface org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder
    • buildPartial

      public FsImageProto.SnapshotSection buildPartial()
      Specified by:
      buildPartial in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      buildPartial in interface org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder
    • clone

      Specified by:
      clone in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      clone in interface org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder
      Overrides:
      clone in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • setField

      public FsImageProto.SnapshotSection.Builder setField(org.apache.hadoop.thirdparty.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      setField in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      setField in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • clearField

      public FsImageProto.SnapshotSection.Builder clearField(org.apache.hadoop.thirdparty.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      clearField in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • clearOneof

      public FsImageProto.SnapshotSection.Builder clearOneof(org.apache.hadoop.thirdparty.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      clearOneof in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • setRepeatedField

      public FsImageProto.SnapshotSection.Builder setRepeatedField(org.apache.hadoop.thirdparty.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
      Specified by:
      setRepeatedField in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • addRepeatedField

      public FsImageProto.SnapshotSection.Builder addRepeatedField(org.apache.hadoop.thirdparty.protobuf.Descriptors.FieldDescriptor field, Object value)
      Specified by:
      addRepeatedField in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • mergeFrom

      public FsImageProto.SnapshotSection.Builder mergeFrom(org.apache.hadoop.thirdparty.protobuf.Message other)
      Specified by:
      mergeFrom in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      mergeFrom in class org.apache.hadoop.thirdparty.protobuf.AbstractMessage.Builder<FsImageProto.SnapshotSection.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface org.apache.hadoop.thirdparty.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • mergeFrom

      public FsImageProto.SnapshotSection.Builder mergeFrom(org.apache.hadoop.thirdparty.protobuf.CodedInputStream input, org.apache.hadoop.thirdparty.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface org.apache.hadoop.thirdparty.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class org.apache.hadoop.thirdparty.protobuf.AbstractMessage.Builder<FsImageProto.SnapshotSection.Builder>
      Throws:
      IOException
    • hasSnapshotCounter

      public boolean hasSnapshotCounter()
      optional uint32 snapshotCounter = 1;
      Specified by:
      hasSnapshotCounter in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      Whether the snapshotCounter field is set.
    • getSnapshotCounter

      public int getSnapshotCounter()
      optional uint32 snapshotCounter = 1;
      Specified by:
      getSnapshotCounter in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      The snapshotCounter.
    • setSnapshotCounter

      public FsImageProto.SnapshotSection.Builder setSnapshotCounter(int value)
      optional uint32 snapshotCounter = 1;
      Parameters:
      value - The snapshotCounter to set.
      Returns:
      This builder for chaining.
    • clearSnapshotCounter

      public FsImageProto.SnapshotSection.Builder clearSnapshotCounter()
      optional uint32 snapshotCounter = 1;
      Returns:
      This builder for chaining.
    • getSnapshottableDirList

      public List<Long> getSnapshottableDirList()
      repeated uint64 snapshottableDir = 2 [packed = true];
      Specified by:
      getSnapshottableDirList in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      A list containing the snapshottableDir.
    • getSnapshottableDirCount

      public int getSnapshottableDirCount()
      repeated uint64 snapshottableDir = 2 [packed = true];
      Specified by:
      getSnapshottableDirCount in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      The count of snapshottableDir.
    • getSnapshottableDir

      public long getSnapshottableDir(int index)
      repeated uint64 snapshottableDir = 2 [packed = true];
      Specified by:
      getSnapshottableDir in interface FsImageProto.SnapshotSectionOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The snapshottableDir at the given index.
    • setSnapshottableDir

      public FsImageProto.SnapshotSection.Builder setSnapshottableDir(int index, long value)
      repeated uint64 snapshottableDir = 2 [packed = true];
      Parameters:
      index - The index to set the value at.
      value - The snapshottableDir to set.
      Returns:
      This builder for chaining.
    • addSnapshottableDir

      public FsImageProto.SnapshotSection.Builder addSnapshottableDir(long value)
      repeated uint64 snapshottableDir = 2 [packed = true];
      Parameters:
      value - The snapshottableDir to add.
      Returns:
      This builder for chaining.
    • addAllSnapshottableDir

      public FsImageProto.SnapshotSection.Builder addAllSnapshottableDir(Iterable<? extends Long> values)
      repeated uint64 snapshottableDir = 2 [packed = true];
      Parameters:
      values - The snapshottableDir to add.
      Returns:
      This builder for chaining.
    • clearSnapshottableDir

      public FsImageProto.SnapshotSection.Builder clearSnapshottableDir()
      repeated uint64 snapshottableDir = 2 [packed = true];
      Returns:
      This builder for chaining.
    • hasNumSnapshots

      public boolean hasNumSnapshots()
       total number of snapshots
       
      optional uint32 numSnapshots = 3;
      Specified by:
      hasNumSnapshots in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      Whether the numSnapshots field is set.
    • getNumSnapshots

      public int getNumSnapshots()
       total number of snapshots
       
      optional uint32 numSnapshots = 3;
      Specified by:
      getNumSnapshots in interface FsImageProto.SnapshotSectionOrBuilder
      Returns:
      The numSnapshots.
    • setNumSnapshots

      public FsImageProto.SnapshotSection.Builder setNumSnapshots(int value)
       total number of snapshots
       
      optional uint32 numSnapshots = 3;
      Parameters:
      value - The numSnapshots to set.
      Returns:
      This builder for chaining.
    • clearNumSnapshots

      public FsImageProto.SnapshotSection.Builder clearNumSnapshots()
       total number of snapshots
       
      optional uint32 numSnapshots = 3;
      Returns:
      This builder for chaining.
    • setUnknownFields

      public final FsImageProto.SnapshotSection.Builder setUnknownFields(org.apache.hadoop.thirdparty.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>
    • mergeUnknownFields

      public final FsImageProto.SnapshotSection.Builder mergeUnknownFields(org.apache.hadoop.thirdparty.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface org.apache.hadoop.thirdparty.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class org.apache.hadoop.thirdparty.protobuf.GeneratedMessageV3.Builder<FsImageProto.SnapshotSection.Builder>