org.apache.iotdb.service.rpc.thrift.TSCreateAlignedTimeseriesReq Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of timechodb-thrift Show documentation
Show all versions of timechodb-thrift Show documentation
RPC (Thrift) framework for client and server.
The newest version!
/**
* Autogenerated by Thrift Compiler (0.14.1)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.apache.iotdb.service.rpc.thrift;
@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.14.1)", date = "2023-04-20")
public class TSCreateAlignedTimeseriesReq implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("TSCreateAlignedTimeseriesReq");
private static final org.apache.thrift.protocol.TField SESSION_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sessionId", org.apache.thrift.protocol.TType.I64, (short)1);
private static final org.apache.thrift.protocol.TField PREFIX_PATH_FIELD_DESC = new org.apache.thrift.protocol.TField("prefixPath", org.apache.thrift.protocol.TType.STRING, (short)2);
private static final org.apache.thrift.protocol.TField MEASUREMENTS_FIELD_DESC = new org.apache.thrift.protocol.TField("measurements", org.apache.thrift.protocol.TType.LIST, (short)3);
private static final org.apache.thrift.protocol.TField DATA_TYPES_FIELD_DESC = new org.apache.thrift.protocol.TField("dataTypes", org.apache.thrift.protocol.TType.LIST, (short)4);
private static final org.apache.thrift.protocol.TField ENCODINGS_FIELD_DESC = new org.apache.thrift.protocol.TField("encodings", org.apache.thrift.protocol.TType.LIST, (short)5);
private static final org.apache.thrift.protocol.TField COMPRESSORS_FIELD_DESC = new org.apache.thrift.protocol.TField("compressors", org.apache.thrift.protocol.TType.LIST, (short)6);
private static final org.apache.thrift.protocol.TField MEASUREMENT_ALIAS_FIELD_DESC = new org.apache.thrift.protocol.TField("measurementAlias", org.apache.thrift.protocol.TType.LIST, (short)7);
private static final org.apache.thrift.protocol.TField TAGS_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("tagsList", org.apache.thrift.protocol.TType.LIST, (short)8);
private static final org.apache.thrift.protocol.TField ATTRIBUTES_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("attributesList", org.apache.thrift.protocol.TType.LIST, (short)9);
private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new TSCreateAlignedTimeseriesReqStandardSchemeFactory();
private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new TSCreateAlignedTimeseriesReqTupleSchemeFactory();
public long sessionId; // required
public @org.apache.thrift.annotation.Nullable java.lang.String prefixPath; // required
public @org.apache.thrift.annotation.Nullable java.util.List measurements; // required
public @org.apache.thrift.annotation.Nullable java.util.List dataTypes; // required
public @org.apache.thrift.annotation.Nullable java.util.List encodings; // required
public @org.apache.thrift.annotation.Nullable java.util.List compressors; // required
public @org.apache.thrift.annotation.Nullable java.util.List measurementAlias; // optional
public @org.apache.thrift.annotation.Nullable java.util.List> tagsList; // optional
public @org.apache.thrift.annotation.Nullable java.util.List> attributesList; // 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 {
SESSION_ID((short)1, "sessionId"),
PREFIX_PATH((short)2, "prefixPath"),
MEASUREMENTS((short)3, "measurements"),
DATA_TYPES((short)4, "dataTypes"),
ENCODINGS((short)5, "encodings"),
COMPRESSORS((short)6, "compressors"),
MEASUREMENT_ALIAS((short)7, "measurementAlias"),
TAGS_LIST((short)8, "tagsList"),
ATTRIBUTES_LIST((short)9, "attributesList");
private static final java.util.Map byName = new java.util.HashMap();
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: // SESSION_ID
return SESSION_ID;
case 2: // PREFIX_PATH
return PREFIX_PATH;
case 3: // MEASUREMENTS
return MEASUREMENTS;
case 4: // DATA_TYPES
return DATA_TYPES;
case 5: // ENCODINGS
return ENCODINGS;
case 6: // COMPRESSORS
return COMPRESSORS;
case 7: // MEASUREMENT_ALIAS
return MEASUREMENT_ALIAS;
case 8: // TAGS_LIST
return TAGS_LIST;
case 9: // ATTRIBUTES_LIST
return ATTRIBUTES_LIST;
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 __SESSIONID_ISSET_ID = 0;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.MEASUREMENT_ALIAS,_Fields.TAGS_LIST,_Fields.ATTRIBUTES_LIST};
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.SESSION_ID, new org.apache.thrift.meta_data.FieldMetaData("sessionId", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
tmpMap.put(_Fields.PREFIX_PATH, new org.apache.thrift.meta_data.FieldMetaData("prefixPath", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.MEASUREMENTS, new org.apache.thrift.meta_data.FieldMetaData("measurements", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
tmpMap.put(_Fields.DATA_TYPES, new org.apache.thrift.meta_data.FieldMetaData("dataTypes", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))));
tmpMap.put(_Fields.ENCODINGS, new org.apache.thrift.meta_data.FieldMetaData("encodings", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))));
tmpMap.put(_Fields.COMPRESSORS, new org.apache.thrift.meta_data.FieldMetaData("compressors", org.apache.thrift.TFieldRequirementType.REQUIRED,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))));
tmpMap.put(_Fields.MEASUREMENT_ALIAS, new org.apache.thrift.meta_data.FieldMetaData("measurementAlias", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
tmpMap.put(_Fields.TAGS_LIST, new org.apache.thrift.meta_data.FieldMetaData("tagsList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING),
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))));
tmpMap.put(_Fields.ATTRIBUTES_LIST, new org.apache.thrift.meta_data.FieldMetaData("attributesList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING),
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)))));
metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(TSCreateAlignedTimeseriesReq.class, metaDataMap);
}
public TSCreateAlignedTimeseriesReq() {
}
public TSCreateAlignedTimeseriesReq(
long sessionId,
java.lang.String prefixPath,
java.util.List measurements,
java.util.List dataTypes,
java.util.List encodings,
java.util.List compressors)
{
this();
this.sessionId = sessionId;
setSessionIdIsSet(true);
this.prefixPath = prefixPath;
this.measurements = measurements;
this.dataTypes = dataTypes;
this.encodings = encodings;
this.compressors = compressors;
}
/**
* Performs a deep copy on other.
*/
public TSCreateAlignedTimeseriesReq(TSCreateAlignedTimeseriesReq other) {
__isset_bitfield = other.__isset_bitfield;
this.sessionId = other.sessionId;
if (other.isSetPrefixPath()) {
this.prefixPath = other.prefixPath;
}
if (other.isSetMeasurements()) {
java.util.List __this__measurements = new java.util.ArrayList(other.measurements);
this.measurements = __this__measurements;
}
if (other.isSetDataTypes()) {
java.util.List __this__dataTypes = new java.util.ArrayList(other.dataTypes);
this.dataTypes = __this__dataTypes;
}
if (other.isSetEncodings()) {
java.util.List __this__encodings = new java.util.ArrayList(other.encodings);
this.encodings = __this__encodings;
}
if (other.isSetCompressors()) {
java.util.List __this__compressors = new java.util.ArrayList(other.compressors);
this.compressors = __this__compressors;
}
if (other.isSetMeasurementAlias()) {
java.util.List __this__measurementAlias = new java.util.ArrayList(other.measurementAlias);
this.measurementAlias = __this__measurementAlias;
}
if (other.isSetTagsList()) {
java.util.List> __this__tagsList = new java.util.ArrayList>(other.tagsList.size());
for (java.util.Map other_element : other.tagsList) {
java.util.Map __this__tagsList_copy = new java.util.HashMap(other_element);
__this__tagsList.add(__this__tagsList_copy);
}
this.tagsList = __this__tagsList;
}
if (other.isSetAttributesList()) {
java.util.List> __this__attributesList = new java.util.ArrayList>(other.attributesList.size());
for (java.util.Map other_element : other.attributesList) {
java.util.Map __this__attributesList_copy = new java.util.HashMap(other_element);
__this__attributesList.add(__this__attributesList_copy);
}
this.attributesList = __this__attributesList;
}
}
public TSCreateAlignedTimeseriesReq deepCopy() {
return new TSCreateAlignedTimeseriesReq(this);
}
@Override
public void clear() {
setSessionIdIsSet(false);
this.sessionId = 0;
this.prefixPath = null;
this.measurements = null;
this.dataTypes = null;
this.encodings = null;
this.compressors = null;
this.measurementAlias = null;
this.tagsList = null;
this.attributesList = null;
}
public long getSessionId() {
return this.sessionId;
}
public TSCreateAlignedTimeseriesReq setSessionId(long sessionId) {
this.sessionId = sessionId;
setSessionIdIsSet(true);
return this;
}
public void unsetSessionId() {
__isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __SESSIONID_ISSET_ID);
}
/** Returns true if field sessionId is set (has been assigned a value) and false otherwise */
public boolean isSetSessionId() {
return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __SESSIONID_ISSET_ID);
}
public void setSessionIdIsSet(boolean value) {
__isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __SESSIONID_ISSET_ID, value);
}
@org.apache.thrift.annotation.Nullable
public java.lang.String getPrefixPath() {
return this.prefixPath;
}
public TSCreateAlignedTimeseriesReq setPrefixPath(@org.apache.thrift.annotation.Nullable java.lang.String prefixPath) {
this.prefixPath = prefixPath;
return this;
}
public void unsetPrefixPath() {
this.prefixPath = null;
}
/** Returns true if field prefixPath is set (has been assigned a value) and false otherwise */
public boolean isSetPrefixPath() {
return this.prefixPath != null;
}
public void setPrefixPathIsSet(boolean value) {
if (!value) {
this.prefixPath = null;
}
}
public int getMeasurementsSize() {
return (this.measurements == null) ? 0 : this.measurements.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator getMeasurementsIterator() {
return (this.measurements == null) ? null : this.measurements.iterator();
}
public void addToMeasurements(java.lang.String elem) {
if (this.measurements == null) {
this.measurements = new java.util.ArrayList();
}
this.measurements.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List getMeasurements() {
return this.measurements;
}
public TSCreateAlignedTimeseriesReq setMeasurements(@org.apache.thrift.annotation.Nullable java.util.List measurements) {
this.measurements = measurements;
return this;
}
public void unsetMeasurements() {
this.measurements = null;
}
/** Returns true if field measurements is set (has been assigned a value) and false otherwise */
public boolean isSetMeasurements() {
return this.measurements != null;
}
public void setMeasurementsIsSet(boolean value) {
if (!value) {
this.measurements = null;
}
}
public int getDataTypesSize() {
return (this.dataTypes == null) ? 0 : this.dataTypes.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator getDataTypesIterator() {
return (this.dataTypes == null) ? null : this.dataTypes.iterator();
}
public void addToDataTypes(int elem) {
if (this.dataTypes == null) {
this.dataTypes = new java.util.ArrayList();
}
this.dataTypes.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List getDataTypes() {
return this.dataTypes;
}
public TSCreateAlignedTimeseriesReq setDataTypes(@org.apache.thrift.annotation.Nullable java.util.List dataTypes) {
this.dataTypes = dataTypes;
return this;
}
public void unsetDataTypes() {
this.dataTypes = null;
}
/** Returns true if field dataTypes is set (has been assigned a value) and false otherwise */
public boolean isSetDataTypes() {
return this.dataTypes != null;
}
public void setDataTypesIsSet(boolean value) {
if (!value) {
this.dataTypes = null;
}
}
public int getEncodingsSize() {
return (this.encodings == null) ? 0 : this.encodings.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator getEncodingsIterator() {
return (this.encodings == null) ? null : this.encodings.iterator();
}
public void addToEncodings(int elem) {
if (this.encodings == null) {
this.encodings = new java.util.ArrayList();
}
this.encodings.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List getEncodings() {
return this.encodings;
}
public TSCreateAlignedTimeseriesReq setEncodings(@org.apache.thrift.annotation.Nullable java.util.List encodings) {
this.encodings = encodings;
return this;
}
public void unsetEncodings() {
this.encodings = null;
}
/** Returns true if field encodings is set (has been assigned a value) and false otherwise */
public boolean isSetEncodings() {
return this.encodings != null;
}
public void setEncodingsIsSet(boolean value) {
if (!value) {
this.encodings = null;
}
}
public int getCompressorsSize() {
return (this.compressors == null) ? 0 : this.compressors.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator getCompressorsIterator() {
return (this.compressors == null) ? null : this.compressors.iterator();
}
public void addToCompressors(int elem) {
if (this.compressors == null) {
this.compressors = new java.util.ArrayList();
}
this.compressors.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List getCompressors() {
return this.compressors;
}
public TSCreateAlignedTimeseriesReq setCompressors(@org.apache.thrift.annotation.Nullable java.util.List compressors) {
this.compressors = compressors;
return this;
}
public void unsetCompressors() {
this.compressors = null;
}
/** Returns true if field compressors is set (has been assigned a value) and false otherwise */
public boolean isSetCompressors() {
return this.compressors != null;
}
public void setCompressorsIsSet(boolean value) {
if (!value) {
this.compressors = null;
}
}
public int getMeasurementAliasSize() {
return (this.measurementAlias == null) ? 0 : this.measurementAlias.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator getMeasurementAliasIterator() {
return (this.measurementAlias == null) ? null : this.measurementAlias.iterator();
}
public void addToMeasurementAlias(java.lang.String elem) {
if (this.measurementAlias == null) {
this.measurementAlias = new java.util.ArrayList();
}
this.measurementAlias.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List getMeasurementAlias() {
return this.measurementAlias;
}
public TSCreateAlignedTimeseriesReq setMeasurementAlias(@org.apache.thrift.annotation.Nullable java.util.List measurementAlias) {
this.measurementAlias = measurementAlias;
return this;
}
public void unsetMeasurementAlias() {
this.measurementAlias = null;
}
/** Returns true if field measurementAlias is set (has been assigned a value) and false otherwise */
public boolean isSetMeasurementAlias() {
return this.measurementAlias != null;
}
public void setMeasurementAliasIsSet(boolean value) {
if (!value) {
this.measurementAlias = null;
}
}
public int getTagsListSize() {
return (this.tagsList == null) ? 0 : this.tagsList.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator> getTagsListIterator() {
return (this.tagsList == null) ? null : this.tagsList.iterator();
}
public void addToTagsList(java.util.Map elem) {
if (this.tagsList == null) {
this.tagsList = new java.util.ArrayList>();
}
this.tagsList.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List> getTagsList() {
return this.tagsList;
}
public TSCreateAlignedTimeseriesReq setTagsList(@org.apache.thrift.annotation.Nullable java.util.List> tagsList) {
this.tagsList = tagsList;
return this;
}
public void unsetTagsList() {
this.tagsList = null;
}
/** Returns true if field tagsList is set (has been assigned a value) and false otherwise */
public boolean isSetTagsList() {
return this.tagsList != null;
}
public void setTagsListIsSet(boolean value) {
if (!value) {
this.tagsList = null;
}
}
public int getAttributesListSize() {
return (this.attributesList == null) ? 0 : this.attributesList.size();
}
@org.apache.thrift.annotation.Nullable
public java.util.Iterator> getAttributesListIterator() {
return (this.attributesList == null) ? null : this.attributesList.iterator();
}
public void addToAttributesList(java.util.Map elem) {
if (this.attributesList == null) {
this.attributesList = new java.util.ArrayList>();
}
this.attributesList.add(elem);
}
@org.apache.thrift.annotation.Nullable
public java.util.List> getAttributesList() {
return this.attributesList;
}
public TSCreateAlignedTimeseriesReq setAttributesList(@org.apache.thrift.annotation.Nullable java.util.List> attributesList) {
this.attributesList = attributesList;
return this;
}
public void unsetAttributesList() {
this.attributesList = null;
}
/** Returns true if field attributesList is set (has been assigned a value) and false otherwise */
public boolean isSetAttributesList() {
return this.attributesList != null;
}
public void setAttributesListIsSet(boolean value) {
if (!value) {
this.attributesList = null;
}
}
public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case SESSION_ID:
if (value == null) {
unsetSessionId();
} else {
setSessionId((java.lang.Long)value);
}
break;
case PREFIX_PATH:
if (value == null) {
unsetPrefixPath();
} else {
setPrefixPath((java.lang.String)value);
}
break;
case MEASUREMENTS:
if (value == null) {
unsetMeasurements();
} else {
setMeasurements((java.util.List)value);
}
break;
case DATA_TYPES:
if (value == null) {
unsetDataTypes();
} else {
setDataTypes((java.util.List)value);
}
break;
case ENCODINGS:
if (value == null) {
unsetEncodings();
} else {
setEncodings((java.util.List)value);
}
break;
case COMPRESSORS:
if (value == null) {
unsetCompressors();
} else {
setCompressors((java.util.List)value);
}
break;
case MEASUREMENT_ALIAS:
if (value == null) {
unsetMeasurementAlias();
} else {
setMeasurementAlias((java.util.List)value);
}
break;
case TAGS_LIST:
if (value == null) {
unsetTagsList();
} else {
setTagsList((java.util.List>)value);
}
break;
case ATTRIBUTES_LIST:
if (value == null) {
unsetAttributesList();
} else {
setAttributesList((java.util.List>)value);
}
break;
}
}
@org.apache.thrift.annotation.Nullable
public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case SESSION_ID:
return getSessionId();
case PREFIX_PATH:
return getPrefixPath();
case MEASUREMENTS:
return getMeasurements();
case DATA_TYPES:
return getDataTypes();
case ENCODINGS:
return getEncodings();
case COMPRESSORS:
return getCompressors();
case MEASUREMENT_ALIAS:
return getMeasurementAlias();
case TAGS_LIST:
return getTagsList();
case ATTRIBUTES_LIST:
return getAttributesList();
}
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 SESSION_ID:
return isSetSessionId();
case PREFIX_PATH:
return isSetPrefixPath();
case MEASUREMENTS:
return isSetMeasurements();
case DATA_TYPES:
return isSetDataTypes();
case ENCODINGS:
return isSetEncodings();
case COMPRESSORS:
return isSetCompressors();
case MEASUREMENT_ALIAS:
return isSetMeasurementAlias();
case TAGS_LIST:
return isSetTagsList();
case ATTRIBUTES_LIST:
return isSetAttributesList();
}
throw new java.lang.IllegalStateException();
}
@Override
public boolean equals(java.lang.Object that) {
if (that instanceof TSCreateAlignedTimeseriesReq)
return this.equals((TSCreateAlignedTimeseriesReq)that);
return false;
}
public boolean equals(TSCreateAlignedTimeseriesReq that) {
if (that == null)
return false;
if (this == that)
return true;
boolean this_present_sessionId = true;
boolean that_present_sessionId = true;
if (this_present_sessionId || that_present_sessionId) {
if (!(this_present_sessionId && that_present_sessionId))
return false;
if (this.sessionId != that.sessionId)
return false;
}
boolean this_present_prefixPath = true && this.isSetPrefixPath();
boolean that_present_prefixPath = true && that.isSetPrefixPath();
if (this_present_prefixPath || that_present_prefixPath) {
if (!(this_present_prefixPath && that_present_prefixPath))
return false;
if (!this.prefixPath.equals(that.prefixPath))
return false;
}
boolean this_present_measurements = true && this.isSetMeasurements();
boolean that_present_measurements = true && that.isSetMeasurements();
if (this_present_measurements || that_present_measurements) {
if (!(this_present_measurements && that_present_measurements))
return false;
if (!this.measurements.equals(that.measurements))
return false;
}
boolean this_present_dataTypes = true && this.isSetDataTypes();
boolean that_present_dataTypes = true && that.isSetDataTypes();
if (this_present_dataTypes || that_present_dataTypes) {
if (!(this_present_dataTypes && that_present_dataTypes))
return false;
if (!this.dataTypes.equals(that.dataTypes))
return false;
}
boolean this_present_encodings = true && this.isSetEncodings();
boolean that_present_encodings = true && that.isSetEncodings();
if (this_present_encodings || that_present_encodings) {
if (!(this_present_encodings && that_present_encodings))
return false;
if (!this.encodings.equals(that.encodings))
return false;
}
boolean this_present_compressors = true && this.isSetCompressors();
boolean that_present_compressors = true && that.isSetCompressors();
if (this_present_compressors || that_present_compressors) {
if (!(this_present_compressors && that_present_compressors))
return false;
if (!this.compressors.equals(that.compressors))
return false;
}
boolean this_present_measurementAlias = true && this.isSetMeasurementAlias();
boolean that_present_measurementAlias = true && that.isSetMeasurementAlias();
if (this_present_measurementAlias || that_present_measurementAlias) {
if (!(this_present_measurementAlias && that_present_measurementAlias))
return false;
if (!this.measurementAlias.equals(that.measurementAlias))
return false;
}
boolean this_present_tagsList = true && this.isSetTagsList();
boolean that_present_tagsList = true && that.isSetTagsList();
if (this_present_tagsList || that_present_tagsList) {
if (!(this_present_tagsList && that_present_tagsList))
return false;
if (!this.tagsList.equals(that.tagsList))
return false;
}
boolean this_present_attributesList = true && this.isSetAttributesList();
boolean that_present_attributesList = true && that.isSetAttributesList();
if (this_present_attributesList || that_present_attributesList) {
if (!(this_present_attributesList && that_present_attributesList))
return false;
if (!this.attributesList.equals(that.attributesList))
return false;
}
return true;
}
@Override
public int hashCode() {
int hashCode = 1;
hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(sessionId);
hashCode = hashCode * 8191 + ((isSetPrefixPath()) ? 131071 : 524287);
if (isSetPrefixPath())
hashCode = hashCode * 8191 + prefixPath.hashCode();
hashCode = hashCode * 8191 + ((isSetMeasurements()) ? 131071 : 524287);
if (isSetMeasurements())
hashCode = hashCode * 8191 + measurements.hashCode();
hashCode = hashCode * 8191 + ((isSetDataTypes()) ? 131071 : 524287);
if (isSetDataTypes())
hashCode = hashCode * 8191 + dataTypes.hashCode();
hashCode = hashCode * 8191 + ((isSetEncodings()) ? 131071 : 524287);
if (isSetEncodings())
hashCode = hashCode * 8191 + encodings.hashCode();
hashCode = hashCode * 8191 + ((isSetCompressors()) ? 131071 : 524287);
if (isSetCompressors())
hashCode = hashCode * 8191 + compressors.hashCode();
hashCode = hashCode * 8191 + ((isSetMeasurementAlias()) ? 131071 : 524287);
if (isSetMeasurementAlias())
hashCode = hashCode * 8191 + measurementAlias.hashCode();
hashCode = hashCode * 8191 + ((isSetTagsList()) ? 131071 : 524287);
if (isSetTagsList())
hashCode = hashCode * 8191 + tagsList.hashCode();
hashCode = hashCode * 8191 + ((isSetAttributesList()) ? 131071 : 524287);
if (isSetAttributesList())
hashCode = hashCode * 8191 + attributesList.hashCode();
return hashCode;
}
@Override
public int compareTo(TSCreateAlignedTimeseriesReq other) {
if (!getClass().equals(other.getClass())) {
return getClass().getName().compareTo(other.getClass().getName());
}
int lastComparison = 0;
lastComparison = java.lang.Boolean.compare(isSetSessionId(), other.isSetSessionId());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetSessionId()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sessionId, other.sessionId);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetPrefixPath(), other.isSetPrefixPath());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetPrefixPath()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.prefixPath, other.prefixPath);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetMeasurements(), other.isSetMeasurements());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetMeasurements()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.measurements, other.measurements);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetDataTypes(), other.isSetDataTypes());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetDataTypes()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dataTypes, other.dataTypes);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetEncodings(), other.isSetEncodings());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetEncodings()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.encodings, other.encodings);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetCompressors(), other.isSetCompressors());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetCompressors()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.compressors, other.compressors);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetMeasurementAlias(), other.isSetMeasurementAlias());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetMeasurementAlias()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.measurementAlias, other.measurementAlias);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetTagsList(), other.isSetTagsList());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetTagsList()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tagsList, other.tagsList);
if (lastComparison != 0) {
return lastComparison;
}
}
lastComparison = java.lang.Boolean.compare(isSetAttributesList(), other.isSetAttributesList());
if (lastComparison != 0) {
return lastComparison;
}
if (isSetAttributesList()) {
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.attributesList, other.attributesList);
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("TSCreateAlignedTimeseriesReq(");
boolean first = true;
sb.append("sessionId:");
sb.append(this.sessionId);
first = false;
if (!first) sb.append(", ");
sb.append("prefixPath:");
if (this.prefixPath == null) {
sb.append("null");
} else {
sb.append(this.prefixPath);
}
first = false;
if (!first) sb.append(", ");
sb.append("measurements:");
if (this.measurements == null) {
sb.append("null");
} else {
sb.append(this.measurements);
}
first = false;
if (!first) sb.append(", ");
sb.append("dataTypes:");
if (this.dataTypes == null) {
sb.append("null");
} else {
sb.append(this.dataTypes);
}
first = false;
if (!first) sb.append(", ");
sb.append("encodings:");
if (this.encodings == null) {
sb.append("null");
} else {
sb.append(this.encodings);
}
first = false;
if (!first) sb.append(", ");
sb.append("compressors:");
if (this.compressors == null) {
sb.append("null");
} else {
sb.append(this.compressors);
}
first = false;
if (isSetMeasurementAlias()) {
if (!first) sb.append(", ");
sb.append("measurementAlias:");
if (this.measurementAlias == null) {
sb.append("null");
} else {
sb.append(this.measurementAlias);
}
first = false;
}
if (isSetTagsList()) {
if (!first) sb.append(", ");
sb.append("tagsList:");
if (this.tagsList == null) {
sb.append("null");
} else {
sb.append(this.tagsList);
}
first = false;
}
if (isSetAttributesList()) {
if (!first) sb.append(", ");
sb.append("attributesList:");
if (this.attributesList == null) {
sb.append("null");
} else {
sb.append(this.attributesList);
}
first = false;
}
sb.append(")");
return sb.toString();
}
public void validate() throws org.apache.thrift.TException {
// check for required fields
// alas, we cannot check 'sessionId' because it's a primitive and you chose the non-beans generator.
if (prefixPath == null) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'prefixPath' was not present! Struct: " + toString());
}
if (measurements == null) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'measurements' was not present! Struct: " + toString());
}
if (dataTypes == null) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'dataTypes' was not present! Struct: " + toString());
}
if (encodings == null) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'encodings' was not present! Struct: " + toString());
}
if (compressors == null) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'compressors' was not present! Struct: " + toString());
}
// 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 {
// 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 TSCreateAlignedTimeseriesReqStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TSCreateAlignedTimeseriesReqStandardScheme getScheme() {
return new TSCreateAlignedTimeseriesReqStandardScheme();
}
}
private static class TSCreateAlignedTimeseriesReqStandardScheme extends org.apache.thrift.scheme.StandardScheme {
public void read(org.apache.thrift.protocol.TProtocol iprot, TSCreateAlignedTimeseriesReq 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: // SESSION_ID
if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
struct.sessionId = iprot.readI64();
struct.setSessionIdIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 2: // PREFIX_PATH
if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
struct.prefixPath = iprot.readString();
struct.setPrefixPathIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 3: // MEASUREMENTS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list444 = iprot.readListBegin();
struct.measurements = new java.util.ArrayList(_list444.size);
@org.apache.thrift.annotation.Nullable java.lang.String _elem445;
for (int _i446 = 0; _i446 < _list444.size; ++_i446)
{
_elem445 = iprot.readString();
struct.measurements.add(_elem445);
}
iprot.readListEnd();
}
struct.setMeasurementsIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 4: // DATA_TYPES
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list447 = iprot.readListBegin();
struct.dataTypes = new java.util.ArrayList(_list447.size);
int _elem448;
for (int _i449 = 0; _i449 < _list447.size; ++_i449)
{
_elem448 = iprot.readI32();
struct.dataTypes.add(_elem448);
}
iprot.readListEnd();
}
struct.setDataTypesIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 5: // ENCODINGS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list450 = iprot.readListBegin();
struct.encodings = new java.util.ArrayList(_list450.size);
int _elem451;
for (int _i452 = 0; _i452 < _list450.size; ++_i452)
{
_elem451 = iprot.readI32();
struct.encodings.add(_elem451);
}
iprot.readListEnd();
}
struct.setEncodingsIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 6: // COMPRESSORS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list453 = iprot.readListBegin();
struct.compressors = new java.util.ArrayList(_list453.size);
int _elem454;
for (int _i455 = 0; _i455 < _list453.size; ++_i455)
{
_elem454 = iprot.readI32();
struct.compressors.add(_elem454);
}
iprot.readListEnd();
}
struct.setCompressorsIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 7: // MEASUREMENT_ALIAS
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list456 = iprot.readListBegin();
struct.measurementAlias = new java.util.ArrayList(_list456.size);
@org.apache.thrift.annotation.Nullable java.lang.String _elem457;
for (int _i458 = 0; _i458 < _list456.size; ++_i458)
{
_elem457 = iprot.readString();
struct.measurementAlias.add(_elem457);
}
iprot.readListEnd();
}
struct.setMeasurementAliasIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 8: // TAGS_LIST
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list459 = iprot.readListBegin();
struct.tagsList = new java.util.ArrayList>(_list459.size);
@org.apache.thrift.annotation.Nullable java.util.Map _elem460;
for (int _i461 = 0; _i461 < _list459.size; ++_i461)
{
{
org.apache.thrift.protocol.TMap _map462 = iprot.readMapBegin();
_elem460 = new java.util.HashMap(2*_map462.size);
@org.apache.thrift.annotation.Nullable java.lang.String _key463;
@org.apache.thrift.annotation.Nullable java.lang.String _val464;
for (int _i465 = 0; _i465 < _map462.size; ++_i465)
{
_key463 = iprot.readString();
_val464 = iprot.readString();
_elem460.put(_key463, _val464);
}
iprot.readMapEnd();
}
struct.tagsList.add(_elem460);
}
iprot.readListEnd();
}
struct.setTagsListIsSet(true);
} else {
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
}
break;
case 9: // ATTRIBUTES_LIST
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list466 = iprot.readListBegin();
struct.attributesList = new java.util.ArrayList>(_list466.size);
@org.apache.thrift.annotation.Nullable java.util.Map _elem467;
for (int _i468 = 0; _i468 < _list466.size; ++_i468)
{
{
org.apache.thrift.protocol.TMap _map469 = iprot.readMapBegin();
_elem467 = new java.util.HashMap(2*_map469.size);
@org.apache.thrift.annotation.Nullable java.lang.String _key470;
@org.apache.thrift.annotation.Nullable java.lang.String _val471;
for (int _i472 = 0; _i472 < _map469.size; ++_i472)
{
_key470 = iprot.readString();
_val471 = iprot.readString();
_elem467.put(_key470, _val471);
}
iprot.readMapEnd();
}
struct.attributesList.add(_elem467);
}
iprot.readListEnd();
}
struct.setAttributesListIsSet(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.isSetSessionId()) {
throw new org.apache.thrift.protocol.TProtocolException("Required field 'sessionId' was not found in serialized data! Struct: " + toString());
}
struct.validate();
}
public void write(org.apache.thrift.protocol.TProtocol oprot, TSCreateAlignedTimeseriesReq struct) throws org.apache.thrift.TException {
struct.validate();
oprot.writeStructBegin(STRUCT_DESC);
oprot.writeFieldBegin(SESSION_ID_FIELD_DESC);
oprot.writeI64(struct.sessionId);
oprot.writeFieldEnd();
if (struct.prefixPath != null) {
oprot.writeFieldBegin(PREFIX_PATH_FIELD_DESC);
oprot.writeString(struct.prefixPath);
oprot.writeFieldEnd();
}
if (struct.measurements != null) {
oprot.writeFieldBegin(MEASUREMENTS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.measurements.size()));
for (java.lang.String _iter473 : struct.measurements)
{
oprot.writeString(_iter473);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
if (struct.dataTypes != null) {
oprot.writeFieldBegin(DATA_TYPES_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, struct.dataTypes.size()));
for (int _iter474 : struct.dataTypes)
{
oprot.writeI32(_iter474);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
if (struct.encodings != null) {
oprot.writeFieldBegin(ENCODINGS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, struct.encodings.size()));
for (int _iter475 : struct.encodings)
{
oprot.writeI32(_iter475);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
if (struct.compressors != null) {
oprot.writeFieldBegin(COMPRESSORS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, struct.compressors.size()));
for (int _iter476 : struct.compressors)
{
oprot.writeI32(_iter476);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
if (struct.measurementAlias != null) {
if (struct.isSetMeasurementAlias()) {
oprot.writeFieldBegin(MEASUREMENT_ALIAS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.measurementAlias.size()));
for (java.lang.String _iter477 : struct.measurementAlias)
{
oprot.writeString(_iter477);
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
}
if (struct.tagsList != null) {
if (struct.isSetTagsList()) {
oprot.writeFieldBegin(TAGS_LIST_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.MAP, struct.tagsList.size()));
for (java.util.Map _iter478 : struct.tagsList)
{
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, _iter478.size()));
for (java.util.Map.Entry _iter479 : _iter478.entrySet())
{
oprot.writeString(_iter479.getKey());
oprot.writeString(_iter479.getValue());
}
oprot.writeMapEnd();
}
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
}
if (struct.attributesList != null) {
if (struct.isSetAttributesList()) {
oprot.writeFieldBegin(ATTRIBUTES_LIST_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.MAP, struct.attributesList.size()));
for (java.util.Map _iter480 : struct.attributesList)
{
{
oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, _iter480.size()));
for (java.util.Map.Entry _iter481 : _iter480.entrySet())
{
oprot.writeString(_iter481.getKey());
oprot.writeString(_iter481.getValue());
}
oprot.writeMapEnd();
}
}
oprot.writeListEnd();
}
oprot.writeFieldEnd();
}
}
oprot.writeFieldStop();
oprot.writeStructEnd();
}
}
private static class TSCreateAlignedTimeseriesReqTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public TSCreateAlignedTimeseriesReqTupleScheme getScheme() {
return new TSCreateAlignedTimeseriesReqTupleScheme();
}
}
private static class TSCreateAlignedTimeseriesReqTupleScheme extends org.apache.thrift.scheme.TupleScheme {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, TSCreateAlignedTimeseriesReq struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
oprot.writeI64(struct.sessionId);
oprot.writeString(struct.prefixPath);
{
oprot.writeI32(struct.measurements.size());
for (java.lang.String _iter482 : struct.measurements)
{
oprot.writeString(_iter482);
}
}
{
oprot.writeI32(struct.dataTypes.size());
for (int _iter483 : struct.dataTypes)
{
oprot.writeI32(_iter483);
}
}
{
oprot.writeI32(struct.encodings.size());
for (int _iter484 : struct.encodings)
{
oprot.writeI32(_iter484);
}
}
{
oprot.writeI32(struct.compressors.size());
for (int _iter485 : struct.compressors)
{
oprot.writeI32(_iter485);
}
}
java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetMeasurementAlias()) {
optionals.set(0);
}
if (struct.isSetTagsList()) {
optionals.set(1);
}
if (struct.isSetAttributesList()) {
optionals.set(2);
}
oprot.writeBitSet(optionals, 3);
if (struct.isSetMeasurementAlias()) {
{
oprot.writeI32(struct.measurementAlias.size());
for (java.lang.String _iter486 : struct.measurementAlias)
{
oprot.writeString(_iter486);
}
}
}
if (struct.isSetTagsList()) {
{
oprot.writeI32(struct.tagsList.size());
for (java.util.Map _iter487 : struct.tagsList)
{
{
oprot.writeI32(_iter487.size());
for (java.util.Map.Entry _iter488 : _iter487.entrySet())
{
oprot.writeString(_iter488.getKey());
oprot.writeString(_iter488.getValue());
}
}
}
}
}
if (struct.isSetAttributesList()) {
{
oprot.writeI32(struct.attributesList.size());
for (java.util.Map _iter489 : struct.attributesList)
{
{
oprot.writeI32(_iter489.size());
for (java.util.Map.Entry _iter490 : _iter489.entrySet())
{
oprot.writeString(_iter490.getKey());
oprot.writeString(_iter490.getValue());
}
}
}
}
}
}
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, TSCreateAlignedTimeseriesReq struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
struct.sessionId = iprot.readI64();
struct.setSessionIdIsSet(true);
struct.prefixPath = iprot.readString();
struct.setPrefixPathIsSet(true);
{
org.apache.thrift.protocol.TList _list491 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
struct.measurements = new java.util.ArrayList(_list491.size);
@org.apache.thrift.annotation.Nullable java.lang.String _elem492;
for (int _i493 = 0; _i493 < _list491.size; ++_i493)
{
_elem492 = iprot.readString();
struct.measurements.add(_elem492);
}
}
struct.setMeasurementsIsSet(true);
{
org.apache.thrift.protocol.TList _list494 = iprot.readListBegin(org.apache.thrift.protocol.TType.I32);
struct.dataTypes = new java.util.ArrayList(_list494.size);
int _elem495;
for (int _i496 = 0; _i496 < _list494.size; ++_i496)
{
_elem495 = iprot.readI32();
struct.dataTypes.add(_elem495);
}
}
struct.setDataTypesIsSet(true);
{
org.apache.thrift.protocol.TList _list497 = iprot.readListBegin(org.apache.thrift.protocol.TType.I32);
struct.encodings = new java.util.ArrayList(_list497.size);
int _elem498;
for (int _i499 = 0; _i499 < _list497.size; ++_i499)
{
_elem498 = iprot.readI32();
struct.encodings.add(_elem498);
}
}
struct.setEncodingsIsSet(true);
{
org.apache.thrift.protocol.TList _list500 = iprot.readListBegin(org.apache.thrift.protocol.TType.I32);
struct.compressors = new java.util.ArrayList(_list500.size);
int _elem501;
for (int _i502 = 0; _i502 < _list500.size; ++_i502)
{
_elem501 = iprot.readI32();
struct.compressors.add(_elem501);
}
}
struct.setCompressorsIsSet(true);
java.util.BitSet incoming = iprot.readBitSet(3);
if (incoming.get(0)) {
{
org.apache.thrift.protocol.TList _list503 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
struct.measurementAlias = new java.util.ArrayList(_list503.size);
@org.apache.thrift.annotation.Nullable java.lang.String _elem504;
for (int _i505 = 0; _i505 < _list503.size; ++_i505)
{
_elem504 = iprot.readString();
struct.measurementAlias.add(_elem504);
}
}
struct.setMeasurementAliasIsSet(true);
}
if (incoming.get(1)) {
{
org.apache.thrift.protocol.TList _list506 = iprot.readListBegin(org.apache.thrift.protocol.TType.MAP);
struct.tagsList = new java.util.ArrayList>(_list506.size);
@org.apache.thrift.annotation.Nullable java.util.Map _elem507;
for (int _i508 = 0; _i508 < _list506.size; ++_i508)
{
{
org.apache.thrift.protocol.TMap _map509 = iprot.readMapBegin(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING);
_elem507 = new java.util.HashMap(2*_map509.size);
@org.apache.thrift.annotation.Nullable java.lang.String _key510;
@org.apache.thrift.annotation.Nullable java.lang.String _val511;
for (int _i512 = 0; _i512 < _map509.size; ++_i512)
{
_key510 = iprot.readString();
_val511 = iprot.readString();
_elem507.put(_key510, _val511);
}
}
struct.tagsList.add(_elem507);
}
}
struct.setTagsListIsSet(true);
}
if (incoming.get(2)) {
{
org.apache.thrift.protocol.TList _list513 = iprot.readListBegin(org.apache.thrift.protocol.TType.MAP);
struct.attributesList = new java.util.ArrayList>(_list513.size);
@org.apache.thrift.annotation.Nullable java.util.Map _elem514;
for (int _i515 = 0; _i515 < _list513.size; ++_i515)
{
{
org.apache.thrift.protocol.TMap _map516 = iprot.readMapBegin(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING);
_elem514 = new java.util.HashMap(2*_map516.size);
@org.apache.thrift.annotation.Nullable java.lang.String _key517;
@org.apache.thrift.annotation.Nullable java.lang.String _val518;
for (int _i519 = 0; _i519 < _map516.size; ++_i519)
{
_key517 = iprot.readString();
_val518 = iprot.readString();
_elem514.put(_key517, _val518);
}
}
struct.attributesList.add(_elem514);
}
}
struct.setAttributesListIsSet(true);
}
}
}
private static 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();
}
}