TTableDescriptor.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 TTableDescriptor implements org.apache.thrift.TBase<TTableDescriptor, TTableDescriptor._Fields>, java.io.Serializable, Cloneable, Comparable<TTableDescriptor> {
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TTableDescriptor");

  private static final org.apache.thrift.protocol.TField ID_FIELD_DESC = new org.apache.thrift.protocol.TField("id", org.apache.thrift.protocol.TType.I64, (short)1);
  private static final org.apache.thrift.protocol.TField TABLE_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("tableType", org.apache.thrift.protocol.TType.I32, (short)2);
  private static final org.apache.thrift.protocol.TField NUM_COLS_FIELD_DESC = new org.apache.thrift.protocol.TField("numCols", org.apache.thrift.protocol.TType.I32, (short)3);
  private static final org.apache.thrift.protocol.TField NUM_CLUSTERING_COLS_FIELD_DESC = new org.apache.thrift.protocol.TField("numClusteringCols", org.apache.thrift.protocol.TType.I32, (short)4);
  private static final org.apache.thrift.protocol.TField TABLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("tableName", org.apache.thrift.protocol.TType.STRING, (short)7);
  private static final org.apache.thrift.protocol.TField DB_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("dbName", org.apache.thrift.protocol.TType.STRING, (short)8);
  private static final org.apache.thrift.protocol.TField MYSQL_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("mysqlTable", org.apache.thrift.protocol.TType.STRUCT, (short)10);
  private static final org.apache.thrift.protocol.TField OLAP_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("olapTable", org.apache.thrift.protocol.TType.STRUCT, (short)11);
  private static final org.apache.thrift.protocol.TField SCHEMA_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("schemaTable", org.apache.thrift.protocol.TType.STRUCT, (short)12);
  private static final org.apache.thrift.protocol.TField BROKER_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("BrokerTable", org.apache.thrift.protocol.TType.STRUCT, (short)14);
  private static final org.apache.thrift.protocol.TField ES_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("esTable", org.apache.thrift.protocol.TType.STRUCT, (short)15);
  private static final org.apache.thrift.protocol.TField ODBC_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("odbcTable", org.apache.thrift.protocol.TType.STRUCT, (short)16);
  private static final org.apache.thrift.protocol.TField HIVE_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("hiveTable", org.apache.thrift.protocol.TType.STRUCT, (short)17);
  private static final org.apache.thrift.protocol.TField ICEBERG_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("icebergTable", org.apache.thrift.protocol.TType.STRUCT, (short)18);
  private static final org.apache.thrift.protocol.TField HUDI_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("hudiTable", org.apache.thrift.protocol.TType.STRUCT, (short)19);
  private static final org.apache.thrift.protocol.TField JDBC_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("jdbcTable", org.apache.thrift.protocol.TType.STRUCT, (short)20);
  private static final org.apache.thrift.protocol.TField MC_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("mcTable", org.apache.thrift.protocol.TType.STRUCT, (short)21);
  private static final org.apache.thrift.protocol.TField TRINO_CONNECTOR_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("trinoConnectorTable", org.apache.thrift.protocol.TType.STRUCT, (short)22);
  private static final org.apache.thrift.protocol.TField LAKESOUL_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("lakesoulTable", org.apache.thrift.protocol.TType.STRUCT, (short)23);
  private static final org.apache.thrift.protocol.TField DICTIONARY_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("dictionaryTable", org.apache.thrift.protocol.TType.STRUCT, (short)24);
  private static final org.apache.thrift.protocol.TField REMOTE_DORIS_TABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("remoteDorisTable", org.apache.thrift.protocol.TType.STRUCT, (short)25);

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

  public long id; // required
  /**
   * 
   * @see org.apache.doris.thrift.TTableType
   */
  public @org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TTableType tableType; // required
  public int numCols; // required
  public int numClusteringCols; // required
  public @org.apache.thrift.annotation.Nullable java.lang.String tableName; // required
  public @org.apache.thrift.annotation.Nullable java.lang.String dbName; // required
  public @org.apache.thrift.annotation.Nullable TMySQLTable mysqlTable; // optional
  public @org.apache.thrift.annotation.Nullable TOlapTable olapTable; // optional
  public @org.apache.thrift.annotation.Nullable TSchemaTable schemaTable; // optional
  public @org.apache.thrift.annotation.Nullable TBrokerTable BrokerTable; // optional
  public @org.apache.thrift.annotation.Nullable TEsTable esTable; // optional
  public @org.apache.thrift.annotation.Nullable TOdbcTable odbcTable; // optional
  public @org.apache.thrift.annotation.Nullable THiveTable hiveTable; // optional
  public @org.apache.thrift.annotation.Nullable TIcebergTable icebergTable; // optional
  public @org.apache.thrift.annotation.Nullable THudiTable hudiTable; // optional
  public @org.apache.thrift.annotation.Nullable TJdbcTable jdbcTable; // optional
  public @org.apache.thrift.annotation.Nullable TMCTable mcTable; // optional
  public @org.apache.thrift.annotation.Nullable TTrinoConnectorTable trinoConnectorTable; // optional
  public @org.apache.thrift.annotation.Nullable TLakeSoulTable lakesoulTable; // optional
  public @org.apache.thrift.annotation.Nullable TDictionaryTable dictionaryTable; // optional
  public @org.apache.thrift.annotation.Nullable TRemoteDorisTable remoteDorisTable; // 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 {
    ID((short)1, "id"),
    /**
     * 
     * @see org.apache.doris.thrift.TTableType
     */
    TABLE_TYPE((short)2, "tableType"),
    NUM_COLS((short)3, "numCols"),
    NUM_CLUSTERING_COLS((short)4, "numClusteringCols"),
    TABLE_NAME((short)7, "tableName"),
    DB_NAME((short)8, "dbName"),
    MYSQL_TABLE((short)10, "mysqlTable"),
    OLAP_TABLE((short)11, "olapTable"),
    SCHEMA_TABLE((short)12, "schemaTable"),
    BROKER_TABLE((short)14, "BrokerTable"),
    ES_TABLE((short)15, "esTable"),
    ODBC_TABLE((short)16, "odbcTable"),
    HIVE_TABLE((short)17, "hiveTable"),
    ICEBERG_TABLE((short)18, "icebergTable"),
    HUDI_TABLE((short)19, "hudiTable"),
    JDBC_TABLE((short)20, "jdbcTable"),
    MC_TABLE((short)21, "mcTable"),
    TRINO_CONNECTOR_TABLE((short)22, "trinoConnectorTable"),
    LAKESOUL_TABLE((short)23, "lakesoulTable"),
    DICTIONARY_TABLE((short)24, "dictionaryTable"),
    REMOTE_DORIS_TABLE((short)25, "remoteDorisTable");

    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: // ID
          return ID;
        case 2: // TABLE_TYPE
          return TABLE_TYPE;
        case 3: // NUM_COLS
          return NUM_COLS;
        case 4: // NUM_CLUSTERING_COLS
          return NUM_CLUSTERING_COLS;
        case 7: // TABLE_NAME
          return TABLE_NAME;
        case 8: // DB_NAME
          return DB_NAME;
        case 10: // MYSQL_TABLE
          return MYSQL_TABLE;
        case 11: // OLAP_TABLE
          return OLAP_TABLE;
        case 12: // SCHEMA_TABLE
          return SCHEMA_TABLE;
        case 14: // BROKER_TABLE
          return BROKER_TABLE;
        case 15: // ES_TABLE
          return ES_TABLE;
        case 16: // ODBC_TABLE
          return ODBC_TABLE;
        case 17: // HIVE_TABLE
          return HIVE_TABLE;
        case 18: // ICEBERG_TABLE
          return ICEBERG_TABLE;
        case 19: // HUDI_TABLE
          return HUDI_TABLE;
        case 20: // JDBC_TABLE
          return JDBC_TABLE;
        case 21: // MC_TABLE
          return MC_TABLE;
        case 22: // TRINO_CONNECTOR_TABLE
          return TRINO_CONNECTOR_TABLE;
        case 23: // LAKESOUL_TABLE
          return LAKESOUL_TABLE;
        case 24: // DICTIONARY_TABLE
          return DICTIONARY_TABLE;
        case 25: // REMOTE_DORIS_TABLE
          return REMOTE_DORIS_TABLE;
        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 __ID_ISSET_ID = 0;
  private static final int __NUMCOLS_ISSET_ID = 1;
  private static final int __NUMCLUSTERINGCOLS_ISSET_ID = 2;
  private byte __isset_bitfield = 0;
  private static final _Fields optionals[] = {_Fields.MYSQL_TABLE,_Fields.OLAP_TABLE,_Fields.SCHEMA_TABLE,_Fields.BROKER_TABLE,_Fields.ES_TABLE,_Fields.ODBC_TABLE,_Fields.HIVE_TABLE,_Fields.ICEBERG_TABLE,_Fields.HUDI_TABLE,_Fields.JDBC_TABLE,_Fields.MC_TABLE,_Fields.TRINO_CONNECTOR_TABLE,_Fields.LAKESOUL_TABLE,_Fields.DICTIONARY_TABLE,_Fields.REMOTE_DORIS_TABLE};
  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.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64        , "TTableId")));
    tmpMap.put(_Fields.TABLE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("tableType", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, org.apache.doris.thrift.TTableType.class)));
    tmpMap.put(_Fields.NUM_COLS, new org.apache.thrift.meta_data.FieldMetaData("numCols", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
    tmpMap.put(_Fields.NUM_CLUSTERING_COLS, new org.apache.thrift.meta_data.FieldMetaData("numClusteringCols", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
    tmpMap.put(_Fields.TABLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("tableName", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.DB_NAME, new org.apache.thrift.meta_data.FieldMetaData("dbName", org.apache.thrift.TFieldRequirementType.REQUIRED, 
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
    tmpMap.put(_Fields.MYSQL_TABLE, new org.apache.thrift.meta_data.FieldMetaData("mysqlTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TMySQLTable.class)));
    tmpMap.put(_Fields.OLAP_TABLE, new org.apache.thrift.meta_data.FieldMetaData("olapTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TOlapTable.class)));
    tmpMap.put(_Fields.SCHEMA_TABLE, new org.apache.thrift.meta_data.FieldMetaData("schemaTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TSchemaTable.class)));
    tmpMap.put(_Fields.BROKER_TABLE, new org.apache.thrift.meta_data.FieldMetaData("BrokerTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TBrokerTable.class)));
    tmpMap.put(_Fields.ES_TABLE, new org.apache.thrift.meta_data.FieldMetaData("esTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TEsTable.class)));
    tmpMap.put(_Fields.ODBC_TABLE, new org.apache.thrift.meta_data.FieldMetaData("odbcTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TOdbcTable.class)));
    tmpMap.put(_Fields.HIVE_TABLE, new org.apache.thrift.meta_data.FieldMetaData("hiveTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, THiveTable.class)));
    tmpMap.put(_Fields.ICEBERG_TABLE, new org.apache.thrift.meta_data.FieldMetaData("icebergTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TIcebergTable.class)));
    tmpMap.put(_Fields.HUDI_TABLE, new org.apache.thrift.meta_data.FieldMetaData("hudiTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, THudiTable.class)));
    tmpMap.put(_Fields.JDBC_TABLE, new org.apache.thrift.meta_data.FieldMetaData("jdbcTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TJdbcTable.class)));
    tmpMap.put(_Fields.MC_TABLE, new org.apache.thrift.meta_data.FieldMetaData("mcTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TMCTable.class)));
    tmpMap.put(_Fields.TRINO_CONNECTOR_TABLE, new org.apache.thrift.meta_data.FieldMetaData("trinoConnectorTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TTrinoConnectorTable.class)));
    tmpMap.put(_Fields.LAKESOUL_TABLE, new org.apache.thrift.meta_data.FieldMetaData("lakesoulTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TLakeSoulTable.class)));
    tmpMap.put(_Fields.DICTIONARY_TABLE, new org.apache.thrift.meta_data.FieldMetaData("dictionaryTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TDictionaryTable.class)));
    tmpMap.put(_Fields.REMOTE_DORIS_TABLE, new org.apache.thrift.meta_data.FieldMetaData("remoteDorisTable", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TRemoteDorisTable.class)));
    metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TTableDescriptor.class, metaDataMap);
  }

  public TTableDescriptor() {
  }

  public TTableDescriptor(
    long id,
    org.apache.doris.thrift.TTableType tableType,
    int numCols,
    int numClusteringCols,
    java.lang.String tableName,
    java.lang.String dbName)
  {
    this();
    this.id = id;
    setIdIsSet(true);
    this.tableType = tableType;
    this.numCols = numCols;
    setNumColsIsSet(true);
    this.numClusteringCols = numClusteringCols;
    setNumClusteringColsIsSet(true);
    this.tableName = tableName;
    this.dbName = dbName;
  }

  /**
   * Performs a deep copy on <i>other</i>.
   */
  public TTableDescriptor(TTableDescriptor other) {
    __isset_bitfield = other.__isset_bitfield;
    this.id = other.id;
    if (other.isSetTableType()) {
      this.tableType = other.tableType;
    }
    this.numCols = other.numCols;
    this.numClusteringCols = other.numClusteringCols;
    if (other.isSetTableName()) {
      this.tableName = other.tableName;
    }
    if (other.isSetDbName()) {
      this.dbName = other.dbName;
    }
    if (other.isSetMysqlTable()) {
      this.mysqlTable = new TMySQLTable(other.mysqlTable);
    }
    if (other.isSetOlapTable()) {
      this.olapTable = new TOlapTable(other.olapTable);
    }
    if (other.isSetSchemaTable()) {
      this.schemaTable = new TSchemaTable(other.schemaTable);
    }
    if (other.isSetBrokerTable()) {
      this.BrokerTable = new TBrokerTable(other.BrokerTable);
    }
    if (other.isSetEsTable()) {
      this.esTable = new TEsTable(other.esTable);
    }
    if (other.isSetOdbcTable()) {
      this.odbcTable = new TOdbcTable(other.odbcTable);
    }
    if (other.isSetHiveTable()) {
      this.hiveTable = new THiveTable(other.hiveTable);
    }
    if (other.isSetIcebergTable()) {
      this.icebergTable = new TIcebergTable(other.icebergTable);
    }
    if (other.isSetHudiTable()) {
      this.hudiTable = new THudiTable(other.hudiTable);
    }
    if (other.isSetJdbcTable()) {
      this.jdbcTable = new TJdbcTable(other.jdbcTable);
    }
    if (other.isSetMcTable()) {
      this.mcTable = new TMCTable(other.mcTable);
    }
    if (other.isSetTrinoConnectorTable()) {
      this.trinoConnectorTable = new TTrinoConnectorTable(other.trinoConnectorTable);
    }
    if (other.isSetLakesoulTable()) {
      this.lakesoulTable = new TLakeSoulTable(other.lakesoulTable);
    }
    if (other.isSetDictionaryTable()) {
      this.dictionaryTable = new TDictionaryTable(other.dictionaryTable);
    }
    if (other.isSetRemoteDorisTable()) {
      this.remoteDorisTable = new TRemoteDorisTable(other.remoteDorisTable);
    }
  }

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

  @Override
  public void clear() {
    setIdIsSet(false);
    this.id = 0;
    this.tableType = null;
    setNumColsIsSet(false);
    this.numCols = 0;
    setNumClusteringColsIsSet(false);
    this.numClusteringCols = 0;
    this.tableName = null;
    this.dbName = null;
    this.mysqlTable = null;
    this.olapTable = null;
    this.schemaTable = null;
    this.BrokerTable = null;
    this.esTable = null;
    this.odbcTable = null;
    this.hiveTable = null;
    this.icebergTable = null;
    this.hudiTable = null;
    this.jdbcTable = null;
    this.mcTable = null;
    this.trinoConnectorTable = null;
    this.lakesoulTable = null;
    this.dictionaryTable = null;
    this.remoteDorisTable = null;
  }

  public long getId() {
    return this.id;
  }

  public TTableDescriptor setId(long id) {
    this.id = id;
    setIdIsSet(true);
    return this;
  }

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

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

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

  /**
   * 
   * @see org.apache.doris.thrift.TTableType
   */
  @org.apache.thrift.annotation.Nullable
  public org.apache.doris.thrift.TTableType getTableType() {
    return this.tableType;
  }

  /**
   * 
   * @see org.apache.doris.thrift.TTableType
   */
  public TTableDescriptor setTableType(@org.apache.thrift.annotation.Nullable org.apache.doris.thrift.TTableType tableType) {
    this.tableType = tableType;
    return this;
  }

  public void unsetTableType() {
    this.tableType = null;
  }

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

  public void setTableTypeIsSet(boolean value) {
    if (!value) {
      this.tableType = null;
    }
  }

  public int getNumCols() {
    return this.numCols;
  }

  public TTableDescriptor setNumCols(int numCols) {
    this.numCols = numCols;
    setNumColsIsSet(true);
    return this;
  }

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

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

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

  public int getNumClusteringCols() {
    return this.numClusteringCols;
  }

  public TTableDescriptor setNumClusteringCols(int numClusteringCols) {
    this.numClusteringCols = numClusteringCols;
    setNumClusteringColsIsSet(true);
    return this;
  }

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

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

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

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

  public TTableDescriptor setTableName(@org.apache.thrift.annotation.Nullable java.lang.String tableName) {
    this.tableName = tableName;
    return this;
  }

  public void unsetTableName() {
    this.tableName = null;
  }

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

  public void setTableNameIsSet(boolean value) {
    if (!value) {
      this.tableName = null;
    }
  }

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

  public TTableDescriptor setDbName(@org.apache.thrift.annotation.Nullable java.lang.String dbName) {
    this.dbName = dbName;
    return this;
  }

  public void unsetDbName() {
    this.dbName = null;
  }

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

  public void setDbNameIsSet(boolean value) {
    if (!value) {
      this.dbName = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TMySQLTable getMysqlTable() {
    return this.mysqlTable;
  }

  public TTableDescriptor setMysqlTable(@org.apache.thrift.annotation.Nullable TMySQLTable mysqlTable) {
    this.mysqlTable = mysqlTable;
    return this;
  }

  public void unsetMysqlTable() {
    this.mysqlTable = null;
  }

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

  public void setMysqlTableIsSet(boolean value) {
    if (!value) {
      this.mysqlTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TOlapTable getOlapTable() {
    return this.olapTable;
  }

  public TTableDescriptor setOlapTable(@org.apache.thrift.annotation.Nullable TOlapTable olapTable) {
    this.olapTable = olapTable;
    return this;
  }

  public void unsetOlapTable() {
    this.olapTable = null;
  }

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

  public void setOlapTableIsSet(boolean value) {
    if (!value) {
      this.olapTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TSchemaTable getSchemaTable() {
    return this.schemaTable;
  }

  public TTableDescriptor setSchemaTable(@org.apache.thrift.annotation.Nullable TSchemaTable schemaTable) {
    this.schemaTable = schemaTable;
    return this;
  }

  public void unsetSchemaTable() {
    this.schemaTable = null;
  }

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

  public void setSchemaTableIsSet(boolean value) {
    if (!value) {
      this.schemaTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TBrokerTable getBrokerTable() {
    return this.BrokerTable;
  }

  public TTableDescriptor setBrokerTable(@org.apache.thrift.annotation.Nullable TBrokerTable BrokerTable) {
    this.BrokerTable = BrokerTable;
    return this;
  }

  public void unsetBrokerTable() {
    this.BrokerTable = null;
  }

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

  public void setBrokerTableIsSet(boolean value) {
    if (!value) {
      this.BrokerTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TEsTable getEsTable() {
    return this.esTable;
  }

  public TTableDescriptor setEsTable(@org.apache.thrift.annotation.Nullable TEsTable esTable) {
    this.esTable = esTable;
    return this;
  }

  public void unsetEsTable() {
    this.esTable = null;
  }

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

  public void setEsTableIsSet(boolean value) {
    if (!value) {
      this.esTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TOdbcTable getOdbcTable() {
    return this.odbcTable;
  }

  public TTableDescriptor setOdbcTable(@org.apache.thrift.annotation.Nullable TOdbcTable odbcTable) {
    this.odbcTable = odbcTable;
    return this;
  }

  public void unsetOdbcTable() {
    this.odbcTable = null;
  }

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

  public void setOdbcTableIsSet(boolean value) {
    if (!value) {
      this.odbcTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public THiveTable getHiveTable() {
    return this.hiveTable;
  }

  public TTableDescriptor setHiveTable(@org.apache.thrift.annotation.Nullable THiveTable hiveTable) {
    this.hiveTable = hiveTable;
    return this;
  }

  public void unsetHiveTable() {
    this.hiveTable = null;
  }

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

  public void setHiveTableIsSet(boolean value) {
    if (!value) {
      this.hiveTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TIcebergTable getIcebergTable() {
    return this.icebergTable;
  }

  public TTableDescriptor setIcebergTable(@org.apache.thrift.annotation.Nullable TIcebergTable icebergTable) {
    this.icebergTable = icebergTable;
    return this;
  }

  public void unsetIcebergTable() {
    this.icebergTable = null;
  }

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

  public void setIcebergTableIsSet(boolean value) {
    if (!value) {
      this.icebergTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public THudiTable getHudiTable() {
    return this.hudiTable;
  }

  public TTableDescriptor setHudiTable(@org.apache.thrift.annotation.Nullable THudiTable hudiTable) {
    this.hudiTable = hudiTable;
    return this;
  }

  public void unsetHudiTable() {
    this.hudiTable = null;
  }

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

  public void setHudiTableIsSet(boolean value) {
    if (!value) {
      this.hudiTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TJdbcTable getJdbcTable() {
    return this.jdbcTable;
  }

  public TTableDescriptor setJdbcTable(@org.apache.thrift.annotation.Nullable TJdbcTable jdbcTable) {
    this.jdbcTable = jdbcTable;
    return this;
  }

  public void unsetJdbcTable() {
    this.jdbcTable = null;
  }

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

  public void setJdbcTableIsSet(boolean value) {
    if (!value) {
      this.jdbcTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TMCTable getMcTable() {
    return this.mcTable;
  }

  public TTableDescriptor setMcTable(@org.apache.thrift.annotation.Nullable TMCTable mcTable) {
    this.mcTable = mcTable;
    return this;
  }

  public void unsetMcTable() {
    this.mcTable = null;
  }

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

  public void setMcTableIsSet(boolean value) {
    if (!value) {
      this.mcTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TTrinoConnectorTable getTrinoConnectorTable() {
    return this.trinoConnectorTable;
  }

  public TTableDescriptor setTrinoConnectorTable(@org.apache.thrift.annotation.Nullable TTrinoConnectorTable trinoConnectorTable) {
    this.trinoConnectorTable = trinoConnectorTable;
    return this;
  }

  public void unsetTrinoConnectorTable() {
    this.trinoConnectorTable = null;
  }

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

  public void setTrinoConnectorTableIsSet(boolean value) {
    if (!value) {
      this.trinoConnectorTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TLakeSoulTable getLakesoulTable() {
    return this.lakesoulTable;
  }

  public TTableDescriptor setLakesoulTable(@org.apache.thrift.annotation.Nullable TLakeSoulTable lakesoulTable) {
    this.lakesoulTable = lakesoulTable;
    return this;
  }

  public void unsetLakesoulTable() {
    this.lakesoulTable = null;
  }

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

  public void setLakesoulTableIsSet(boolean value) {
    if (!value) {
      this.lakesoulTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TDictionaryTable getDictionaryTable() {
    return this.dictionaryTable;
  }

  public TTableDescriptor setDictionaryTable(@org.apache.thrift.annotation.Nullable TDictionaryTable dictionaryTable) {
    this.dictionaryTable = dictionaryTable;
    return this;
  }

  public void unsetDictionaryTable() {
    this.dictionaryTable = null;
  }

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

  public void setDictionaryTableIsSet(boolean value) {
    if (!value) {
      this.dictionaryTable = null;
    }
  }

  @org.apache.thrift.annotation.Nullable
  public TRemoteDorisTable getRemoteDorisTable() {
    return this.remoteDorisTable;
  }

  public TTableDescriptor setRemoteDorisTable(@org.apache.thrift.annotation.Nullable TRemoteDorisTable remoteDorisTable) {
    this.remoteDorisTable = remoteDorisTable;
    return this;
  }

  public void unsetRemoteDorisTable() {
    this.remoteDorisTable = null;
  }

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

  public void setRemoteDorisTableIsSet(boolean value) {
    if (!value) {
      this.remoteDorisTable = null;
    }
  }

  public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
    switch (field) {
    case ID:
      if (value == null) {
        unsetId();
      } else {
        setId((java.lang.Long)value);
      }
      break;

    case TABLE_TYPE:
      if (value == null) {
        unsetTableType();
      } else {
        setTableType((org.apache.doris.thrift.TTableType)value);
      }
      break;

    case NUM_COLS:
      if (value == null) {
        unsetNumCols();
      } else {
        setNumCols((java.lang.Integer)value);
      }
      break;

    case NUM_CLUSTERING_COLS:
      if (value == null) {
        unsetNumClusteringCols();
      } else {
        setNumClusteringCols((java.lang.Integer)value);
      }
      break;

    case TABLE_NAME:
      if (value == null) {
        unsetTableName();
      } else {
        setTableName((java.lang.String)value);
      }
      break;

    case DB_NAME:
      if (value == null) {
        unsetDbName();
      } else {
        setDbName((java.lang.String)value);
      }
      break;

    case MYSQL_TABLE:
      if (value == null) {
        unsetMysqlTable();
      } else {
        setMysqlTable((TMySQLTable)value);
      }
      break;

    case OLAP_TABLE:
      if (value == null) {
        unsetOlapTable();
      } else {
        setOlapTable((TOlapTable)value);
      }
      break;

    case SCHEMA_TABLE:
      if (value == null) {
        unsetSchemaTable();
      } else {
        setSchemaTable((TSchemaTable)value);
      }
      break;

    case BROKER_TABLE:
      if (value == null) {
        unsetBrokerTable();
      } else {
        setBrokerTable((TBrokerTable)value);
      }
      break;

    case ES_TABLE:
      if (value == null) {
        unsetEsTable();
      } else {
        setEsTable((TEsTable)value);
      }
      break;

    case ODBC_TABLE:
      if (value == null) {
        unsetOdbcTable();
      } else {
        setOdbcTable((TOdbcTable)value);
      }
      break;

    case HIVE_TABLE:
      if (value == null) {
        unsetHiveTable();
      } else {
        setHiveTable((THiveTable)value);
      }
      break;

    case ICEBERG_TABLE:
      if (value == null) {
        unsetIcebergTable();
      } else {
        setIcebergTable((TIcebergTable)value);
      }
      break;

    case HUDI_TABLE:
      if (value == null) {
        unsetHudiTable();
      } else {
        setHudiTable((THudiTable)value);
      }
      break;

    case JDBC_TABLE:
      if (value == null) {
        unsetJdbcTable();
      } else {
        setJdbcTable((TJdbcTable)value);
      }
      break;

    case MC_TABLE:
      if (value == null) {
        unsetMcTable();
      } else {
        setMcTable((TMCTable)value);
      }
      break;

    case TRINO_CONNECTOR_TABLE:
      if (value == null) {
        unsetTrinoConnectorTable();
      } else {
        setTrinoConnectorTable((TTrinoConnectorTable)value);
      }
      break;

    case LAKESOUL_TABLE:
      if (value == null) {
        unsetLakesoulTable();
      } else {
        setLakesoulTable((TLakeSoulTable)value);
      }
      break;

    case DICTIONARY_TABLE:
      if (value == null) {
        unsetDictionaryTable();
      } else {
        setDictionaryTable((TDictionaryTable)value);
      }
      break;

    case REMOTE_DORIS_TABLE:
      if (value == null) {
        unsetRemoteDorisTable();
      } else {
        setRemoteDorisTable((TRemoteDorisTable)value);
      }
      break;

    }
  }

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

    case TABLE_TYPE:
      return getTableType();

    case NUM_COLS:
      return getNumCols();

    case NUM_CLUSTERING_COLS:
      return getNumClusteringCols();

    case TABLE_NAME:
      return getTableName();

    case DB_NAME:
      return getDbName();

    case MYSQL_TABLE:
      return getMysqlTable();

    case OLAP_TABLE:
      return getOlapTable();

    case SCHEMA_TABLE:
      return getSchemaTable();

    case BROKER_TABLE:
      return getBrokerTable();

    case ES_TABLE:
      return getEsTable();

    case ODBC_TABLE:
      return getOdbcTable();

    case HIVE_TABLE:
      return getHiveTable();

    case ICEBERG_TABLE:
      return getIcebergTable();

    case HUDI_TABLE:
      return getHudiTable();

    case JDBC_TABLE:
      return getJdbcTable();

    case MC_TABLE:
      return getMcTable();

    case TRINO_CONNECTOR_TABLE:
      return getTrinoConnectorTable();

    case LAKESOUL_TABLE:
      return getLakesoulTable();

    case DICTIONARY_TABLE:
      return getDictionaryTable();

    case REMOTE_DORIS_TABLE:
      return getRemoteDorisTable();

    }
    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 ID:
      return isSetId();
    case TABLE_TYPE:
      return isSetTableType();
    case NUM_COLS:
      return isSetNumCols();
    case NUM_CLUSTERING_COLS:
      return isSetNumClusteringCols();
    case TABLE_NAME:
      return isSetTableName();
    case DB_NAME:
      return isSetDbName();
    case MYSQL_TABLE:
      return isSetMysqlTable();
    case OLAP_TABLE:
      return isSetOlapTable();
    case SCHEMA_TABLE:
      return isSetSchemaTable();
    case BROKER_TABLE:
      return isSetBrokerTable();
    case ES_TABLE:
      return isSetEsTable();
    case ODBC_TABLE:
      return isSetOdbcTable();
    case HIVE_TABLE:
      return isSetHiveTable();
    case ICEBERG_TABLE:
      return isSetIcebergTable();
    case HUDI_TABLE:
      return isSetHudiTable();
    case JDBC_TABLE:
      return isSetJdbcTable();
    case MC_TABLE:
      return isSetMcTable();
    case TRINO_CONNECTOR_TABLE:
      return isSetTrinoConnectorTable();
    case LAKESOUL_TABLE:
      return isSetLakesoulTable();
    case DICTIONARY_TABLE:
      return isSetDictionaryTable();
    case REMOTE_DORIS_TABLE:
      return isSetRemoteDorisTable();
    }
    throw new java.lang.IllegalStateException();
  }

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

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

    boolean this_present_id = true;
    boolean that_present_id = true;
    if (this_present_id || that_present_id) {
      if (!(this_present_id && that_present_id))
        return false;
      if (this.id != that.id)
        return false;
    }

    boolean this_present_tableType = true && this.isSetTableType();
    boolean that_present_tableType = true && that.isSetTableType();
    if (this_present_tableType || that_present_tableType) {
      if (!(this_present_tableType && that_present_tableType))
        return false;
      if (!this.tableType.equals(that.tableType))
        return false;
    }

    boolean this_present_numCols = true;
    boolean that_present_numCols = true;
    if (this_present_numCols || that_present_numCols) {
      if (!(this_present_numCols && that_present_numCols))
        return false;
      if (this.numCols != that.numCols)
        return false;
    }

    boolean this_present_numClusteringCols = true;
    boolean that_present_numClusteringCols = true;
    if (this_present_numClusteringCols || that_present_numClusteringCols) {
      if (!(this_present_numClusteringCols && that_present_numClusteringCols))
        return false;
      if (this.numClusteringCols != that.numClusteringCols)
        return false;
    }

    boolean this_present_tableName = true && this.isSetTableName();
    boolean that_present_tableName = true && that.isSetTableName();
    if (this_present_tableName || that_present_tableName) {
      if (!(this_present_tableName && that_present_tableName))
        return false;
      if (!this.tableName.equals(that.tableName))
        return false;
    }

    boolean this_present_dbName = true && this.isSetDbName();
    boolean that_present_dbName = true && that.isSetDbName();
    if (this_present_dbName || that_present_dbName) {
      if (!(this_present_dbName && that_present_dbName))
        return false;
      if (!this.dbName.equals(that.dbName))
        return false;
    }

    boolean this_present_mysqlTable = true && this.isSetMysqlTable();
    boolean that_present_mysqlTable = true && that.isSetMysqlTable();
    if (this_present_mysqlTable || that_present_mysqlTable) {
      if (!(this_present_mysqlTable && that_present_mysqlTable))
        return false;
      if (!this.mysqlTable.equals(that.mysqlTable))
        return false;
    }

    boolean this_present_olapTable = true && this.isSetOlapTable();
    boolean that_present_olapTable = true && that.isSetOlapTable();
    if (this_present_olapTable || that_present_olapTable) {
      if (!(this_present_olapTable && that_present_olapTable))
        return false;
      if (!this.olapTable.equals(that.olapTable))
        return false;
    }

    boolean this_present_schemaTable = true && this.isSetSchemaTable();
    boolean that_present_schemaTable = true && that.isSetSchemaTable();
    if (this_present_schemaTable || that_present_schemaTable) {
      if (!(this_present_schemaTable && that_present_schemaTable))
        return false;
      if (!this.schemaTable.equals(that.schemaTable))
        return false;
    }

    boolean this_present_BrokerTable = true && this.isSetBrokerTable();
    boolean that_present_BrokerTable = true && that.isSetBrokerTable();
    if (this_present_BrokerTable || that_present_BrokerTable) {
      if (!(this_present_BrokerTable && that_present_BrokerTable))
        return false;
      if (!this.BrokerTable.equals(that.BrokerTable))
        return false;
    }

    boolean this_present_esTable = true && this.isSetEsTable();
    boolean that_present_esTable = true && that.isSetEsTable();
    if (this_present_esTable || that_present_esTable) {
      if (!(this_present_esTable && that_present_esTable))
        return false;
      if (!this.esTable.equals(that.esTable))
        return false;
    }

    boolean this_present_odbcTable = true && this.isSetOdbcTable();
    boolean that_present_odbcTable = true && that.isSetOdbcTable();
    if (this_present_odbcTable || that_present_odbcTable) {
      if (!(this_present_odbcTable && that_present_odbcTable))
        return false;
      if (!this.odbcTable.equals(that.odbcTable))
        return false;
    }

    boolean this_present_hiveTable = true && this.isSetHiveTable();
    boolean that_present_hiveTable = true && that.isSetHiveTable();
    if (this_present_hiveTable || that_present_hiveTable) {
      if (!(this_present_hiveTable && that_present_hiveTable))
        return false;
      if (!this.hiveTable.equals(that.hiveTable))
        return false;
    }

    boolean this_present_icebergTable = true && this.isSetIcebergTable();
    boolean that_present_icebergTable = true && that.isSetIcebergTable();
    if (this_present_icebergTable || that_present_icebergTable) {
      if (!(this_present_icebergTable && that_present_icebergTable))
        return false;
      if (!this.icebergTable.equals(that.icebergTable))
        return false;
    }

    boolean this_present_hudiTable = true && this.isSetHudiTable();
    boolean that_present_hudiTable = true && that.isSetHudiTable();
    if (this_present_hudiTable || that_present_hudiTable) {
      if (!(this_present_hudiTable && that_present_hudiTable))
        return false;
      if (!this.hudiTable.equals(that.hudiTable))
        return false;
    }

    boolean this_present_jdbcTable = true && this.isSetJdbcTable();
    boolean that_present_jdbcTable = true && that.isSetJdbcTable();
    if (this_present_jdbcTable || that_present_jdbcTable) {
      if (!(this_present_jdbcTable && that_present_jdbcTable))
        return false;
      if (!this.jdbcTable.equals(that.jdbcTable))
        return false;
    }

    boolean this_present_mcTable = true && this.isSetMcTable();
    boolean that_present_mcTable = true && that.isSetMcTable();
    if (this_present_mcTable || that_present_mcTable) {
      if (!(this_present_mcTable && that_present_mcTable))
        return false;
      if (!this.mcTable.equals(that.mcTable))
        return false;
    }

    boolean this_present_trinoConnectorTable = true && this.isSetTrinoConnectorTable();
    boolean that_present_trinoConnectorTable = true && that.isSetTrinoConnectorTable();
    if (this_present_trinoConnectorTable || that_present_trinoConnectorTable) {
      if (!(this_present_trinoConnectorTable && that_present_trinoConnectorTable))
        return false;
      if (!this.trinoConnectorTable.equals(that.trinoConnectorTable))
        return false;
    }

    boolean this_present_lakesoulTable = true && this.isSetLakesoulTable();
    boolean that_present_lakesoulTable = true && that.isSetLakesoulTable();
    if (this_present_lakesoulTable || that_present_lakesoulTable) {
      if (!(this_present_lakesoulTable && that_present_lakesoulTable))
        return false;
      if (!this.lakesoulTable.equals(that.lakesoulTable))
        return false;
    }

    boolean this_present_dictionaryTable = true && this.isSetDictionaryTable();
    boolean that_present_dictionaryTable = true && that.isSetDictionaryTable();
    if (this_present_dictionaryTable || that_present_dictionaryTable) {
      if (!(this_present_dictionaryTable && that_present_dictionaryTable))
        return false;
      if (!this.dictionaryTable.equals(that.dictionaryTable))
        return false;
    }

    boolean this_present_remoteDorisTable = true && this.isSetRemoteDorisTable();
    boolean that_present_remoteDorisTable = true && that.isSetRemoteDorisTable();
    if (this_present_remoteDorisTable || that_present_remoteDorisTable) {
      if (!(this_present_remoteDorisTable && that_present_remoteDorisTable))
        return false;
      if (!this.remoteDorisTable.equals(that.remoteDorisTable))
        return false;
    }

    return true;
  }

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

    hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(id);

    hashCode = hashCode * 8191 + ((isSetTableType()) ? 131071 : 524287);
    if (isSetTableType())
      hashCode = hashCode * 8191 + tableType.getValue();

    hashCode = hashCode * 8191 + numCols;

    hashCode = hashCode * 8191 + numClusteringCols;

    hashCode = hashCode * 8191 + ((isSetTableName()) ? 131071 : 524287);
    if (isSetTableName())
      hashCode = hashCode * 8191 + tableName.hashCode();

    hashCode = hashCode * 8191 + ((isSetDbName()) ? 131071 : 524287);
    if (isSetDbName())
      hashCode = hashCode * 8191 + dbName.hashCode();

    hashCode = hashCode * 8191 + ((isSetMysqlTable()) ? 131071 : 524287);
    if (isSetMysqlTable())
      hashCode = hashCode * 8191 + mysqlTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetOlapTable()) ? 131071 : 524287);
    if (isSetOlapTable())
      hashCode = hashCode * 8191 + olapTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetSchemaTable()) ? 131071 : 524287);
    if (isSetSchemaTable())
      hashCode = hashCode * 8191 + schemaTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetBrokerTable()) ? 131071 : 524287);
    if (isSetBrokerTable())
      hashCode = hashCode * 8191 + BrokerTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetEsTable()) ? 131071 : 524287);
    if (isSetEsTable())
      hashCode = hashCode * 8191 + esTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetOdbcTable()) ? 131071 : 524287);
    if (isSetOdbcTable())
      hashCode = hashCode * 8191 + odbcTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetHiveTable()) ? 131071 : 524287);
    if (isSetHiveTable())
      hashCode = hashCode * 8191 + hiveTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetIcebergTable()) ? 131071 : 524287);
    if (isSetIcebergTable())
      hashCode = hashCode * 8191 + icebergTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetHudiTable()) ? 131071 : 524287);
    if (isSetHudiTable())
      hashCode = hashCode * 8191 + hudiTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetJdbcTable()) ? 131071 : 524287);
    if (isSetJdbcTable())
      hashCode = hashCode * 8191 + jdbcTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetMcTable()) ? 131071 : 524287);
    if (isSetMcTable())
      hashCode = hashCode * 8191 + mcTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetTrinoConnectorTable()) ? 131071 : 524287);
    if (isSetTrinoConnectorTable())
      hashCode = hashCode * 8191 + trinoConnectorTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetLakesoulTable()) ? 131071 : 524287);
    if (isSetLakesoulTable())
      hashCode = hashCode * 8191 + lakesoulTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetDictionaryTable()) ? 131071 : 524287);
    if (isSetDictionaryTable())
      hashCode = hashCode * 8191 + dictionaryTable.hashCode();

    hashCode = hashCode * 8191 + ((isSetRemoteDorisTable()) ? 131071 : 524287);
    if (isSetRemoteDorisTable())
      hashCode = hashCode * 8191 + remoteDorisTable.hashCode();

    return hashCode;
  }

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

    int lastComparison = 0;

    lastComparison = java.lang.Boolean.compare(isSetId(), other.isSetId());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetId()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, other.id);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetTableType(), other.isSetTableType());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTableType()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tableType, other.tableType);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetNumCols(), other.isSetNumCols());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetNumCols()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.numCols, other.numCols);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetNumClusteringCols(), other.isSetNumClusteringCols());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetNumClusteringCols()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.numClusteringCols, other.numClusteringCols);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetTableName(), other.isSetTableName());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTableName()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tableName, other.tableName);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetDbName(), other.isSetDbName());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetDbName()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dbName, other.dbName);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetMysqlTable(), other.isSetMysqlTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetMysqlTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.mysqlTable, other.mysqlTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetOlapTable(), other.isSetOlapTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetOlapTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.olapTable, other.olapTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetSchemaTable(), other.isSetSchemaTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetSchemaTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.schemaTable, other.schemaTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetBrokerTable(), other.isSetBrokerTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetBrokerTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.BrokerTable, other.BrokerTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetEsTable(), other.isSetEsTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetEsTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.esTable, other.esTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetOdbcTable(), other.isSetOdbcTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetOdbcTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.odbcTable, other.odbcTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetHiveTable(), other.isSetHiveTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetHiveTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.hiveTable, other.hiveTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetIcebergTable(), other.isSetIcebergTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetIcebergTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.icebergTable, other.icebergTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetHudiTable(), other.isSetHudiTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetHudiTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.hudiTable, other.hudiTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetJdbcTable(), other.isSetJdbcTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetJdbcTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.jdbcTable, other.jdbcTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetMcTable(), other.isSetMcTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetMcTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.mcTable, other.mcTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetTrinoConnectorTable(), other.isSetTrinoConnectorTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetTrinoConnectorTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.trinoConnectorTable, other.trinoConnectorTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetLakesoulTable(), other.isSetLakesoulTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetLakesoulTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lakesoulTable, other.lakesoulTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetDictionaryTable(), other.isSetDictionaryTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetDictionaryTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dictionaryTable, other.dictionaryTable);
      if (lastComparison != 0) {
        return lastComparison;
      }
    }
    lastComparison = java.lang.Boolean.compare(isSetRemoteDorisTable(), other.isSetRemoteDorisTable());
    if (lastComparison != 0) {
      return lastComparison;
    }
    if (isSetRemoteDorisTable()) {
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.remoteDorisTable, other.remoteDorisTable);
      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("TTableDescriptor(");
    boolean first = true;

    sb.append("id:");
    sb.append(this.id);
    first = false;
    if (!first) sb.append(", ");
    sb.append("tableType:");
    if (this.tableType == null) {
      sb.append("null");
    } else {
      sb.append(this.tableType);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("numCols:");
    sb.append(this.numCols);
    first = false;
    if (!first) sb.append(", ");
    sb.append("numClusteringCols:");
    sb.append(this.numClusteringCols);
    first = false;
    if (!first) sb.append(", ");
    sb.append("tableName:");
    if (this.tableName == null) {
      sb.append("null");
    } else {
      sb.append(this.tableName);
    }
    first = false;
    if (!first) sb.append(", ");
    sb.append("dbName:");
    if (this.dbName == null) {
      sb.append("null");
    } else {
      sb.append(this.dbName);
    }
    first = false;
    if (isSetMysqlTable()) {
      if (!first) sb.append(", ");
      sb.append("mysqlTable:");
      if (this.mysqlTable == null) {
        sb.append("null");
      } else {
        sb.append(this.mysqlTable);
      }
      first = false;
    }
    if (isSetOlapTable()) {
      if (!first) sb.append(", ");
      sb.append("olapTable:");
      if (this.olapTable == null) {
        sb.append("null");
      } else {
        sb.append(this.olapTable);
      }
      first = false;
    }
    if (isSetSchemaTable()) {
      if (!first) sb.append(", ");
      sb.append("schemaTable:");
      if (this.schemaTable == null) {
        sb.append("null");
      } else {
        sb.append(this.schemaTable);
      }
      first = false;
    }
    if (isSetBrokerTable()) {
      if (!first) sb.append(", ");
      sb.append("BrokerTable:");
      if (this.BrokerTable == null) {
        sb.append("null");
      } else {
        sb.append(this.BrokerTable);
      }
      first = false;
    }
    if (isSetEsTable()) {
      if (!first) sb.append(", ");
      sb.append("esTable:");
      if (this.esTable == null) {
        sb.append("null");
      } else {
        sb.append(this.esTable);
      }
      first = false;
    }
    if (isSetOdbcTable()) {
      if (!first) sb.append(", ");
      sb.append("odbcTable:");
      if (this.odbcTable == null) {
        sb.append("null");
      } else {
        sb.append(this.odbcTable);
      }
      first = false;
    }
    if (isSetHiveTable()) {
      if (!first) sb.append(", ");
      sb.append("hiveTable:");
      if (this.hiveTable == null) {
        sb.append("null");
      } else {
        sb.append(this.hiveTable);
      }
      first = false;
    }
    if (isSetIcebergTable()) {
      if (!first) sb.append(", ");
      sb.append("icebergTable:");
      if (this.icebergTable == null) {
        sb.append("null");
      } else {
        sb.append(this.icebergTable);
      }
      first = false;
    }
    if (isSetHudiTable()) {
      if (!first) sb.append(", ");
      sb.append("hudiTable:");
      if (this.hudiTable == null) {
        sb.append("null");
      } else {
        sb.append(this.hudiTable);
      }
      first = false;
    }
    if (isSetJdbcTable()) {
      if (!first) sb.append(", ");
      sb.append("jdbcTable:");
      if (this.jdbcTable == null) {
        sb.append("null");
      } else {
        sb.append(this.jdbcTable);
      }
      first = false;
    }
    if (isSetMcTable()) {
      if (!first) sb.append(", ");
      sb.append("mcTable:");
      if (this.mcTable == null) {
        sb.append("null");
      } else {
        sb.append(this.mcTable);
      }
      first = false;
    }
    if (isSetTrinoConnectorTable()) {
      if (!first) sb.append(", ");
      sb.append("trinoConnectorTable:");
      if (this.trinoConnectorTable == null) {
        sb.append("null");
      } else {
        sb.append(this.trinoConnectorTable);
      }
      first = false;
    }
    if (isSetLakesoulTable()) {
      if (!first) sb.append(", ");
      sb.append("lakesoulTable:");
      if (this.lakesoulTable == null) {
        sb.append("null");
      } else {
        sb.append(this.lakesoulTable);
      }
      first = false;
    }
    if (isSetDictionaryTable()) {
      if (!first) sb.append(", ");
      sb.append("dictionaryTable:");
      if (this.dictionaryTable == null) {
        sb.append("null");
      } else {
        sb.append(this.dictionaryTable);
      }
      first = false;
    }
    if (isSetRemoteDorisTable()) {
      if (!first) sb.append(", ");
      sb.append("remoteDorisTable:");
      if (this.remoteDorisTable == null) {
        sb.append("null");
      } else {
        sb.append(this.remoteDorisTable);
      }
      first = false;
    }
    sb.append(")");
    return sb.toString();
  }

  public void validate() throws org.apache.thrift.TException {
    // check for required fields
    // alas, we cannot check 'id' because it's a primitive and you chose the non-beans generator.
    if (tableType == null) {
      throw new org.apache.thrift.protocol.TProtocolException("Required field 'tableType' was not present! Struct: " + toString());
    }
    // alas, we cannot check 'numCols' because it's a primitive and you chose the non-beans generator.
    // alas, we cannot check 'numClusteringCols' because it's a primitive and you chose the non-beans generator.
    if (tableName == null) {
      throw new org.apache.thrift.protocol.TProtocolException("Required field 'tableName' was not present! Struct: " + toString());
    }
    if (dbName == null) {
      throw new org.apache.thrift.protocol.TProtocolException("Required field 'dbName' was not present! Struct: " + toString());
    }
    // check for sub-struct validity
    if (mysqlTable != null) {
      mysqlTable.validate();
    }
    if (olapTable != null) {
      olapTable.validate();
    }
    if (schemaTable != null) {
      schemaTable.validate();
    }
    if (BrokerTable != null) {
      BrokerTable.validate();
    }
    if (esTable != null) {
      esTable.validate();
    }
    if (odbcTable != null) {
      odbcTable.validate();
    }
    if (hiveTable != null) {
      hiveTable.validate();
    }
    if (icebergTable != null) {
      icebergTable.validate();
    }
    if (hudiTable != null) {
      hudiTable.validate();
    }
    if (jdbcTable != null) {
      jdbcTable.validate();
    }
    if (mcTable != null) {
      mcTable.validate();
    }
    if (trinoConnectorTable != null) {
      trinoConnectorTable.validate();
    }
    if (lakesoulTable != null) {
      lakesoulTable.validate();
    }
    if (dictionaryTable != null) {
      dictionaryTable.validate();
    }
    if (remoteDorisTable != null) {
      remoteDorisTable.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 TTableDescriptorStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
    public TTableDescriptorStandardScheme getScheme() {
      return new TTableDescriptorStandardScheme();
    }
  }

  private static class TTableDescriptorStandardScheme extends org.apache.thrift.scheme.StandardScheme<TTableDescriptor> {

    public void read(org.apache.thrift.protocol.TProtocol iprot, TTableDescriptor 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: // ID
            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
              struct.id = iprot.readI64();
              struct.setIdIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 2: // TABLE_TYPE
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.tableType = org.apache.doris.thrift.TTableType.findByValue(iprot.readI32());
              struct.setTableTypeIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 3: // NUM_COLS
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.numCols = iprot.readI32();
              struct.setNumColsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 4: // NUM_CLUSTERING_COLS
            if (schemeField.type == org.apache.thrift.protocol.TType.I32) {
              struct.numClusteringCols = iprot.readI32();
              struct.setNumClusteringColsIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 7: // TABLE_NAME
            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
              struct.tableName = iprot.readString();
              struct.setTableNameIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 8: // DB_NAME
            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
              struct.dbName = iprot.readString();
              struct.setDbNameIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 10: // MYSQL_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.mysqlTable = new TMySQLTable();
              struct.mysqlTable.read(iprot);
              struct.setMysqlTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 11: // OLAP_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.olapTable = new TOlapTable();
              struct.olapTable.read(iprot);
              struct.setOlapTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 12: // SCHEMA_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.schemaTable = new TSchemaTable();
              struct.schemaTable.read(iprot);
              struct.setSchemaTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 14: // BROKER_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.BrokerTable = new TBrokerTable();
              struct.BrokerTable.read(iprot);
              struct.setBrokerTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 15: // ES_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.esTable = new TEsTable();
              struct.esTable.read(iprot);
              struct.setEsTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 16: // ODBC_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.odbcTable = new TOdbcTable();
              struct.odbcTable.read(iprot);
              struct.setOdbcTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 17: // HIVE_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.hiveTable = new THiveTable();
              struct.hiveTable.read(iprot);
              struct.setHiveTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 18: // ICEBERG_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.icebergTable = new TIcebergTable();
              struct.icebergTable.read(iprot);
              struct.setIcebergTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 19: // HUDI_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.hudiTable = new THudiTable();
              struct.hudiTable.read(iprot);
              struct.setHudiTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 20: // JDBC_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.jdbcTable = new TJdbcTable();
              struct.jdbcTable.read(iprot);
              struct.setJdbcTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 21: // MC_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.mcTable = new TMCTable();
              struct.mcTable.read(iprot);
              struct.setMcTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 22: // TRINO_CONNECTOR_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.trinoConnectorTable = new TTrinoConnectorTable();
              struct.trinoConnectorTable.read(iprot);
              struct.setTrinoConnectorTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 23: // LAKESOUL_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.lakesoulTable = new TLakeSoulTable();
              struct.lakesoulTable.read(iprot);
              struct.setLakesoulTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 24: // DICTIONARY_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.dictionaryTable = new TDictionaryTable();
              struct.dictionaryTable.read(iprot);
              struct.setDictionaryTableIsSet(true);
            } else { 
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
            }
            break;
          case 25: // REMOTE_DORIS_TABLE
            if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
              struct.remoteDorisTable = new TRemoteDorisTable();
              struct.remoteDorisTable.read(iprot);
              struct.setRemoteDorisTableIsSet(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
      if (!struct.isSetId()) {
        throw new org.apache.thrift.protocol.TProtocolException("Required field 'id' was not found in serialized data! Struct: " + toString());
      }
      if (!struct.isSetNumCols()) {
        throw new org.apache.thrift.protocol.TProtocolException("Required field 'numCols' was not found in serialized data! Struct: " + toString());
      }
      if (!struct.isSetNumClusteringCols()) {
        throw new org.apache.thrift.protocol.TProtocolException("Required field 'numClusteringCols' was not found in serialized data! Struct: " + toString());
      }
      struct.validate();
    }

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

      oprot.writeStructBegin(STRUCT_DESC);
      oprot.writeFieldBegin(ID_FIELD_DESC);
      oprot.writeI64(struct.id);
      oprot.writeFieldEnd();
      if (struct.tableType != null) {
        oprot.writeFieldBegin(TABLE_TYPE_FIELD_DESC);
        oprot.writeI32(struct.tableType.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(NUM_COLS_FIELD_DESC);
      oprot.writeI32(struct.numCols);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(NUM_CLUSTERING_COLS_FIELD_DESC);
      oprot.writeI32(struct.numClusteringCols);
      oprot.writeFieldEnd();
      if (struct.tableName != null) {
        oprot.writeFieldBegin(TABLE_NAME_FIELD_DESC);
        oprot.writeString(struct.tableName);
        oprot.writeFieldEnd();
      }
      if (struct.dbName != null) {
        oprot.writeFieldBegin(DB_NAME_FIELD_DESC);
        oprot.writeString(struct.dbName);
        oprot.writeFieldEnd();
      }
      if (struct.mysqlTable != null) {
        if (struct.isSetMysqlTable()) {
          oprot.writeFieldBegin(MYSQL_TABLE_FIELD_DESC);
          struct.mysqlTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.olapTable != null) {
        if (struct.isSetOlapTable()) {
          oprot.writeFieldBegin(OLAP_TABLE_FIELD_DESC);
          struct.olapTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.schemaTable != null) {
        if (struct.isSetSchemaTable()) {
          oprot.writeFieldBegin(SCHEMA_TABLE_FIELD_DESC);
          struct.schemaTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.BrokerTable != null) {
        if (struct.isSetBrokerTable()) {
          oprot.writeFieldBegin(BROKER_TABLE_FIELD_DESC);
          struct.BrokerTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.esTable != null) {
        if (struct.isSetEsTable()) {
          oprot.writeFieldBegin(ES_TABLE_FIELD_DESC);
          struct.esTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.odbcTable != null) {
        if (struct.isSetOdbcTable()) {
          oprot.writeFieldBegin(ODBC_TABLE_FIELD_DESC);
          struct.odbcTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.hiveTable != null) {
        if (struct.isSetHiveTable()) {
          oprot.writeFieldBegin(HIVE_TABLE_FIELD_DESC);
          struct.hiveTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.icebergTable != null) {
        if (struct.isSetIcebergTable()) {
          oprot.writeFieldBegin(ICEBERG_TABLE_FIELD_DESC);
          struct.icebergTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.hudiTable != null) {
        if (struct.isSetHudiTable()) {
          oprot.writeFieldBegin(HUDI_TABLE_FIELD_DESC);
          struct.hudiTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.jdbcTable != null) {
        if (struct.isSetJdbcTable()) {
          oprot.writeFieldBegin(JDBC_TABLE_FIELD_DESC);
          struct.jdbcTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.mcTable != null) {
        if (struct.isSetMcTable()) {
          oprot.writeFieldBegin(MC_TABLE_FIELD_DESC);
          struct.mcTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.trinoConnectorTable != null) {
        if (struct.isSetTrinoConnectorTable()) {
          oprot.writeFieldBegin(TRINO_CONNECTOR_TABLE_FIELD_DESC);
          struct.trinoConnectorTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.lakesoulTable != null) {
        if (struct.isSetLakesoulTable()) {
          oprot.writeFieldBegin(LAKESOUL_TABLE_FIELD_DESC);
          struct.lakesoulTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.dictionaryTable != null) {
        if (struct.isSetDictionaryTable()) {
          oprot.writeFieldBegin(DICTIONARY_TABLE_FIELD_DESC);
          struct.dictionaryTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.remoteDorisTable != null) {
        if (struct.isSetRemoteDorisTable()) {
          oprot.writeFieldBegin(REMOTE_DORIS_TABLE_FIELD_DESC);
          struct.remoteDorisTable.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }

  }

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

  private static class TTableDescriptorTupleScheme extends org.apache.thrift.scheme.TupleScheme<TTableDescriptor> {

    @Override
    public void write(org.apache.thrift.protocol.TProtocol prot, TTableDescriptor struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      oprot.writeI64(struct.id);
      oprot.writeI32(struct.tableType.getValue());
      oprot.writeI32(struct.numCols);
      oprot.writeI32(struct.numClusteringCols);
      oprot.writeString(struct.tableName);
      oprot.writeString(struct.dbName);
      java.util.BitSet optionals = new java.util.BitSet();
      if (struct.isSetMysqlTable()) {
        optionals.set(0);
      }
      if (struct.isSetOlapTable()) {
        optionals.set(1);
      }
      if (struct.isSetSchemaTable()) {
        optionals.set(2);
      }
      if (struct.isSetBrokerTable()) {
        optionals.set(3);
      }
      if (struct.isSetEsTable()) {
        optionals.set(4);
      }
      if (struct.isSetOdbcTable()) {
        optionals.set(5);
      }
      if (struct.isSetHiveTable()) {
        optionals.set(6);
      }
      if (struct.isSetIcebergTable()) {
        optionals.set(7);
      }
      if (struct.isSetHudiTable()) {
        optionals.set(8);
      }
      if (struct.isSetJdbcTable()) {
        optionals.set(9);
      }
      if (struct.isSetMcTable()) {
        optionals.set(10);
      }
      if (struct.isSetTrinoConnectorTable()) {
        optionals.set(11);
      }
      if (struct.isSetLakesoulTable()) {
        optionals.set(12);
      }
      if (struct.isSetDictionaryTable()) {
        optionals.set(13);
      }
      if (struct.isSetRemoteDorisTable()) {
        optionals.set(14);
      }
      oprot.writeBitSet(optionals, 15);
      if (struct.isSetMysqlTable()) {
        struct.mysqlTable.write(oprot);
      }
      if (struct.isSetOlapTable()) {
        struct.olapTable.write(oprot);
      }
      if (struct.isSetSchemaTable()) {
        struct.schemaTable.write(oprot);
      }
      if (struct.isSetBrokerTable()) {
        struct.BrokerTable.write(oprot);
      }
      if (struct.isSetEsTable()) {
        struct.esTable.write(oprot);
      }
      if (struct.isSetOdbcTable()) {
        struct.odbcTable.write(oprot);
      }
      if (struct.isSetHiveTable()) {
        struct.hiveTable.write(oprot);
      }
      if (struct.isSetIcebergTable()) {
        struct.icebergTable.write(oprot);
      }
      if (struct.isSetHudiTable()) {
        struct.hudiTable.write(oprot);
      }
      if (struct.isSetJdbcTable()) {
        struct.jdbcTable.write(oprot);
      }
      if (struct.isSetMcTable()) {
        struct.mcTable.write(oprot);
      }
      if (struct.isSetTrinoConnectorTable()) {
        struct.trinoConnectorTable.write(oprot);
      }
      if (struct.isSetLakesoulTable()) {
        struct.lakesoulTable.write(oprot);
      }
      if (struct.isSetDictionaryTable()) {
        struct.dictionaryTable.write(oprot);
      }
      if (struct.isSetRemoteDorisTable()) {
        struct.remoteDorisTable.write(oprot);
      }
    }

    @Override
    public void read(org.apache.thrift.protocol.TProtocol prot, TTableDescriptor struct) throws org.apache.thrift.TException {
      org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
      struct.id = iprot.readI64();
      struct.setIdIsSet(true);
      struct.tableType = org.apache.doris.thrift.TTableType.findByValue(iprot.readI32());
      struct.setTableTypeIsSet(true);
      struct.numCols = iprot.readI32();
      struct.setNumColsIsSet(true);
      struct.numClusteringCols = iprot.readI32();
      struct.setNumClusteringColsIsSet(true);
      struct.tableName = iprot.readString();
      struct.setTableNameIsSet(true);
      struct.dbName = iprot.readString();
      struct.setDbNameIsSet(true);
      java.util.BitSet incoming = iprot.readBitSet(15);
      if (incoming.get(0)) {
        struct.mysqlTable = new TMySQLTable();
        struct.mysqlTable.read(iprot);
        struct.setMysqlTableIsSet(true);
      }
      if (incoming.get(1)) {
        struct.olapTable = new TOlapTable();
        struct.olapTable.read(iprot);
        struct.setOlapTableIsSet(true);
      }
      if (incoming.get(2)) {
        struct.schemaTable = new TSchemaTable();
        struct.schemaTable.read(iprot);
        struct.setSchemaTableIsSet(true);
      }
      if (incoming.get(3)) {
        struct.BrokerTable = new TBrokerTable();
        struct.BrokerTable.read(iprot);
        struct.setBrokerTableIsSet(true);
      }
      if (incoming.get(4)) {
        struct.esTable = new TEsTable();
        struct.esTable.read(iprot);
        struct.setEsTableIsSet(true);
      }
      if (incoming.get(5)) {
        struct.odbcTable = new TOdbcTable();
        struct.odbcTable.read(iprot);
        struct.setOdbcTableIsSet(true);
      }
      if (incoming.get(6)) {
        struct.hiveTable = new THiveTable();
        struct.hiveTable.read(iprot);
        struct.setHiveTableIsSet(true);
      }
      if (incoming.get(7)) {
        struct.icebergTable = new TIcebergTable();
        struct.icebergTable.read(iprot);
        struct.setIcebergTableIsSet(true);
      }
      if (incoming.get(8)) {
        struct.hudiTable = new THudiTable();
        struct.hudiTable.read(iprot);
        struct.setHudiTableIsSet(true);
      }
      if (incoming.get(9)) {
        struct.jdbcTable = new TJdbcTable();
        struct.jdbcTable.read(iprot);
        struct.setJdbcTableIsSet(true);
      }
      if (incoming.get(10)) {
        struct.mcTable = new TMCTable();
        struct.mcTable.read(iprot);
        struct.setMcTableIsSet(true);
      }
      if (incoming.get(11)) {
        struct.trinoConnectorTable = new TTrinoConnectorTable();
        struct.trinoConnectorTable.read(iprot);
        struct.setTrinoConnectorTableIsSet(true);
      }
      if (incoming.get(12)) {
        struct.lakesoulTable = new TLakeSoulTable();
        struct.lakesoulTable.read(iprot);
        struct.setLakesoulTableIsSet(true);
      }
      if (incoming.get(13)) {
        struct.dictionaryTable = new TDictionaryTable();
        struct.dictionaryTable.read(iprot);
        struct.setDictionaryTableIsSet(true);
      }
      if (incoming.get(14)) {
        struct.remoteDorisTable = new TRemoteDorisTable();
        struct.remoteDorisTable.read(iprot);
        struct.setRemoteDorisTableIsSet(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();
  }
}