TUpdateTabletMetaInfoReq.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 TUpdateTabletMetaInfoReq implements org.apache.thrift.TBase<TUpdateTabletMetaInfoReq, TUpdateTabletMetaInfoReq._Fields>, java.io.Serializable, Cloneable, Comparable<TUpdateTabletMetaInfoReq> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TUpdateTabletMetaInfoReq");
private static final org.apache.thrift.protocol.TField TABLET_META_INFOS_FIELD_DESC = new org.apache.thrift.protocol.TField("tabletMetaInfos", org.apache.thrift.protocol.TType.LIST, (short)1);
private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TUpdateTabletMetaInfoReqStandardSchemeFactory();
private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TUpdateTabletMetaInfoReqTupleSchemeFactory();
public @org.apache.thrift.annotation.Nullable java.util.List<TTabletMetaInfo> tabletMetaInfos; // 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 {
TABLET_META_INFOS((short)1, "tabletMetaInfos");
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: // TABLET_META_INFOS
return TABLET_META_INFOS;
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 _Fields optionals[] = {_Fields.TABLET_META_INFOS};
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.TABLET_META_INFOS, new org.apache.thrift.meta_data.FieldMetaData("tabletMetaInfos", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TTabletMetaInfo.class))));
metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TUpdateTabletMetaInfoReq.class, metaDataMap);
}
public TUpdateTabletMetaInfoReq() {
}
/**
* Performs a deep copy on <i>other</i>.
*/
public TUpdateTabletMetaInfoReq(TUpdateTabletMetaInfoReq other) {
if (other.isSetTabletMetaInfos()) {
java.util.List<TTabletMetaInfo> __this__tabletMetaInfos = new java.util.ArrayList<TTabletMetaInfo>(other.tabletMetaInfos.size());
for (TTabletMetaInfo other_element : other.tabletMetaInfos) {
__this__tabletMetaInfos.add(new TTabletMetaInfo(other_element));
}
this.tabletMetaInfos = __this__tabletMetaInfos;
}
}
public TUpdateTabletMetaInfoReq deepCopy() {
return new TUpdateTabletMetaInfoReq(this);
}
@Override
public void clear() {
this.tabletMetaInfos = null;
}
public int getTabletMetaInfosSize() {
return (this.tabletMetaInfos == null) ? 0 : this.tabletMetaInfos.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator<TTabletMetaInfo> getTabletMetaInfosIterator() {
return (this.tabletMetaInfos == null) ? null : this.tabletMetaInfos.iterator();
}
public void addToTabletMetaInfos(TTabletMetaInfo elem) {
if (this.tabletMetaInfos == null) {
this.tabletMetaInfos = new java.util.ArrayList<TTabletMetaInfo>();
}
this.tabletMetaInfos.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List<TTabletMetaInfo> getTabletMetaInfos() {
return this.tabletMetaInfos;
}
public TUpdateTabletMetaInfoReq setTabletMetaInfos(@org.apache.thrift.annotation.Nullable java.util.List<TTabletMetaInfo> tabletMetaInfos) {
this.tabletMetaInfos = tabletMetaInfos;
return this;
}
public void unsetTabletMetaInfos() {
this.tabletMetaInfos = null;
}
/** Returns true if field tabletMetaInfos is set (has been assigned a value) and false otherwise */
public boolean isSetTabletMetaInfos() {
return this.tabletMetaInfos != null;
}
public void setTabletMetaInfosIsSet(boolean value) {
if (!value) {
this.tabletMetaInfos = null;
}
}
public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case TABLET_META_INFOS:
if (value == null) {
unsetTabletMetaInfos();
} else {
setTabletMetaInfos((java.util.List<TTabletMetaInfo>)value);
}
break;
}
}
@org.apache.thrift.annotation.Nullable
public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case TABLET_META_INFOS:
return getTabletMetaInfos();
}
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 TABLET_META_INFOS:
return isSetTabletMetaInfos();
}
throw new java.lang.IllegalStateException();
}
@Override
public boolean equals(java.lang.Object that) {
if (that instanceof TUpdateTabletMetaInfoReq)
return this.equals((TUpdateTabletMetaInfoReq)that);
return false;
}
public boolean equals(TUpdateTabletMetaInfoReq that) {
if (that == null)
return false;
if (this == that)
return true;
boolean this_present_tabletMetaInfos = true && this.isSetTabletMetaInfos();
boolean that_present_tabletMetaInfos = true && that.isSetTabletMetaInfos();
if (this_present_tabletMetaInfos || that_present_tabletMetaInfos) {
if (!(this_present_tabletMetaInfos && that_present_tabletMetaInfos))
return false;
if (!this.tabletMetaInfos.equals(that.tabletMetaInfos))
return false;
}
return true;
}
@Override
public int hashCode() {
int hashCode = 1;
hashCode = hashCode * 8191 + ((isSetTabletMetaInfos()) ? 131071 : 524287);
if (isSetTabletMetaInfos())
hashCode = hashCode * 8191 + tabletMetaInfos.hashCode();
return hashCode;
}
@Override
public int compareTo(TUpdateTabletMetaInfoReq other) {
if (!getClass().equals(other.getClass())) {
return getClass().getName().compareTo(other.getClass().getName());
}
int lastComparison = 0;
lastComparison = java.lang.Boolean.compare(isSetTabletMetaInfos(), other.isSetTabletMetaInfos());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetTabletMetaInfos()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tabletMetaInfos, other.tabletMetaInfos);
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("TUpdateTabletMetaInfoReq(");
boolean first = true;
if (isSetTabletMetaInfos()) {
sb.append("tabletMetaInfos:");
if (this.tabletMetaInfos == null) {
sb.append("null");
} else {
sb.append(this.tabletMetaInfos);
}
first = false;
}
sb.append(")");
return sb.toString();
}
public void validate() throws org.apache.thrift.TException {
// check for required fields
// check for sub-struct validity
}
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 {
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 TUpdateTabletMetaInfoReqStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TUpdateTabletMetaInfoReqStandardScheme getScheme() {
return new TUpdateTabletMetaInfoReqStandardScheme();
}
}
private static class TUpdateTabletMetaInfoReqStandardScheme extends org.apache.thrift.scheme.StandardScheme<TUpdateTabletMetaInfoReq> {
public void read(org.apache.thrift.protocol.TProtocol iprot, TUpdateTabletMetaInfoReq 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: // TABLET_META_INFOS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list318 = iprot.readListBegin();
struct.tabletMetaInfos = new java.util.ArrayList<TTabletMetaInfo>(_list318.size);
@org.apache.thrift.annotation.Nullable TTabletMetaInfo _elem319;
for (int _i320 = 0; _i320 < _list318.size; ++_i320)
{
_elem319 = new TTabletMetaInfo();
_elem319.read(iprot);
struct.tabletMetaInfos.add(_elem319);
}
iprot.readListEnd();
}
struct.setTabletMetaInfosIsSet(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, TUpdateTabletMetaInfoReq struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
if (struct.tabletMetaInfos != null) {
if (struct.isSetTabletMetaInfos()) {
oprot.writeFieldBegin(TABLET_META_INFOS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.tabletMetaInfos.size()));
for (TTabletMetaInfo _iter321 : struct.tabletMetaInfos)
{
_iter321.write(oprot);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
}
oprot.writeFieldStop();
oprot.writeStructEnd();
}
}
private static class TUpdateTabletMetaInfoReqTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TUpdateTabletMetaInfoReqTupleScheme getScheme() {
return new TUpdateTabletMetaInfoReqTupleScheme();
}
}
private static class TUpdateTabletMetaInfoReqTupleScheme extends org.apache.thrift.scheme.TupleScheme<TUpdateTabletMetaInfoReq> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, TUpdateTabletMetaInfoReq 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.isSetTabletMetaInfos()) {
optionals.set(0);
}
oprot.writeBitSet(optionals, 1);
if (struct.isSetTabletMetaInfos()) {
{
oprot.writeI32(struct.tabletMetaInfos.size());
for (TTabletMetaInfo _iter322 : struct.tabletMetaInfos)
{
_iter322.write(oprot);
}
}
}
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, TUpdateTabletMetaInfoReq struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
java.util.BitSet incoming = iprot.readBitSet(1);
if (incoming.get(0)) {
{
org.apache.thrift.protocol.TList _list323 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRUCT);
struct.tabletMetaInfos = new java.util.ArrayList<TTabletMetaInfo>(_list323.size);
@org.apache.thrift.annotation.Nullable TTabletMetaInfo _elem324;
for (int _i325 = 0; _i325 < _list323.size; ++_i325)
{
_elem324 = new TTabletMetaInfo();
_elem324.read(iprot);
struct.tabletMetaInfos.add(_elem324);
}
}
struct.setTabletMetaInfosIsSet(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();
}
}