TFileRangeDesc.java

/**
 * Autogenerated by Thrift Compiler (0.16.0)
 *
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
 *  @generated
 */
package org.apache.doris.thrift;

@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.16.0)", date = "2026-05-14")
public class TFileRangeDesc implements org.apache.thrift.TBase<TFileRangeDesc, TFileRangeDesc._Fields>, java.io.Serializable, Cloneable, Comparable<TFileRangeDesc> {
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TFileRangeDesc");

  private static final org.apache.thrift.protocol.TField LOAD_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("load_id", org.apache.thrift.protocol.TType.STRUCT, (short)1);
  private static final org.apache.thrift.protocol.TField PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("path", org.apache.thrift.protocol.TType.STRING, (short)2);
  private static final org.apache.thrift.protocol.TField START_OFFSET_FIELD_DESC = new org.apache.thrift.protocol.TField("start_offset", org.apache.thrift.protocol.TType.I64, (short)3);
  private static final org.apache.thrift.protocol.TField SIZE_FIELD_DESC = new org.apache.thrift.protocol.TField("size", org.apache.thrift.protocol.TType.I64, (short)4);
  private static final org.apache.thrift.protocol.TField FILE_SIZE_FIELD_DESC = new org.apache.thrift.protocol.TField("file_size", org.apache.thrift.protocol.TType.I64, (short)5);
  private static final org.apache.thrift.protocol.TField COLUMNS_FROM_PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("columns_from_path", org.apache.thrift.protocol.TType.LIST, (short)6);
  private static final org.apache.thrift.protocol.TField COLUMNS_FROM_PATH_KEYS_FIELD_DESC = new org.apache.thrift.protocol.TField("columns_from_path_keys", org.apache.thrift.protocol.TType.LIST, (short)7);
  private static final org.apache.thrift.protocol.TField TABLE_FORMAT_PARAMS_FIELD_DESC = new org.apache.thrift.protocol.TField("table_format_params", org.apache.thrift.protocol.TType.STRUCT, (short)8);
  private static final org.apache.thrift.protocol.TField MODIFICATION_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("modification_time", org.apache.thrift.protocol.TType.I64, (short)9);
  private static final org.apache.thrift.protocol.TField FILE_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("file_type", org.apache.thrift.protocol.TType.I32, (short)10);
  private static final org.apache.thrift.protocol.TField COMPRESS_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("compress_type", org.apache.thrift.protocol.TType.I32, (short)11);
  private static final org.apache.thrift.protocol.TField FS_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("fs_name", org.apache.thrift.protocol.TType.STRING, (short)12);
  private static final org.apache.thrift.protocol.TField FORMAT_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("format_type", org.apache.thrift.protocol.TType.I32, (short)13);
  private static final org.apache.thrift.protocol.TField SELF_SPLIT_WEIGHT_FIELD_DESC = new org.apache.thrift.protocol.TField("self_split_weight", org.apache.thrift.protocol.TType.I64, (short)14);
  private static final org.apache.thrift.protocol.TField COLUMNS_FROM_PATH_IS_NULL_FIELD_DESC = new org.apache.thrift.protocol.TField("columns_from_path_is_null", org.apache.thrift.protocol.TType.LIST, (short)15);
  private static final org.apache.thrift.protocol.TField FILE_CACHE_ADMISSION_FIELD_DESC = new org.apache.thrift.protocol.TField("file_cache_admission", org.apache.thrift.protocol.TType.BOOL, (short)16);

  private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TFileRangeDescStandardSchemeFactory();
  private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TFileRangeDescTupleSchemeFactory();

  public @org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TUniqueId load_id; // optional
  public @org.apache.thrift.annotation.Nullable java.lang.String path; // optional
  public long start_offset; // optional
  public long size; // optional
  public long file_size; // optional
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> columns_from_path; // optional
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> columns_from_path_keys; // optional
  public @org.apache.thrift.annotation.Nullable TTableFormatFileDesc table_format_params; // optional
  public long modification_time; // optional
  /**
   * 
   * @see org.apache.doris.thrift.TFileType
   */
  public @org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TFileType file_type; // optional
  /**
   * 
   * @see TFileCompressType
   */
  public @org.apache.thrift.annotation.Nullable TFileCompressType compress_type; // optional
  public @org.apache.thrift.annotation.Nullable java.lang.String fs_name; // optional
  /**
   * 
   * @see TFileFormatType
   */
  public @org.apache.thrift.annotation.Nullable TFileFormatType format_type; // optional
  public long self_split_weight; // optional
  public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.Boolean> columns_from_path_is_null; // optional
  public boolean file_cache_admission; // optional

  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
    LOAD_ID((short)1, "load_id"),
    PATH((short)2, "path"),
    START_OFFSET((short)3, "start_offset"),
    SIZE((short)4, "size"),
    FILE_SIZE((short)5, "file_size"),
    COLUMNS_FROM_PATH((short)6, "columns_from_path"),
    COLUMNS_FROM_PATH_KEYS((short)7, "columns_from_path_keys"),
    TABLE_FORMAT_PARAMS((short)8, "table_format_params"),
    MODIFICATION_TIME((short)9, "modification_time"),
    /**
     * 
     * @see org.apache.doris.thrift.TFileType
     */
    FILE_TYPE((short)10, "file_type"),
    /**
     * 
     * @see TFileCompressType
     */
    COMPRESS_TYPE((short)11, "compress_type"),
    FS_NAME((short)12, "fs_name"),
    /**
     * 
     * @see TFileFormatType
     */
    FORMAT_TYPE((short)13, "format_type"),
    SELF_SPLIT_WEIGHT((short)14, "self_split_weight"),
    COLUMNS_FROM_PATH_IS_NULL((short)15, "columns_from_path_is_null"),
    FILE_CACHE_ADMISSION((short)16, "file_cache_admission");

    private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();

    static {
      for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
        byName.put(field.getFieldName(), field);
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, or null if its not found.
     */
    @org.apache.thrift.annotation.Nullable
    public static _Fields findByThriftId(int fieldId) {
      switch(fieldId) {
        case 1: // LOAD_ID
          return LOAD_ID;
        case 2: // PATH
          return PATH;
        case 3: // START_OFFSET
          return START_OFFSET;
        case 4: // SIZE
          return SIZE;
        case 5: // FILE_SIZE
          return FILE_SIZE;
        case 6: // COLUMNS_FROM_PATH
          return COLUMNS_FROM_PATH;
        case 7: // COLUMNS_FROM_PATH_KEYS
          return COLUMNS_FROM_PATH_KEYS;
        case 8: // TABLE_FORMAT_PARAMS
          return TABLE_FORMAT_PARAMS;
        case 9: // MODIFICATION_TIME
          return MODIFICATION_TIME;
        case 10: // FILE_TYPE
          return FILE_TYPE;
        case 11: // COMPRESS_TYPE
          return COMPRESS_TYPE;
        case 12: // FS_NAME
          return FS_NAME;
        case 13: // FORMAT_TYPE
          return FORMAT_TYPE;
        case 14: // SELF_SPLIT_WEIGHT
          return SELF_SPLIT_WEIGHT;
        case 15: // COLUMNS_FROM_PATH_IS_NULL
          return COLUMNS_FROM_PATH_IS_NULL;
        case 16: // FILE_CACHE_ADMISSION
          return FILE_CACHE_ADMISSION;
        default:
          return null;
      }
    }

    /**
     * Find the _Fields constant that matches fieldId, throwing an exception
     * if it is not found.
     */
    public static _Fields findByThriftIdOrThrow(int fieldId) {
      _Fields fields = findByThriftId(fieldId);
      if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
      return fields;
    }

    /**
     * Find the _Fields constant that matches name, or null if its not found.
     */
    @org.apache.thrift.annotation.Nullable
    public static _Fields findByName(java.lang.String name) {
      return byName.get(name);
    }

    private final short _thriftId;
    private final java.lang.String _fieldName;

    _Fields(short thriftId, java.lang.String fieldName) {
      _thriftId = thriftId;
      _fieldName = fieldName;
    }

    public short getThriftFieldId() {
      return _thriftId;
    }

    public java.lang.String getFieldName() {
      return _fieldName;
    }
  }

  // isset id assignments
  private static final int __START_OFFSET_ISSET_ID = 0;
  private static final int __SIZE_ISSET_ID = 1;
  private static final int __FILE_SIZE_ISSET_ID = 2;
  private static final int __MODIFICATION_TIME_ISSET_ID = 3;
  private static final int __SELF_SPLIT_WEIGHT_ISSET_ID = 4;
  private static final int __FILE_CACHE_ADMISSION_ISSET_ID = 5;
  private byte __isset_bitfield = 0;
  private static final _Fields optionals[] = {_Fields.LOAD_ID,_Fields.PATH,_Fields.START_OFFSET,_Fields.SIZE,_Fields.FILE_SIZE,_Fields.COLUMNS_FROM_PATH,_Fields.COLUMNS_FROM_PATH_KEYS,_Fields.TABLE_FORMAT_PARAMS,_Fields.MODIFICATION_TIME,_Fields.FILE_TYPE,_Fields.COMPRESS_TYPE,_Fields.FS_NAME,_Fields.FORMAT_TYPE,_Fields.SELF_SPLIT_WEIGHT,_Fields.COLUMNS_FROM_PATH_IS_NULL,_Fields.FILE_CACHE_ADMISSION};
  public static final java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
  static {
    java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
    tmpMap.put(_Fields.LOAD_ID, new org.apache.thrift.meta_data.FieldMetaData("load_id", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, org.apache.doris.thrift.TUniqueId.class)));
    tmpMap.put(_Fields.PATH, new org.apache.thrift.meta_data.FieldMetaData("path", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.START_OFFSET, new org.apache.thrift.meta_data.FieldMetaData("start_offset", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.SIZE, new org.apache.thrift.meta_data.FieldMetaData("size", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.FILE_SIZE, new org.apache.thrift.meta_data.FieldMetaData("file_size", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.COLUMNS_FROM_PATH, new org.apache.thrift.meta_data.FieldMetaData("columns_from_path", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
    tmpMap.put(_Fields.COLUMNS_FROM_PATH_KEYS, new org.apache.thrift.meta_data.FieldMetaData("columns_from_path_keys", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
    tmpMap.put(_Fields.TABLE_FORMAT_PARAMS, new org.apache.thrift.meta_data.FieldMetaData("table_format_params", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TTableFormatFileDesc.class)));
    tmpMap.put(_Fields.MODIFICATION_TIME, new org.apache.thrift.meta_data.FieldMetaData("modification_time", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.FILE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("file_type", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, org.apache.doris.thrift.TFileType.class)));
    tmpMap.put(_Fields.COMPRESS_TYPE, new org.apache.thrift.meta_data.FieldMetaData("compress_type", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TFileCompressType.class)));
    tmpMap.put(_Fields.FS_NAME, new org.apache.thrift.meta_data.FieldMetaData("fs_name", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.FORMAT_TYPE, new org.apache.thrift.meta_data.FieldMetaData("format_type", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, TFileFormatType.class)));
    tmpMap.put(_Fields.SELF_SPLIT_WEIGHT, new org.apache.thrift.meta_data.FieldMetaData("self_split_weight", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
    tmpMap.put(_Fields.COLUMNS_FROM_PATH_IS_NULL, new org.apache.thrift.meta_data.FieldMetaData("columns_from_path_is_null", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
            new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))));
    tmpMap.put(_Fields.FILE_CACHE_ADMISSION, new org.apache.thrift.meta_data.FieldMetaData("file_cache_admission", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TFileRangeDesc.class, metaDataMap);
  }

  public TFileRangeDesc() {
    this.file_size = -1L;

  }

  /**
   * Performs a deep copy on <i>other</i>.
   */
  public TFileRangeDesc(TFileRangeDesc other) {
    __isset_bitfield = other.__isset_bitfield;
    if (other.isSetLoadId()) {
      this.load_id = new org.apache.doris.thrift.TUniqueId(other.load_id);
    }
    if (other.isSetPath()) {
      this.path = other.path;
    }
    this.start_offset = other.start_offset;
    this.size = other.size;
    this.file_size = other.file_size;
    if (other.isSetColumnsFromPath()) {
      java.util.List<java.lang.String> __this__columns_from_path = new java.util.ArrayList<java.lang.String>(other.columns_from_path);
      this.columns_from_path = __this__columns_from_path;
    }
    if (other.isSetColumnsFromPathKeys()) {
      java.util.List<java.lang.String> __this__columns_from_path_keys = new java.util.ArrayList<java.lang.String>(other.columns_from_path_keys);
      this.columns_from_path_keys = __this__columns_from_path_keys;
    }
    if (other.isSetTableFormatParams()) {
      this.table_format_params = new TTableFormatFileDesc(other.table_format_params);
    }
    this.modification_time = other.modification_time;
    if (other.isSetFileType()) {
      this.file_type = other.file_type;
    }
    if (other.isSetCompressType()) {
      this.compress_type = other.compress_type;
    }
    if (other.isSetFsName()) {
      this.fs_name = other.fs_name;
    }
    if (other.isSetFormatType()) {
      this.format_type = other.format_type;
    }
    this.self_split_weight = other.self_split_weight;
    if (other.isSetColumnsFromPathIsNull()) {
      java.util.List<java.lang.Boolean> __this__columns_from_path_is_null = new java.util.ArrayList<java.lang.Boolean>(other.columns_from_path_is_null);
      this.columns_from_path_is_null = __this__columns_from_path_is_null;
    }
    this.file_cache_admission = other.file_cache_admission;
  }

  public TFileRangeDesc deepCopy() {
    return new TFileRangeDesc(this);
  }

  @Override
  public void clear() {
    this.load_id = null;
    this.path = null;
    setStartOffsetIsSet(false);
    this.start_offset = 0;
    setSizeIsSet(false);
    this.size = 0;
    this.file_size = -1L;

    this.columns_from_path = null;
    this.columns_from_path_keys = null;
    this.table_format_params = null;
    setModificationTimeIsSet(false);
    this.modification_time = 0;
    this.file_type = null;
    this.compress_type = null;
    this.fs_name = null;
    this.format_type = null;
    setSelfSplitWeightIsSet(false);
    this.self_split_weight = 0;
    this.columns_from_path_is_null = null;
    setFileCacheAdmissionIsSet(false);
    this.file_cache_admission = false;
  }

  @org.apache.thrift.annotation.Nullable
  public org.apache.doris.thrift.TUniqueId getLoadId() {
    return this.load_id;
  }

  public TFileRangeDesc setLoadId(@org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TUniqueId load_id) {
    this.load_id = load_id;
    return this;
  }

  public void unsetLoadId() {
    this.load_id = null;
  }

  /** Returns true if field load_id is set (has been assigned a value) and false otherwise */
  public boolean isSetLoadId() {
    return this.load_id != null;
  }

  public void setLoadIdIsSet(boolean value) {
    if (!value) {
      this.load_id = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public java.lang.String getPath() {
    return this.path;
  }

  public TFileRangeDesc setPath(@org.apache.thrift.annotation.Nullable java.lang.String path) {
    this.path = path;
    return this;
  }

  public void unsetPath() {
    this.path = null;
  }

  /** Returns true if field path is set (has been assigned a value) and false otherwise */
  public boolean isSetPath() {
    return this.path != null;
  }

  public void setPathIsSet(boolean value) {
    if (!value) {
      this.path = null;
    }
  }

  public long getStartOffset() {
    return this.start_offset;
  }

  public TFileRangeDesc setStartOffset(long start_offset) {
    this.start_offset = start_offset;
    setStartOffsetIsSet(true);
    return this;
  }

  public void unsetStartOffset() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __START_OFFSET_ISSET_ID);
  }

  /** Returns true if field start_offset is set (has been assigned a value) and false otherwise */
  public boolean isSetStartOffset() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __START_OFFSET_ISSET_ID);
  }

  public void setStartOffsetIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __START_OFFSET_ISSET_ID, value);
  }

  public long getSize() {
    return this.size;
  }

  public TFileRangeDesc setSize(long size) {
    this.size = size;
    setSizeIsSet(true);
    return this;
  }

  public void unsetSize() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SIZE_ISSET_ID);
  }

  /** Returns true if field size is set (has been assigned a value) and false otherwise */
  public boolean isSetSize() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SIZE_ISSET_ID);
  }

  public void setSizeIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SIZE_ISSET_ID, value);
  }

  public long getFileSize() {
    return this.file_size;
  }

  public TFileRangeDesc setFileSize(long file_size) {
    this.file_size = file_size;
    setFileSizeIsSet(true);
    return this;
  }

  public void unsetFileSize() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __FILE_SIZE_ISSET_ID);
  }

  /** Returns true if field file_size is set (has been assigned a value) and false otherwise */
  public boolean isSetFileSize() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __FILE_SIZE_ISSET_ID);
  }

  public void setFileSizeIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __FILE_SIZE_ISSET_ID, value);
  }

  public int getColumnsFromPathSize() {
    return (this.columns_from_path == null) ? 0 : this.columns_from_path.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.String> getColumnsFromPathIterator() {
    return (this.columns_from_path == null) ? null : this.columns_from_path.iterator();
  }

  public void addToColumnsFromPath(java.lang.String elem) {
    if (this.columns_from_path == null) {
      this.columns_from_path = new java.util.ArrayList<java.lang.String>();
    }
    this.columns_from_path.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.String> getColumnsFromPath() {
    return this.columns_from_path;
  }

  public TFileRangeDesc setColumnsFromPath(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> columns_from_path) {
    this.columns_from_path = columns_from_path;
    return this;
  }

  public void unsetColumnsFromPath() {
    this.columns_from_path = null;
  }

  /** Returns true if field columns_from_path is set (has been assigned a value) and false otherwise */
  public boolean isSetColumnsFromPath() {
    return this.columns_from_path != null;
  }

  public void setColumnsFromPathIsSet(boolean value) {
    if (!value) {
      this.columns_from_path = null;
    }
  }

  public int getColumnsFromPathKeysSize() {
    return (this.columns_from_path_keys == null) ? 0 : this.columns_from_path_keys.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.String> getColumnsFromPathKeysIterator() {
    return (this.columns_from_path_keys == null) ? null : this.columns_from_path_keys.iterator();
  }

  public void addToColumnsFromPathKeys(java.lang.String elem) {
    if (this.columns_from_path_keys == null) {
      this.columns_from_path_keys = new java.util.ArrayList<java.lang.String>();
    }
    this.columns_from_path_keys.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.String> getColumnsFromPathKeys() {
    return this.columns_from_path_keys;
  }

  public TFileRangeDesc setColumnsFromPathKeys(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> columns_from_path_keys) {
    this.columns_from_path_keys = columns_from_path_keys;
    return this;
  }

  public void unsetColumnsFromPathKeys() {
    this.columns_from_path_keys = null;
  }

  /** Returns true if field columns_from_path_keys is set (has been assigned a value) and false otherwise */
  public boolean isSetColumnsFromPathKeys() {
    return this.columns_from_path_keys != null;
  }

  public void setColumnsFromPathKeysIsSet(boolean value) {
    if (!value) {
      this.columns_from_path_keys = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TTableFormatFileDesc getTableFormatParams() {
    return this.table_format_params;
  }

  public TFileRangeDesc setTableFormatParams(@org.apache.thrift.annotation.Nullable TTableFormatFileDesc table_format_params) {
    this.table_format_params = table_format_params;
    return this;
  }

  public void unsetTableFormatParams() {
    this.table_format_params = null;
  }

  /** Returns true if field table_format_params is set (has been assigned a value) and false otherwise */
  public boolean isSetTableFormatParams() {
    return this.table_format_params != null;
  }

  public void setTableFormatParamsIsSet(boolean value) {
    if (!value) {
      this.table_format_params = null;
    }
  }

  public long getModificationTime() {
    return this.modification_time;
  }

  public TFileRangeDesc setModificationTime(long modification_time) {
    this.modification_time = modification_time;
    setModificationTimeIsSet(true);
    return this;
  }

  public void unsetModificationTime() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MODIFICATION_TIME_ISSET_ID);
  }

  /** Returns true if field modification_time is set (has been assigned a value) and false otherwise */
  public boolean isSetModificationTime() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MODIFICATION_TIME_ISSET_ID);
  }

  public void setModificationTimeIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MODIFICATION_TIME_ISSET_ID, value);
  }

  /**
   * 
   * @see org.apache.doris.thrift.TFileType
   */
  @org.apache.thrift.annotation.Nullable
  public org.apache.doris.thrift.TFileType getFileType() {
    return this.file_type;
  }

  /**
   * 
   * @see org.apache.doris.thrift.TFileType
   */
  public TFileRangeDesc setFileType(@org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TFileType file_type) {
    this.file_type = file_type;
    return this;
  }

  public void unsetFileType() {
    this.file_type = null;
  }

  /** Returns true if field file_type is set (has been assigned a value) and false otherwise */
  public boolean isSetFileType() {
    return this.file_type != null;
  }

  public void setFileTypeIsSet(boolean value) {
    if (!value) {
      this.file_type = null;
    }
  }

  /**
   * 
   * @see TFileCompressType
   */
  @org.apache.thrift.annotation.Nullable
  public TFileCompressType getCompressType() {
    return this.compress_type;
  }

  /**
   * 
   * @see TFileCompressType
   */
  public TFileRangeDesc setCompressType(@org.apache.thrift.annotation.Nullable TFileCompressType compress_type) {
    this.compress_type = compress_type;
    return this;
  }

  public void unsetCompressType() {
    this.compress_type = null;
  }

  /** Returns true if field compress_type is set (has been assigned a value) and false otherwise */
  public boolean isSetCompressType() {
    return this.compress_type != null;
  }

  public void setCompressTypeIsSet(boolean value) {
    if (!value) {
      this.compress_type = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public java.lang.String getFsName() {
    return this.fs_name;
  }

  public TFileRangeDesc setFsName(@org.apache.thrift.annotation.Nullable java.lang.String fs_name) {
    this.fs_name = fs_name;
    return this;
  }

  public void unsetFsName() {
    this.fs_name = null;
  }

  /** Returns true if field fs_name is set (has been assigned a value) and false otherwise */
  public boolean isSetFsName() {
    return this.fs_name != null;
  }

  public void setFsNameIsSet(boolean value) {
    if (!value) {
      this.fs_name = null;
    }
  }

  /**
   * 
   * @see TFileFormatType
   */
  @org.apache.thrift.annotation.Nullable
  public TFileFormatType getFormatType() {
    return this.format_type;
  }

  /**
   * 
   * @see TFileFormatType
   */
  public TFileRangeDesc setFormatType(@org.apache.thrift.annotation.Nullable TFileFormatType format_type) {
    this.format_type = format_type;
    return this;
  }

  public void unsetFormatType() {
    this.format_type = null;
  }

  /** Returns true if field format_type is set (has been assigned a value) and false otherwise */
  public boolean isSetFormatType() {
    return this.format_type != null;
  }

  public void setFormatTypeIsSet(boolean value) {
    if (!value) {
      this.format_type = null;
    }
  }

  public long getSelfSplitWeight() {
    return this.self_split_weight;
  }

  public TFileRangeDesc setSelfSplitWeight(long self_split_weight) {
    this.self_split_weight = self_split_weight;
    setSelfSplitWeightIsSet(true);
    return this;
  }

  public void unsetSelfSplitWeight() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SELF_SPLIT_WEIGHT_ISSET_ID);
  }

  /** Returns true if field self_split_weight is set (has been assigned a value) and false otherwise */
  public boolean isSetSelfSplitWeight() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SELF_SPLIT_WEIGHT_ISSET_ID);
  }

  public void setSelfSplitWeightIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SELF_SPLIT_WEIGHT_ISSET_ID, value);
  }

  public int getColumnsFromPathIsNullSize() {
    return (this.columns_from_path_is_null == null) ? 0 : this.columns_from_path_is_null.size();
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.Iterator<java.lang.Boolean> getColumnsFromPathIsNullIterator() {
    return (this.columns_from_path_is_null == null) ? null : this.columns_from_path_is_null.iterator();
  }

  public void addToColumnsFromPathIsNull(boolean elem) {
    if (this.columns_from_path_is_null == null) {
      this.columns_from_path_is_null = new java.util.ArrayList<java.lang.Boolean>();
    }
    this.columns_from_path_is_null.add(elem);
  }

  @org.apache.thrift.annotation.Nullable
  public java.util.List<java.lang.Boolean> getColumnsFromPathIsNull() {
    return this.columns_from_path_is_null;
  }

  public TFileRangeDesc setColumnsFromPathIsNull(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.Boolean> columns_from_path_is_null) {
    this.columns_from_path_is_null = columns_from_path_is_null;
    return this;
  }

  public void unsetColumnsFromPathIsNull() {
    this.columns_from_path_is_null = null;
  }

  /** Returns true if field columns_from_path_is_null is set (has been assigned a value) and false otherwise */
  public boolean isSetColumnsFromPathIsNull() {
    return this.columns_from_path_is_null != null;
  }

  public void setColumnsFromPathIsNullIsSet(boolean value) {
    if (!value) {
      this.columns_from_path_is_null = null;
    }
  }

  public boolean isFileCacheAdmission() {
    return this.file_cache_admission;
  }

  public TFileRangeDesc setFileCacheAdmission(boolean file_cache_admission) {
    this.file_cache_admission = file_cache_admission;
    setFileCacheAdmissionIsSet(true);
    return this;
  }

  public void unsetFileCacheAdmission() {
    __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __FILE_CACHE_ADMISSION_ISSET_ID);
  }

  /** Returns true if field file_cache_admission is set (has been assigned a value) and false otherwise */
  public boolean isSetFileCacheAdmission() {
    return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __FILE_CACHE_ADMISSION_ISSET_ID);
  }

  public void setFileCacheAdmissionIsSet(boolean value) {
    __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __FILE_CACHE_ADMISSION_ISSET_ID, value);
  }

  public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
    switch (field) {
    case LOAD_ID:
      if (value == null) {
        unsetLoadId();
      } else {
        setLoadId((org.apache.doris.thrift.TUniqueId)value);
      }
      break;

    case PATH:
      if (value == null) {
        unsetPath();
      } else {
        setPath((java.lang.String)value);
      }
      break;

    case START_OFFSET:
      if (value == null) {
        unsetStartOffset();
      } else {
        setStartOffset((java.lang.Long)value);
      }
      break;

    case SIZE:
      if (value == null) {
        unsetSize();
      } else {
        setSize((java.lang.Long)value);
      }
      break;

    case FILE_SIZE:
      if (value == null) {
        unsetFileSize();
      } else {
        setFileSize((java.lang.Long)value);
      }
      break;

    case COLUMNS_FROM_PATH:
      if (value == null) {
        unsetColumnsFromPath();
      } else {
        setColumnsFromPath((java.util.List<java.lang.String>)value);
      }
      break;

    case COLUMNS_FROM_PATH_KEYS:
      if (value == null) {
        unsetColumnsFromPathKeys();
      } else {
        setColumnsFromPathKeys((java.util.List<java.lang.String>)value);
      }
      break;

    case TABLE_FORMAT_PARAMS:
      if (value == null) {
        unsetTableFormatParams();
      } else {
        setTableFormatParams((TTableFormatFileDesc)value);
      }
      break;

    case MODIFICATION_TIME:
      if (value == null) {
        unsetModificationTime();
      } else {
        setModificationTime((java.lang.Long)value);
      }
      break;

    case FILE_TYPE:
      if (value == null) {
        unsetFileType();
      } else {
        setFileType((org.apache.doris.thrift.TFileType)value);
      }
      break;

    case COMPRESS_TYPE:
      if (value == null) {
        unsetCompressType();
      } else {
        setCompressType((TFileCompressType)value);
      }
      break;

    case FS_NAME:
      if (value == null) {
        unsetFsName();
      } else {
        setFsName((java.lang.String)value);
      }
      break;

    case FORMAT_TYPE:
      if (value == null) {
        unsetFormatType();
      } else {
        setFormatType((TFileFormatType)value);
      }
      break;

    case SELF_SPLIT_WEIGHT:
      if (value == null) {
        unsetSelfSplitWeight();
      } else {
        setSelfSplitWeight((java.lang.Long)value);
      }
      break;

    case COLUMNS_FROM_PATH_IS_NULL:
      if (value == null) {
        unsetColumnsFromPathIsNull();
      } else {
        setColumnsFromPathIsNull((java.util.List<java.lang.Boolean>)value);
      }
      break;

    case FILE_CACHE_ADMISSION:
      if (value == null) {
        unsetFileCacheAdmission();
      } else {
        setFileCacheAdmission((java.lang.Boolean)value);
      }
      break;

    }
  }

  @org.apache.thrift.annotation.Nullable
  public java.lang.Object getFieldValue(_Fields field) {
    switch (field) {
    case LOAD_ID:
      return getLoadId();

    case PATH:
      return getPath();

    case START_OFFSET:
      return getStartOffset();

    case SIZE:
      return getSize();

    case FILE_SIZE:
      return getFileSize();

    case COLUMNS_FROM_PATH:
      return getColumnsFromPath();

    case COLUMNS_FROM_PATH_KEYS:
      return getColumnsFromPathKeys();

    case TABLE_FORMAT_PARAMS:
      return getTableFormatParams();

    case MODIFICATION_TIME:
      return getModificationTime();

    case FILE_TYPE:
      return getFileType();

    case COMPRESS_TYPE:
      return getCompressType();

    case FS_NAME:
      return getFsName();

    case FORMAT_TYPE:
      return getFormatType();

    case SELF_SPLIT_WEIGHT:
      return getSelfSplitWeight();

    case COLUMNS_FROM_PATH_IS_NULL:
      return getColumnsFromPathIsNull();

    case FILE_CACHE_ADMISSION:
      return isFileCacheAdmission();

    }
    throw new java.lang.IllegalStateException();
  }

  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
  public boolean isSet(_Fields field) {
    if (field == null) {
      throw new java.lang.IllegalArgumentException();
    }

    switch (field) {
    case LOAD_ID:
      return isSetLoadId();
    case PATH:
      return isSetPath();
    case START_OFFSET:
      return isSetStartOffset();
    case SIZE:
      return isSetSize();
    case FILE_SIZE:
      return isSetFileSize();
    case COLUMNS_FROM_PATH:
      return isSetColumnsFromPath();
    case COLUMNS_FROM_PATH_KEYS:
      return isSetColumnsFromPathKeys();
    case TABLE_FORMAT_PARAMS:
      return isSetTableFormatParams();
    case MODIFICATION_TIME:
      return isSetModificationTime();
    case FILE_TYPE:
      return isSetFileType();
    case COMPRESS_TYPE:
      return isSetCompressType();
    case FS_NAME:
      return isSetFsName();
    case FORMAT_TYPE:
      return isSetFormatType();
    case SELF_SPLIT_WEIGHT:
      return isSetSelfSplitWeight();
    case COLUMNS_FROM_PATH_IS_NULL:
      return isSetColumnsFromPathIsNull();
    case FILE_CACHE_ADMISSION:
      return isSetFileCacheAdmission();
    }
    throw new java.lang.IllegalStateException();
  }

  @Override
  public boolean equals(java.lang.Object that) {
    if (that instanceof TFileRangeDesc)
      return this.equals((TFileRangeDesc)that);
    return false;
  }

  public boolean equals(TFileRangeDesc that) {
    if (that == null)
      return false;
    if (this == that)
      return true;

    boolean this_present_load_id = true && this.isSetLoadId();
    boolean that_present_load_id = true && that.isSetLoadId();
    if (this_present_load_id || that_present_load_id) {
      if (!(this_present_load_id && that_present_load_id))
        return false;
      if (!this.load_id.equals(that.load_id))
        return false;
    }

    boolean this_present_path = true && this.isSetPath();
    boolean that_present_path = true && that.isSetPath();
    if (this_present_path || that_present_path) {
      if (!(this_present_path && that_present_path))
        return false;
      if (!this.path.equals(that.path))
        return false;
    }

    boolean this_present_start_offset = true && this.isSetStartOffset();
    boolean that_present_start_offset = true && that.isSetStartOffset();
    if (this_present_start_offset || that_present_start_offset) {
      if (!(this_present_start_offset && that_present_start_offset))
        return false;
      if (this.start_offset != that.start_offset)
        return false;
    }

    boolean this_present_size = true && this.isSetSize();
    boolean that_present_size = true && that.isSetSize();
    if (this_present_size || that_present_size) {
      if (!(this_present_size && that_present_size))
        return false;
      if (this.size != that.size)
        return false;
    }

    boolean this_present_file_size = true && this.isSetFileSize();
    boolean that_present_file_size = true && that.isSetFileSize();
    if (this_present_file_size || that_present_file_size) {
      if (!(this_present_file_size && that_present_file_size))
        return false;
      if (this.file_size != that.file_size)
        return false;
    }

    boolean this_present_columns_from_path = true && this.isSetColumnsFromPath();
    boolean that_present_columns_from_path = true && that.isSetColumnsFromPath();
    if (this_present_columns_from_path || that_present_columns_from_path) {
      if (!(this_present_columns_from_path && that_present_columns_from_path))
        return false;
      if (!this.columns_from_path.equals(that.columns_from_path))
        return false;
    }

    boolean this_present_columns_from_path_keys = true && this.isSetColumnsFromPathKeys();
    boolean that_present_columns_from_path_keys = true && that.isSetColumnsFromPathKeys();
    if (this_present_columns_from_path_keys || that_present_columns_from_path_keys) {
      if (!(this_present_columns_from_path_keys && that_present_columns_from_path_keys))
        return false;
      if (!this.columns_from_path_keys.equals(that.columns_from_path_keys))
        return false;
    }

    boolean this_present_table_format_params = true && this.isSetTableFormatParams();
    boolean that_present_table_format_params = true && that.isSetTableFormatParams();
    if (this_present_table_format_params || that_present_table_format_params) {
      if (!(this_present_table_format_params && that_present_table_format_params))
        return false;
      if (!this.table_format_params.equals(that.table_format_params))
        return false;
    }

    boolean this_present_modification_time = true && this.isSetModificationTime();
    boolean that_present_modification_time = true && that.isSetModificationTime();
    if (this_present_modification_time || that_present_modification_time) {
      if (!(this_present_modification_time && that_present_modification_time))
        return false;
      if (this.modification_time != that.modification_time)
        return false;
    }

    boolean this_present_file_type = true && this.isSetFileType();
    boolean that_present_file_type = true && that.isSetFileType();
    if (this_present_file_type || that_present_file_type) {
      if (!(this_present_file_type && that_present_file_type))
        return false;
      if (!this.file_type.equals(that.file_type))
        return false;
    }

    boolean this_present_compress_type = true && this.isSetCompressType();
    boolean that_present_compress_type = true && that.isSetCompressType();
    if (this_present_compress_type || that_present_compress_type) {
      if (!(this_present_compress_type && that_present_compress_type))
        return false;
      if (!this.compress_type.equals(that.compress_type))
        return false;
    }

    boolean this_present_fs_name = true && this.isSetFsName();
    boolean that_present_fs_name = true && that.isSetFsName();
    if (this_present_fs_name || that_present_fs_name) {
      if (!(this_present_fs_name && that_present_fs_name))
        return false;
      if (!this.fs_name.equals(that.fs_name))
        return false;
    }

    boolean this_present_format_type = true && this.isSetFormatType();
    boolean that_present_format_type = true && that.isSetFormatType();
    if (this_present_format_type || that_present_format_type) {
      if (!(this_present_format_type && that_present_format_type))
        return false;
      if (!this.format_type.equals(that.format_type))
        return false;
    }

    boolean this_present_self_split_weight = true && this.isSetSelfSplitWeight();
    boolean that_present_self_split_weight = true && that.isSetSelfSplitWeight();
    if (this_present_self_split_weight || that_present_self_split_weight) {
      if (!(this_present_self_split_weight && that_present_self_split_weight))
        return false;
      if (this.self_split_weight != that.self_split_weight)
        return false;
    }

    boolean this_present_columns_from_path_is_null = true && this.isSetColumnsFromPathIsNull();
    boolean that_present_columns_from_path_is_null = true && that.isSetColumnsFromPathIsNull();
    if (this_present_columns_from_path_is_null || that_present_columns_from_path_is_null) {
      if (!(this_present_columns_from_path_is_null && that_present_columns_from_path_is_null))
        return false;
      if (!this.columns_from_path_is_null.equals(that.columns_from_path_is_null))
        return false;
    }

    boolean this_present_file_cache_admission = true && this.isSetFileCacheAdmission();
    boolean that_present_file_cache_admission = true && that.isSetFileCacheAdmission();
    if (this_present_file_cache_admission || that_present_file_cache_admission) {
      if (!(this_present_file_cache_admission && that_present_file_cache_admission))
        return false;
      if (this.file_cache_admission != that.file_cache_admission)
        return false;
    }

    return true;
  }

  @Override
  public int hashCode() {
    int hashCode = 1;

    hashCode = hashCode * 8191 + ((isSetLoadId()) ? 131071 : 524287);
    if (isSetLoadId())
      hashCode = hashCode * 8191 + load_id.hashCode();

    hashCode = hashCode * 8191 + ((isSetPath()) ? 131071 : 524287);
    if (isSetPath())
      hashCode = hashCode * 8191 + path.hashCode();

    hashCode = hashCode * 8191 + ((isSetStartOffset()) ? 131071 : 524287);
    if (isSetStartOffset())
      hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(start_offset);

    hashCode = hashCode * 8191 + ((isSetSize()) ? 131071 : 524287);
    if (isSetSize())
      hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(size);

    hashCode = hashCode * 8191 + ((isSetFileSize()) ? 131071 : 524287);
    if (isSetFileSize())
      hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(file_size);

    hashCode = hashCode * 8191 + ((isSetColumnsFromPath()) ? 131071 : 524287);
    if (isSetColumnsFromPath())
      hashCode = hashCode * 8191 + columns_from_path.hashCode();

    hashCode = hashCode * 8191 + ((isSetColumnsFromPathKeys()) ? 131071 : 524287);
    if (isSetColumnsFromPathKeys())
      hashCode = hashCode * 8191 + columns_from_path_keys.hashCode();

    hashCode = hashCode * 8191 + ((isSetTableFormatParams()) ? 131071 : 524287);
    if (isSetTableFormatParams())
      hashCode = hashCode * 8191 + table_format_params.hashCode();

    hashCode = hashCode * 8191 + ((isSetModificationTime()) ? 131071 : 524287);
    if (isSetModificationTime())
      hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(modification_time);

    hashCode = hashCode * 8191 + ((isSetFileType()) ? 131071 : 524287);
    if (isSetFileType())
      hashCode = hashCode * 8191 + file_type.getValue();

    hashCode = hashCode * 8191 + ((isSetCompressType()) ? 131071 : 524287);
    if (isSetCompressType())
      hashCode = hashCode * 8191 + compress_type.getValue();

    hashCode = hashCode * 8191 + ((isSetFsName()) ? 131071 : 524287);
    if (isSetFsName())
      hashCode = hashCode * 8191 + fs_name.hashCode();

    hashCode = hashCode * 8191 + ((isSetFormatType()) ? 131071 : 524287);
    if (isSetFormatType())
      hashCode = hashCode * 8191 + format_type.getValue();

    hashCode = hashCode * 8191 + ((isSetSelfSplitWeight()) ? 131071 : 524287);
    if (isSetSelfSplitWeight())
      hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(self_split_weight);

    hashCode = hashCode * 8191 + ((isSetColumnsFromPathIsNull()) ? 131071 : 524287);
    if (isSetColumnsFromPathIsNull())
      hashCode = hashCode * 8191 + columns_from_path_is_null.hashCode();

    hashCode = hashCode * 8191 + ((isSetFileCacheAdmission()) ? 131071 : 524287);
    if (isSetFileCacheAdmission())
      hashCode = hashCode * 8191 + ((file_cache_admission) ? 131071 : 524287);

    return hashCode;
  }

  @Override
  public int compareTo(TFileRangeDesc other) {
    if (!getClass().equals(other.getClass())) {
      return getClass().getName().compareTo(other.getClass().getName());
    }

    int lastComparison = 0;

    lastComparison = java.lang.Boolean.compare(isSetLoadId(), other.isSetLoadId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLoadId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.load_id, other.load_id);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetPath(), other.isSetPath());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetPath()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.path, other.path);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetStartOffset(), other.isSetStartOffset());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetStartOffset()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.start_offset, other.start_offset);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetSize(), other.isSetSize());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSize()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.size, other.size);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetFileSize(), other.isSetFileSize());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFileSize()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.file_size, other.file_size);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetColumnsFromPath(), other.isSetColumnsFromPath());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetColumnsFromPath()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.columns_from_path, other.columns_from_path);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetColumnsFromPathKeys(), other.isSetColumnsFromPathKeys());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetColumnsFromPathKeys()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.columns_from_path_keys, other.columns_from_path_keys);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetTableFormatParams(), other.isSetTableFormatParams());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTableFormatParams()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.table_format_params, other.table_format_params);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetModificationTime(), other.isSetModificationTime());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetModificationTime()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.modification_time, other.modification_time);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetFileType(), other.isSetFileType());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFileType()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.file_type, other.file_type);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetCompressType(), other.isSetCompressType());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetCompressType()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.compress_type, other.compress_type);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetFsName(), other.isSetFsName());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFsName()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fs_name, other.fs_name);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetFormatType(), other.isSetFormatType());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFormatType()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.format_type, other.format_type);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetSelfSplitWeight(), other.isSetSelfSplitWeight());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSelfSplitWeight()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.self_split_weight, other.self_split_weight);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetColumnsFromPathIsNull(), other.isSetColumnsFromPathIsNull());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetColumnsFromPathIsNull()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.columns_from_path_is_null, other.columns_from_path_is_null);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetFileCacheAdmission(), other.isSetFileCacheAdmission());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetFileCacheAdmission()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.file_cache_admission, other.file_cache_admission);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    return 0;
  }

  @org.apache.thrift.annotation.Nullable
  public _Fields fieldForId(int fieldId) {
    return _Fields.findByThriftId(fieldId);
  }

  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
    scheme(iprot).read(iprot, this);
  }

  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
    scheme(oprot).write(oprot, this);
  }

  @Override
  public java.lang.String toString() {
    java.lang.StringBuilder sb = new java.lang.StringBuilder("TFileRangeDesc(");
    boolean first = true;

    if (isSetLoadId()) {
      sb.append("load_id:");
      if (this.load_id == null) {
        sb.append("null");
      } else {
        sb.append(this.load_id);
      }
      first = false;
    }
    if (isSetPath()) {
      if (!first) sb.append(", ");
      sb.append("path:");
      if (this.path == null) {
        sb.append("null");
      } else {
        sb.append(this.path);
      }
      first = false;
    }
    if (isSetStartOffset()) {
      if (!first) sb.append(", ");
      sb.append("start_offset:");
      sb.append(this.start_offset);
      first = false;
    }
    if (isSetSize()) {
      if (!first) sb.append(", ");
      sb.append("size:");
      sb.append(this.size);
      first = false;
    }
    if (isSetFileSize()) {
      if (!first) sb.append(", ");
      sb.append("file_size:");
      sb.append(this.file_size);
      first = false;
    }
    if (isSetColumnsFromPath()) {
      if (!first) sb.append(", ");
      sb.append("columns_from_path:");
      if (this.columns_from_path == null) {
        sb.append("null");
      } else {
        sb.append(this.columns_from_path);
      }
      first = false;
    }
    if (isSetColumnsFromPathKeys()) {
      if (!first) sb.append(", ");
      sb.append("columns_from_path_keys:");
      if (this.columns_from_path_keys == null) {
        sb.append("null");
      } else {
        sb.append(this.columns_from_path_keys);
      }
      first = false;
    }
    if (isSetTableFormatParams()) {
      if (!first) sb.append(", ");
      sb.append("table_format_params:");
      if (this.table_format_params == null) {
        sb.append("null");
      } else {
        sb.append(this.table_format_params);
      }
      first = false;
    }
    if (isSetModificationTime()) {
      if (!first) sb.append(", ");
      sb.append("modification_time:");
      sb.append(this.modification_time);
      first = false;
    }
    if (isSetFileType()) {
      if (!first) sb.append(", ");
      sb.append("file_type:");
      if (this.file_type == null) {
        sb.append("null");
      } else {
        sb.append(this.file_type);
      }
      first = false;
    }
    if (isSetCompressType()) {
      if (!first) sb.append(", ");
      sb.append("compress_type:");
      if (this.compress_type == null) {
        sb.append("null");
      } else {
        sb.append(this.compress_type);
      }
      first = false;
    }
    if (isSetFsName()) {
      if (!first) sb.append(", ");
      sb.append("fs_name:");
      if (this.fs_name == null) {
        sb.append("null");
      } else {
        sb.append(this.fs_name);
      }
      first = false;
    }
    if (isSetFormatType()) {
      if (!first) sb.append(", ");
      sb.append("format_type:");
      if (this.format_type == null) {
        sb.append("null");
      } else {
        sb.append(this.format_type);
      }
      first = false;
    }
    if (isSetSelfSplitWeight()) {
      if (!first) sb.append(", ");
      sb.append("self_split_weight:");
      sb.append(this.self_split_weight);
      first = false;
    }
    if (isSetColumnsFromPathIsNull()) {
      if (!first) sb.append(", ");
      sb.append("columns_from_path_is_null:");
      if (this.columns_from_path_is_null == null) {
        sb.append("null");
      } else {
        sb.append(this.columns_from_path_is_null);
      }
      first = false;
    }
    if (isSetFileCacheAdmission()) {
      if (!first) sb.append(", ");
      sb.append("file_cache_admission:");
      sb.append(this.file_cache_admission);
      first = false;
    }
    sb.append(")");
    return sb.toString();
  }

  public void validate() throws org.apache.thrift.TException {
    // check for required fields
    // check for sub-struct validity
    if (load_id != null) {
      load_id.validate();
    }
    if (table_format_params != null) {
      table_format_params.validate();
    }
  }

  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
    try {
      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
    try {
      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
      __isset_bitfield = 0;
      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
    } catch (org.apache.thrift.TException te) {
      throw new java.io.IOException(te);
    }
  }

  private static class TFileRangeDescStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
    public TFileRangeDescStandardScheme getScheme() {
      return new TFileRangeDescStandardScheme();
    }
  }

  private static class TFileRangeDescStandardScheme extends org.apache.thrift.scheme.StandardScheme<TFileRangeDesc> {

    public void read(org.apache.thrift.protocol.TProtocol iprot, TFileRangeDesc struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TField schemeField;
      iprot.readStructBegin();
      while (true)
      {
        schemeField = iprot.readFieldBegin();
        if (schemeField.type == org.apache.thrift.protocol.TType.STOP) { 
          break;
        }
        switch (schemeField.id) {
          case 1: // LOAD_ID
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.load_id = new org.apache.doris.thrift.TUniqueId();
              struct.load_id.read(iprot);
              struct.setLoadIdIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 2: // PATH
            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
              struct.path = iprot.readString();
              struct.setPathIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 3: // START_OFFSET
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.start_offset = iprot.readI64();
              struct.setStartOffsetIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 4: // SIZE
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.size = iprot.readI64();
              struct.setSizeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 5: // FILE_SIZE
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.file_size = iprot.readI64();
              struct.setFileSizeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 6: // COLUMNS_FROM_PATH
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list320 = iprot.readListBegin();
                struct.columns_from_path = new java.util.ArrayList<java.lang.String>(_list320.size);
                @org.apache.thrift.annotation.Nullable java.lang.String _elem321;
                for (int _i322 = 0; _i322 < _list320.size; ++_i322)
                {
                  _elem321 = iprot.readString();
                  struct.columns_from_path.add(_elem321);
                }
                iprot.readListEnd();
              }
              struct.setColumnsFromPathIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 7: // COLUMNS_FROM_PATH_KEYS
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list323 = iprot.readListBegin();
                struct.columns_from_path_keys = new java.util.ArrayList<java.lang.String>(_list323.size);
                @org.apache.thrift.annotation.Nullable java.lang.String _elem324;
                for (int _i325 = 0; _i325 < _list323.size; ++_i325)
                {
                  _elem324 = iprot.readString();
                  struct.columns_from_path_keys.add(_elem324);
                }
                iprot.readListEnd();
              }
              struct.setColumnsFromPathKeysIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 8: // TABLE_FORMAT_PARAMS
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.table_format_params = new TTableFormatFileDesc();
              struct.table_format_params.read(iprot);
              struct.setTableFormatParamsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 9: // MODIFICATION_TIME
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.modification_time = iprot.readI64();
              struct.setModificationTimeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 10: // FILE_TYPE
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.file_type = org.apache.doris.thrift.TFileType.findByValue(iprot.readI32());
              struct.setFileTypeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 11: // COMPRESS_TYPE
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.compress_type = org.apache.doris.thrift.TFileCompressType.findByValue(iprot.readI32());
              struct.setCompressTypeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 12: // FS_NAME
            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
              struct.fs_name = iprot.readString();
              struct.setFsNameIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 13: // FORMAT_TYPE
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.format_type = org.apache.doris.thrift.TFileFormatType.findByValue(iprot.readI32());
              struct.setFormatTypeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 14: // SELF_SPLIT_WEIGHT
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.self_split_weight = iprot.readI64();
              struct.setSelfSplitWeightIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 15: // COLUMNS_FROM_PATH_IS_NULL
            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
              {
                org.apache.thrift.protocol.TList _list326 = iprot.readListBegin();
                struct.columns_from_path_is_null = new java.util.ArrayList<java.lang.Boolean>(_list326.size);
                boolean _elem327;
                for (int _i328 = 0; _i328 < _list326.size; ++_i328)
                {
                  _elem327 = iprot.readBool();
                  struct.columns_from_path_is_null.add(_elem327);
                }
                iprot.readListEnd();
              }
              struct.setColumnsFromPathIsNullIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 16: // FILE_CACHE_ADMISSION
            if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
              struct.file_cache_admission = iprot.readBool();
              struct.setFileCacheAdmissionIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          default:
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
        }
        iprot.readFieldEnd();
      }
      iprot.readStructEnd();

      // check for required fields of primitive type, which can't be checked in the validate method
      struct.validate();
    }

    public void write(org.apache.thrift.protocol.TProtocol oprot, TFileRangeDesc struct) throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.load_id != null) {
        if (struct.isSetLoadId()) {
          oprot.writeFieldBegin(LOAD_ID_FIELD_DESC);
          struct.load_id.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.path != null) {
        if (struct.isSetPath()) {
          oprot.writeFieldBegin(PATH_FIELD_DESC);
          oprot.writeString(struct.path);
          oprot.writeFieldEnd();
        }
      }
      if (struct.isSetStartOffset()) {
        oprot.writeFieldBegin(START_OFFSET_FIELD_DESC);
        oprot.writeI64(struct.start_offset);
        oprot.writeFieldEnd();
      }
      if (struct.isSetSize()) {
        oprot.writeFieldBegin(SIZE_FIELD_DESC);
        oprot.writeI64(struct.size);
        oprot.writeFieldEnd();
      }
      if (struct.isSetFileSize()) {
        oprot.writeFieldBegin(FILE_SIZE_FIELD_DESC);
        oprot.writeI64(struct.file_size);
        oprot.writeFieldEnd();
      }
      if (struct.columns_from_path != null) {
        if (struct.isSetColumnsFromPath()) {
          oprot.writeFieldBegin(COLUMNS_FROM_PATH_FIELD_DESC);
          {
            oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.columns_from_path.size()));
            for (java.lang.String _iter329 : struct.columns_from_path)
            {
              oprot.writeString(_iter329);
            }
            oprot.writeListEnd();
          }
          oprot.writeFieldEnd();
        }
      }
      if (struct.columns_from_path_keys != null) {
        if (struct.isSetColumnsFromPathKeys()) {
          oprot.writeFieldBegin(COLUMNS_FROM_PATH_KEYS_FIELD_DESC);
          {
            oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.columns_from_path_keys.size()));
            for (java.lang.String _iter330 : struct.columns_from_path_keys)
            {
              oprot.writeString(_iter330);
            }
            oprot.writeListEnd();
          }
          oprot.writeFieldEnd();
        }
      }
      if (struct.table_format_params != null) {
        if (struct.isSetTableFormatParams()) {
          oprot.writeFieldBegin(TABLE_FORMAT_PARAMS_FIELD_DESC);
          struct.table_format_params.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.isSetModificationTime()) {
        oprot.writeFieldBegin(MODIFICATION_TIME_FIELD_DESC);
        oprot.writeI64(struct.modification_time);
        oprot.writeFieldEnd();
      }
      if (struct.file_type != null) {
        if (struct.isSetFileType()) {
          oprot.writeFieldBegin(FILE_TYPE_FIELD_DESC);
          oprot.writeI32(struct.file_type.getValue());
          oprot.writeFieldEnd();
        }
      }
      if (struct.compress_type != null) {
        if (struct.isSetCompressType()) {
          oprot.writeFieldBegin(COMPRESS_TYPE_FIELD_DESC);
          oprot.writeI32(struct.compress_type.getValue());
          oprot.writeFieldEnd();
        }
      }
      if (struct.fs_name != null) {
        if (struct.isSetFsName()) {
          oprot.writeFieldBegin(FS_NAME_FIELD_DESC);
          oprot.writeString(struct.fs_name);
          oprot.writeFieldEnd();
        }
      }
      if (struct.format_type != null) {
        if (struct.isSetFormatType()) {
          oprot.writeFieldBegin(FORMAT_TYPE_FIELD_DESC);
          oprot.writeI32(struct.format_type.getValue());
          oprot.writeFieldEnd();
        }
      }
      if (struct.isSetSelfSplitWeight()) {
        oprot.writeFieldBegin(SELF_SPLIT_WEIGHT_FIELD_DESC);
        oprot.writeI64(struct.self_split_weight);
        oprot.writeFieldEnd();
      }
      if (struct.columns_from_path_is_null != null) {
        if (struct.isSetColumnsFromPathIsNull()) {
          oprot.writeFieldBegin(COLUMNS_FROM_PATH_IS_NULL_FIELD_DESC);
          {
            oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.BOOL, struct.columns_from_path_is_null.size()));
            for (boolean _iter331 : struct.columns_from_path_is_null)
            {
              oprot.writeBool(_iter331);
            }
            oprot.writeListEnd();
          }
          oprot.writeFieldEnd();
        }
      }
      if (struct.isSetFileCacheAdmission()) {
        oprot.writeFieldBegin(FILE_CACHE_ADMISSION_FIELD_DESC);
        oprot.writeBool(struct.file_cache_admission);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }

  }

  private static class TFileRangeDescTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
    public TFileRangeDescTupleScheme getScheme() {
      return new TFileRangeDescTupleScheme();
    }
  }

  private static class TFileRangeDescTupleScheme extends org.apache.thrift.scheme.TupleScheme<TFileRangeDesc> {

    @Override
    public void write(org.apache.thrift.protocol.TProtocol prot, TFileRangeDesc struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      java.util.BitSet optionals = new java.util.BitSet();
      if (struct.isSetLoadId()) {
        optionals.set(0);
      }
      if (struct.isSetPath()) {
        optionals.set(1);
      }
      if (struct.isSetStartOffset()) {
        optionals.set(2);
      }
      if (struct.isSetSize()) {
        optionals.set(3);
      }
      if (struct.isSetFileSize()) {
        optionals.set(4);
      }
      if (struct.isSetColumnsFromPath()) {
        optionals.set(5);
      }
      if (struct.isSetColumnsFromPathKeys()) {
        optionals.set(6);
      }
      if (struct.isSetTableFormatParams()) {
        optionals.set(7);
      }
      if (struct.isSetModificationTime()) {
        optionals.set(8);
      }
      if (struct.isSetFileType()) {
        optionals.set(9);
      }
      if (struct.isSetCompressType()) {
        optionals.set(10);
      }
      if (struct.isSetFsName()) {
        optionals.set(11);
      }
      if (struct.isSetFormatType()) {
        optionals.set(12);
      }
      if (struct.isSetSelfSplitWeight()) {
        optionals.set(13);
      }
      if (struct.isSetColumnsFromPathIsNull()) {
        optionals.set(14);
      }
      if (struct.isSetFileCacheAdmission()) {
        optionals.set(15);
      }
      oprot.writeBitSet(optionals, 16);
      if (struct.isSetLoadId()) {
        struct.load_id.write(oprot);
      }
      if (struct.isSetPath()) {
        oprot.writeString(struct.path);
      }
      if (struct.isSetStartOffset()) {
        oprot.writeI64(struct.start_offset);
      }
      if (struct.isSetSize()) {
        oprot.writeI64(struct.size);
      }
      if (struct.isSetFileSize()) {
        oprot.writeI64(struct.file_size);
      }
      if (struct.isSetColumnsFromPath()) {
        {
          oprot.writeI32(struct.columns_from_path.size());
          for (java.lang.String _iter332 : struct.columns_from_path)
          {
            oprot.writeString(_iter332);
          }
        }
      }
      if (struct.isSetColumnsFromPathKeys()) {
        {
          oprot.writeI32(struct.columns_from_path_keys.size());
          for (java.lang.String _iter333 : struct.columns_from_path_keys)
          {
            oprot.writeString(_iter333);
          }
        }
      }
      if (struct.isSetTableFormatParams()) {
        struct.table_format_params.write(oprot);
      }
      if (struct.isSetModificationTime()) {
        oprot.writeI64(struct.modification_time);
      }
      if (struct.isSetFileType()) {
        oprot.writeI32(struct.file_type.getValue());
      }
      if (struct.isSetCompressType()) {
        oprot.writeI32(struct.compress_type.getValue());
      }
      if (struct.isSetFsName()) {
        oprot.writeString(struct.fs_name);
      }
      if (struct.isSetFormatType()) {
        oprot.writeI32(struct.format_type.getValue());
      }
      if (struct.isSetSelfSplitWeight()) {
        oprot.writeI64(struct.self_split_weight);
      }
      if (struct.isSetColumnsFromPathIsNull()) {
        {
          oprot.writeI32(struct.columns_from_path_is_null.size());
          for (boolean _iter334 : struct.columns_from_path_is_null)
          {
            oprot.writeBool(_iter334);
          }
        }
      }
      if (struct.isSetFileCacheAdmission()) {
        oprot.writeBool(struct.file_cache_admission);
      }
    }

    @Override
    public void read(org.apache.thrift.protocol.TProtocol prot, TFileRangeDesc struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      java.util.BitSet incoming = iprot.readBitSet(16);
      if (incoming.get(0)) {
        struct.load_id = new org.apache.doris.thrift.TUniqueId();
        struct.load_id.read(iprot);
        struct.setLoadIdIsSet(true);
      }
      if (incoming.get(1)) {
        struct.path = iprot.readString();
        struct.setPathIsSet(true);
      }
      if (incoming.get(2)) {
        struct.start_offset = iprot.readI64();
        struct.setStartOffsetIsSet(true);
      }
      if (incoming.get(3)) {
        struct.size = iprot.readI64();
        struct.setSizeIsSet(true);
      }
      if (incoming.get(4)) {
        struct.file_size = iprot.readI64();
        struct.setFileSizeIsSet(true);
      }
      if (incoming.get(5)) {
        {
          org.apache.thrift.protocol.TList _list335 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
          struct.columns_from_path = new java.util.ArrayList<java.lang.String>(_list335.size);
          @org.apache.thrift.annotation.Nullable java.lang.String _elem336;
          for (int _i337 = 0; _i337 < _list335.size; ++_i337)
          {
            _elem336 = iprot.readString();
            struct.columns_from_path.add(_elem336);
          }
        }
        struct.setColumnsFromPathIsSet(true);
      }
      if (incoming.get(6)) {
        {
          org.apache.thrift.protocol.TList _list338 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
          struct.columns_from_path_keys = new java.util.ArrayList<java.lang.String>(_list338.size);
          @org.apache.thrift.annotation.Nullable java.lang.String _elem339;
          for (int _i340 = 0; _i340 < _list338.size; ++_i340)
          {
            _elem339 = iprot.readString();
            struct.columns_from_path_keys.add(_elem339);
          }
        }
        struct.setColumnsFromPathKeysIsSet(true);
      }
      if (incoming.get(7)) {
        struct.table_format_params = new TTableFormatFileDesc();
        struct.table_format_params.read(iprot);
        struct.setTableFormatParamsIsSet(true);
      }
      if (incoming.get(8)) {
        struct.modification_time = iprot.readI64();
        struct.setModificationTimeIsSet(true);
      }
      if (incoming.get(9)) {
        struct.file_type = org.apache.doris.thrift.TFileType.findByValue(iprot.readI32());
        struct.setFileTypeIsSet(true);
      }
      if (incoming.get(10)) {
        struct.compress_type = org.apache.doris.thrift.TFileCompressType.findByValue(iprot.readI32());
        struct.setCompressTypeIsSet(true);
      }
      if (incoming.get(11)) {
        struct.fs_name = iprot.readString();
        struct.setFsNameIsSet(true);
      }
      if (incoming.get(12)) {
        struct.format_type = org.apache.doris.thrift.TFileFormatType.findByValue(iprot.readI32());
        struct.setFormatTypeIsSet(true);
      }
      if (incoming.get(13)) {
        struct.self_split_weight = iprot.readI64();
        struct.setSelfSplitWeightIsSet(true);
      }
      if (incoming.get(14)) {
        {
          org.apache.thrift.protocol.TList _list341 = iprot.readListBegin(org.apache.thrift.protocol.TType.BOOL);
          struct.columns_from_path_is_null = new java.util.ArrayList<java.lang.Boolean>(_list341.size);
          boolean _elem342;
          for (int _i343 = 0; _i343 < _list341.size; ++_i343)
          {
            _elem342 = iprot.readBool();
            struct.columns_from_path_is_null.add(_elem342);
          }
        }
        struct.setColumnsFromPathIsNullIsSet(true);
      }
      if (incoming.get(15)) {
        struct.file_cache_admission = iprot.readBool();
        struct.setFileCacheAdmissionIsSet(true);
      }
    }
  }

  private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
    return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
  }
}