You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by se...@apache.org on 2018/07/13 01:40:18 UTC
[16/91] [abbrv] [partial] hive git commit: HIVE-20097 : Convert
standalone-metastore to a submodule (Alexander Kolbasov reviewed by Vihang
Karajgaonkar)
http://git-wip-us.apache.org/repos/asf/hive/blob/20eb7b51/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MapSchemaVersionToSerdeRequest.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MapSchemaVersionToSerdeRequest.java b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MapSchemaVersionToSerdeRequest.java
new file mode 100644
index 0000000..81eb732
--- /dev/null
+++ b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MapSchemaVersionToSerdeRequest.java
@@ -0,0 +1,504 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.3)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ * @generated
+ */
+package org.apache.hadoop.hive.metastore.api;
+
+import org.apache.thrift.scheme.IScheme;
+import org.apache.thrift.scheme.SchemeFactory;
+import org.apache.thrift.scheme.StandardScheme;
+
+import org.apache.thrift.scheme.TupleScheme;
+import org.apache.thrift.protocol.TTupleProtocol;
+import org.apache.thrift.protocol.TProtocolException;
+import org.apache.thrift.EncodingUtils;
+import org.apache.thrift.TException;
+import org.apache.thrift.async.AsyncMethodCallback;
+import org.apache.thrift.server.AbstractNonblockingServer.*;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.EnumMap;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.EnumSet;
+import java.util.Collections;
+import java.util.BitSet;
+import java.nio.ByteBuffer;
+import java.util.Arrays;
+import javax.annotation.Generated;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@org.apache.hadoop.classification.InterfaceAudience.Public @org.apache.hadoop.classification.InterfaceStability.Stable public class MapSchemaVersionToSerdeRequest implements org.apache.thrift.TBase<MapSchemaVersionToSerdeRequest, MapSchemaVersionToSerdeRequest._Fields>, java.io.Serializable, Cloneable, Comparable<MapSchemaVersionToSerdeRequest> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("MapSchemaVersionToSerdeRequest");
+
+ private static final org.apache.thrift.protocol.TField SCHEMA_VERSION_FIELD_DESC = new org.apache.thrift.protocol.TField("schemaVersion", org.apache.thrift.protocol.TType.STRUCT, (short)1);
+ private static final org.apache.thrift.protocol.TField SERDE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("serdeName", org.apache.thrift.protocol.TType.STRING, (short)2);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new MapSchemaVersionToSerdeRequestStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new MapSchemaVersionToSerdeRequestTupleSchemeFactory());
+ }
+
+ private SchemaVersionDescriptor schemaVersion; // required
+ private String serdeName; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ SCHEMA_VERSION((short)1, "schemaVersion"),
+ SERDE_NAME((short)2, "serdeName");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // SCHEMA_VERSION
+ return SCHEMA_VERSION;
+ case 2: // SERDE_NAME
+ return SERDE_NAME;
+ 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 IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.SCHEMA_VERSION, new org.apache.thrift.meta_data.FieldMetaData("schemaVersion", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, SchemaVersionDescriptor.class)));
+ tmpMap.put(_Fields.SERDE_NAME, new org.apache.thrift.meta_data.FieldMetaData("serdeName", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(MapSchemaVersionToSerdeRequest.class, metaDataMap);
+ }
+
+ public MapSchemaVersionToSerdeRequest() {
+ }
+
+ public MapSchemaVersionToSerdeRequest(
+ SchemaVersionDescriptor schemaVersion,
+ String serdeName)
+ {
+ this();
+ this.schemaVersion = schemaVersion;
+ this.serdeName = serdeName;
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public MapSchemaVersionToSerdeRequest(MapSchemaVersionToSerdeRequest other) {
+ if (other.isSetSchemaVersion()) {
+ this.schemaVersion = new SchemaVersionDescriptor(other.schemaVersion);
+ }
+ if (other.isSetSerdeName()) {
+ this.serdeName = other.serdeName;
+ }
+ }
+
+ public MapSchemaVersionToSerdeRequest deepCopy() {
+ return new MapSchemaVersionToSerdeRequest(this);
+ }
+
+ @Override
+ public void clear() {
+ this.schemaVersion = null;
+ this.serdeName = null;
+ }
+
+ public SchemaVersionDescriptor getSchemaVersion() {
+ return this.schemaVersion;
+ }
+
+ public void setSchemaVersion(SchemaVersionDescriptor schemaVersion) {
+ this.schemaVersion = schemaVersion;
+ }
+
+ public void unsetSchemaVersion() {
+ this.schemaVersion = null;
+ }
+
+ /** Returns true if field schemaVersion is set (has been assigned a value) and false otherwise */
+ public boolean isSetSchemaVersion() {
+ return this.schemaVersion != null;
+ }
+
+ public void setSchemaVersionIsSet(boolean value) {
+ if (!value) {
+ this.schemaVersion = null;
+ }
+ }
+
+ public String getSerdeName() {
+ return this.serdeName;
+ }
+
+ public void setSerdeName(String serdeName) {
+ this.serdeName = serdeName;
+ }
+
+ public void unsetSerdeName() {
+ this.serdeName = null;
+ }
+
+ /** Returns true if field serdeName is set (has been assigned a value) and false otherwise */
+ public boolean isSetSerdeName() {
+ return this.serdeName != null;
+ }
+
+ public void setSerdeNameIsSet(boolean value) {
+ if (!value) {
+ this.serdeName = null;
+ }
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case SCHEMA_VERSION:
+ if (value == null) {
+ unsetSchemaVersion();
+ } else {
+ setSchemaVersion((SchemaVersionDescriptor)value);
+ }
+ break;
+
+ case SERDE_NAME:
+ if (value == null) {
+ unsetSerdeName();
+ } else {
+ setSerdeName((String)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case SCHEMA_VERSION:
+ return getSchemaVersion();
+
+ case SERDE_NAME:
+ return getSerdeName();
+
+ }
+ throw new 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 IllegalArgumentException();
+ }
+
+ switch (field) {
+ case SCHEMA_VERSION:
+ return isSetSchemaVersion();
+ case SERDE_NAME:
+ return isSetSerdeName();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof MapSchemaVersionToSerdeRequest)
+ return this.equals((MapSchemaVersionToSerdeRequest)that);
+ return false;
+ }
+
+ public boolean equals(MapSchemaVersionToSerdeRequest that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_schemaVersion = true && this.isSetSchemaVersion();
+ boolean that_present_schemaVersion = true && that.isSetSchemaVersion();
+ if (this_present_schemaVersion || that_present_schemaVersion) {
+ if (!(this_present_schemaVersion && that_present_schemaVersion))
+ return false;
+ if (!this.schemaVersion.equals(that.schemaVersion))
+ return false;
+ }
+
+ boolean this_present_serdeName = true && this.isSetSerdeName();
+ boolean that_present_serdeName = true && that.isSetSerdeName();
+ if (this_present_serdeName || that_present_serdeName) {
+ if (!(this_present_serdeName && that_present_serdeName))
+ return false;
+ if (!this.serdeName.equals(that.serdeName))
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_schemaVersion = true && (isSetSchemaVersion());
+ list.add(present_schemaVersion);
+ if (present_schemaVersion)
+ list.add(schemaVersion);
+
+ boolean present_serdeName = true && (isSetSerdeName());
+ list.add(present_serdeName);
+ if (present_serdeName)
+ list.add(serdeName);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(MapSchemaVersionToSerdeRequest other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetSchemaVersion()).compareTo(other.isSetSchemaVersion());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSchemaVersion()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.schemaVersion, other.schemaVersion);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetSerdeName()).compareTo(other.isSetSerdeName());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSerdeName()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.serdeName, other.serdeName);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("MapSchemaVersionToSerdeRequest(");
+ boolean first = true;
+
+ sb.append("schemaVersion:");
+ if (this.schemaVersion == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.schemaVersion);
+ }
+ first = false;
+ if (!first) sb.append(", ");
+ sb.append("serdeName:");
+ if (this.serdeName == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.serdeName);
+ }
+ first = false;
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ // check for sub-struct validity
+ if (schemaVersion != null) {
+ schemaVersion.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, 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 MapSchemaVersionToSerdeRequestStandardSchemeFactory implements SchemeFactory {
+ public MapSchemaVersionToSerdeRequestStandardScheme getScheme() {
+ return new MapSchemaVersionToSerdeRequestStandardScheme();
+ }
+ }
+
+ private static class MapSchemaVersionToSerdeRequestStandardScheme extends StandardScheme<MapSchemaVersionToSerdeRequest> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, MapSchemaVersionToSerdeRequest 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: // SCHEMA_VERSION
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
+ struct.schemaVersion = new SchemaVersionDescriptor();
+ struct.schemaVersion.read(iprot);
+ struct.setSchemaVersionIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 2: // SERDE_NAME
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.serdeName = iprot.readString();
+ struct.setSerdeNameIsSet(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();
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, MapSchemaVersionToSerdeRequest struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.schemaVersion != null) {
+ oprot.writeFieldBegin(SCHEMA_VERSION_FIELD_DESC);
+ struct.schemaVersion.write(oprot);
+ oprot.writeFieldEnd();
+ }
+ if (struct.serdeName != null) {
+ oprot.writeFieldBegin(SERDE_NAME_FIELD_DESC);
+ oprot.writeString(struct.serdeName);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class MapSchemaVersionToSerdeRequestTupleSchemeFactory implements SchemeFactory {
+ public MapSchemaVersionToSerdeRequestTupleScheme getScheme() {
+ return new MapSchemaVersionToSerdeRequestTupleScheme();
+ }
+ }
+
+ private static class MapSchemaVersionToSerdeRequestTupleScheme extends TupleScheme<MapSchemaVersionToSerdeRequest> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, MapSchemaVersionToSerdeRequest struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetSchemaVersion()) {
+ optionals.set(0);
+ }
+ if (struct.isSetSerdeName()) {
+ optionals.set(1);
+ }
+ oprot.writeBitSet(optionals, 2);
+ if (struct.isSetSchemaVersion()) {
+ struct.schemaVersion.write(oprot);
+ }
+ if (struct.isSetSerdeName()) {
+ oprot.writeString(struct.serdeName);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, MapSchemaVersionToSerdeRequest struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(2);
+ if (incoming.get(0)) {
+ struct.schemaVersion = new SchemaVersionDescriptor();
+ struct.schemaVersion.read(iprot);
+ struct.setSchemaVersionIsSet(true);
+ }
+ if (incoming.get(1)) {
+ struct.serdeName = iprot.readString();
+ struct.setSerdeNameIsSet(true);
+ }
+ }
+ }
+
+}
+
http://git-wip-us.apache.org/repos/asf/hive/blob/20eb7b51/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Materialization.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Materialization.java b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Materialization.java
new file mode 100644
index 0000000..3510995
--- /dev/null
+++ b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/Materialization.java
@@ -0,0 +1,750 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.3)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ * @generated
+ */
+package org.apache.hadoop.hive.metastore.api;
+
+import org.apache.thrift.scheme.IScheme;
+import org.apache.thrift.scheme.SchemeFactory;
+import org.apache.thrift.scheme.StandardScheme;
+
+import org.apache.thrift.scheme.TupleScheme;
+import org.apache.thrift.protocol.TTupleProtocol;
+import org.apache.thrift.protocol.TProtocolException;
+import org.apache.thrift.EncodingUtils;
+import org.apache.thrift.TException;
+import org.apache.thrift.async.AsyncMethodCallback;
+import org.apache.thrift.server.AbstractNonblockingServer.*;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.EnumMap;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.EnumSet;
+import java.util.Collections;
+import java.util.BitSet;
+import java.nio.ByteBuffer;
+import java.util.Arrays;
+import javax.annotation.Generated;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@org.apache.hadoop.classification.InterfaceAudience.Public @org.apache.hadoop.classification.InterfaceStability.Stable public class Materialization implements org.apache.thrift.TBase<Materialization, Materialization._Fields>, java.io.Serializable, Cloneable, Comparable<Materialization> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Materialization");
+
+ private static final org.apache.thrift.protocol.TField TABLES_USED_FIELD_DESC = new org.apache.thrift.protocol.TField("tablesUsed", org.apache.thrift.protocol.TType.SET, (short)1);
+ private static final org.apache.thrift.protocol.TField VALID_TXN_LIST_FIELD_DESC = new org.apache.thrift.protocol.TField("validTxnList", org.apache.thrift.protocol.TType.STRING, (short)2);
+ private static final org.apache.thrift.protocol.TField INVALIDATION_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("invalidationTime", org.apache.thrift.protocol.TType.I64, (short)3);
+ private static final org.apache.thrift.protocol.TField SOURCE_TABLES_UPDATE_DELETE_MODIFIED_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceTablesUpdateDeleteModified", org.apache.thrift.protocol.TType.BOOL, (short)4);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new MaterializationStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new MaterializationTupleSchemeFactory());
+ }
+
+ private Set<String> tablesUsed; // required
+ private String validTxnList; // optional
+ private long invalidationTime; // optional
+ private boolean sourceTablesUpdateDeleteModified; // 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 {
+ TABLES_USED((short)1, "tablesUsed"),
+ VALID_TXN_LIST((short)2, "validTxnList"),
+ INVALIDATION_TIME((short)3, "invalidationTime"),
+ SOURCE_TABLES_UPDATE_DELETE_MODIFIED((short)4, "sourceTablesUpdateDeleteModified");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // TABLES_USED
+ return TABLES_USED;
+ case 2: // VALID_TXN_LIST
+ return VALID_TXN_LIST;
+ case 3: // INVALIDATION_TIME
+ return INVALIDATION_TIME;
+ case 4: // SOURCE_TABLES_UPDATE_DELETE_MODIFIED
+ return SOURCE_TABLES_UPDATE_DELETE_MODIFIED;
+ 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 IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ private static final int __INVALIDATIONTIME_ISSET_ID = 0;
+ private static final int __SOURCETABLESUPDATEDELETEMODIFIED_ISSET_ID = 1;
+ private byte __isset_bitfield = 0;
+ private static final _Fields optionals[] = {_Fields.VALID_TXN_LIST,_Fields.INVALIDATION_TIME,_Fields.SOURCE_TABLES_UPDATE_DELETE_MODIFIED};
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.TABLES_USED, new org.apache.thrift.meta_data.FieldMetaData("tablesUsed", org.apache.thrift.TFieldRequirementType.REQUIRED,
+ new org.apache.thrift.meta_data.SetMetaData(org.apache.thrift.protocol.TType.SET,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
+ tmpMap.put(_Fields.VALID_TXN_LIST, new org.apache.thrift.meta_data.FieldMetaData("validTxnList", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+ tmpMap.put(_Fields.INVALIDATION_TIME, new org.apache.thrift.meta_data.FieldMetaData("invalidationTime", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
+ tmpMap.put(_Fields.SOURCE_TABLES_UPDATE_DELETE_MODIFIED, new org.apache.thrift.meta_data.FieldMetaData("sourceTablesUpdateDeleteModified", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Materialization.class, metaDataMap);
+ }
+
+ public Materialization() {
+ }
+
+ public Materialization(
+ Set<String> tablesUsed)
+ {
+ this();
+ this.tablesUsed = tablesUsed;
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public Materialization(Materialization other) {
+ __isset_bitfield = other.__isset_bitfield;
+ if (other.isSetTablesUsed()) {
+ Set<String> __this__tablesUsed = new HashSet<String>(other.tablesUsed);
+ this.tablesUsed = __this__tablesUsed;
+ }
+ if (other.isSetValidTxnList()) {
+ this.validTxnList = other.validTxnList;
+ }
+ this.invalidationTime = other.invalidationTime;
+ this.sourceTablesUpdateDeleteModified = other.sourceTablesUpdateDeleteModified;
+ }
+
+ public Materialization deepCopy() {
+ return new Materialization(this);
+ }
+
+ @Override
+ public void clear() {
+ this.tablesUsed = null;
+ this.validTxnList = null;
+ setInvalidationTimeIsSet(false);
+ this.invalidationTime = 0;
+ setSourceTablesUpdateDeleteModifiedIsSet(false);
+ this.sourceTablesUpdateDeleteModified = false;
+ }
+
+ public int getTablesUsedSize() {
+ return (this.tablesUsed == null) ? 0 : this.tablesUsed.size();
+ }
+
+ public java.util.Iterator<String> getTablesUsedIterator() {
+ return (this.tablesUsed == null) ? null : this.tablesUsed.iterator();
+ }
+
+ public void addToTablesUsed(String elem) {
+ if (this.tablesUsed == null) {
+ this.tablesUsed = new HashSet<String>();
+ }
+ this.tablesUsed.add(elem);
+ }
+
+ public Set<String> getTablesUsed() {
+ return this.tablesUsed;
+ }
+
+ public void setTablesUsed(Set<String> tablesUsed) {
+ this.tablesUsed = tablesUsed;
+ }
+
+ public void unsetTablesUsed() {
+ this.tablesUsed = null;
+ }
+
+ /** Returns true if field tablesUsed is set (has been assigned a value) and false otherwise */
+ public boolean isSetTablesUsed() {
+ return this.tablesUsed != null;
+ }
+
+ public void setTablesUsedIsSet(boolean value) {
+ if (!value) {
+ this.tablesUsed = null;
+ }
+ }
+
+ public String getValidTxnList() {
+ return this.validTxnList;
+ }
+
+ public void setValidTxnList(String validTxnList) {
+ this.validTxnList = validTxnList;
+ }
+
+ public void unsetValidTxnList() {
+ this.validTxnList = null;
+ }
+
+ /** Returns true if field validTxnList is set (has been assigned a value) and false otherwise */
+ public boolean isSetValidTxnList() {
+ return this.validTxnList != null;
+ }
+
+ public void setValidTxnListIsSet(boolean value) {
+ if (!value) {
+ this.validTxnList = null;
+ }
+ }
+
+ public long getInvalidationTime() {
+ return this.invalidationTime;
+ }
+
+ public void setInvalidationTime(long invalidationTime) {
+ this.invalidationTime = invalidationTime;
+ setInvalidationTimeIsSet(true);
+ }
+
+ public void unsetInvalidationTime() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __INVALIDATIONTIME_ISSET_ID);
+ }
+
+ /** Returns true if field invalidationTime is set (has been assigned a value) and false otherwise */
+ public boolean isSetInvalidationTime() {
+ return EncodingUtils.testBit(__isset_bitfield, __INVALIDATIONTIME_ISSET_ID);
+ }
+
+ public void setInvalidationTimeIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __INVALIDATIONTIME_ISSET_ID, value);
+ }
+
+ public boolean isSourceTablesUpdateDeleteModified() {
+ return this.sourceTablesUpdateDeleteModified;
+ }
+
+ public void setSourceTablesUpdateDeleteModified(boolean sourceTablesUpdateDeleteModified) {
+ this.sourceTablesUpdateDeleteModified = sourceTablesUpdateDeleteModified;
+ setSourceTablesUpdateDeleteModifiedIsSet(true);
+ }
+
+ public void unsetSourceTablesUpdateDeleteModified() {
+ __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SOURCETABLESUPDATEDELETEMODIFIED_ISSET_ID);
+ }
+
+ /** Returns true if field sourceTablesUpdateDeleteModified is set (has been assigned a value) and false otherwise */
+ public boolean isSetSourceTablesUpdateDeleteModified() {
+ return EncodingUtils.testBit(__isset_bitfield, __SOURCETABLESUPDATEDELETEMODIFIED_ISSET_ID);
+ }
+
+ public void setSourceTablesUpdateDeleteModifiedIsSet(boolean value) {
+ __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SOURCETABLESUPDATEDELETEMODIFIED_ISSET_ID, value);
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case TABLES_USED:
+ if (value == null) {
+ unsetTablesUsed();
+ } else {
+ setTablesUsed((Set<String>)value);
+ }
+ break;
+
+ case VALID_TXN_LIST:
+ if (value == null) {
+ unsetValidTxnList();
+ } else {
+ setValidTxnList((String)value);
+ }
+ break;
+
+ case INVALIDATION_TIME:
+ if (value == null) {
+ unsetInvalidationTime();
+ } else {
+ setInvalidationTime((Long)value);
+ }
+ break;
+
+ case SOURCE_TABLES_UPDATE_DELETE_MODIFIED:
+ if (value == null) {
+ unsetSourceTablesUpdateDeleteModified();
+ } else {
+ setSourceTablesUpdateDeleteModified((Boolean)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case TABLES_USED:
+ return getTablesUsed();
+
+ case VALID_TXN_LIST:
+ return getValidTxnList();
+
+ case INVALIDATION_TIME:
+ return getInvalidationTime();
+
+ case SOURCE_TABLES_UPDATE_DELETE_MODIFIED:
+ return isSourceTablesUpdateDeleteModified();
+
+ }
+ throw new 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 IllegalArgumentException();
+ }
+
+ switch (field) {
+ case TABLES_USED:
+ return isSetTablesUsed();
+ case VALID_TXN_LIST:
+ return isSetValidTxnList();
+ case INVALIDATION_TIME:
+ return isSetInvalidationTime();
+ case SOURCE_TABLES_UPDATE_DELETE_MODIFIED:
+ return isSetSourceTablesUpdateDeleteModified();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof Materialization)
+ return this.equals((Materialization)that);
+ return false;
+ }
+
+ public boolean equals(Materialization that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_tablesUsed = true && this.isSetTablesUsed();
+ boolean that_present_tablesUsed = true && that.isSetTablesUsed();
+ if (this_present_tablesUsed || that_present_tablesUsed) {
+ if (!(this_present_tablesUsed && that_present_tablesUsed))
+ return false;
+ if (!this.tablesUsed.equals(that.tablesUsed))
+ return false;
+ }
+
+ boolean this_present_validTxnList = true && this.isSetValidTxnList();
+ boolean that_present_validTxnList = true && that.isSetValidTxnList();
+ if (this_present_validTxnList || that_present_validTxnList) {
+ if (!(this_present_validTxnList && that_present_validTxnList))
+ return false;
+ if (!this.validTxnList.equals(that.validTxnList))
+ return false;
+ }
+
+ boolean this_present_invalidationTime = true && this.isSetInvalidationTime();
+ boolean that_present_invalidationTime = true && that.isSetInvalidationTime();
+ if (this_present_invalidationTime || that_present_invalidationTime) {
+ if (!(this_present_invalidationTime && that_present_invalidationTime))
+ return false;
+ if (this.invalidationTime != that.invalidationTime)
+ return false;
+ }
+
+ boolean this_present_sourceTablesUpdateDeleteModified = true && this.isSetSourceTablesUpdateDeleteModified();
+ boolean that_present_sourceTablesUpdateDeleteModified = true && that.isSetSourceTablesUpdateDeleteModified();
+ if (this_present_sourceTablesUpdateDeleteModified || that_present_sourceTablesUpdateDeleteModified) {
+ if (!(this_present_sourceTablesUpdateDeleteModified && that_present_sourceTablesUpdateDeleteModified))
+ return false;
+ if (this.sourceTablesUpdateDeleteModified != that.sourceTablesUpdateDeleteModified)
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_tablesUsed = true && (isSetTablesUsed());
+ list.add(present_tablesUsed);
+ if (present_tablesUsed)
+ list.add(tablesUsed);
+
+ boolean present_validTxnList = true && (isSetValidTxnList());
+ list.add(present_validTxnList);
+ if (present_validTxnList)
+ list.add(validTxnList);
+
+ boolean present_invalidationTime = true && (isSetInvalidationTime());
+ list.add(present_invalidationTime);
+ if (present_invalidationTime)
+ list.add(invalidationTime);
+
+ boolean present_sourceTablesUpdateDeleteModified = true && (isSetSourceTablesUpdateDeleteModified());
+ list.add(present_sourceTablesUpdateDeleteModified);
+ if (present_sourceTablesUpdateDeleteModified)
+ list.add(sourceTablesUpdateDeleteModified);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(Materialization other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetTablesUsed()).compareTo(other.isSetTablesUsed());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetTablesUsed()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tablesUsed, other.tablesUsed);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetValidTxnList()).compareTo(other.isSetValidTxnList());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetValidTxnList()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.validTxnList, other.validTxnList);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetInvalidationTime()).compareTo(other.isSetInvalidationTime());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetInvalidationTime()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.invalidationTime, other.invalidationTime);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetSourceTablesUpdateDeleteModified()).compareTo(other.isSetSourceTablesUpdateDeleteModified());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetSourceTablesUpdateDeleteModified()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceTablesUpdateDeleteModified, other.sourceTablesUpdateDeleteModified);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("Materialization(");
+ boolean first = true;
+
+ sb.append("tablesUsed:");
+ if (this.tablesUsed == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.tablesUsed);
+ }
+ first = false;
+ if (isSetValidTxnList()) {
+ if (!first) sb.append(", ");
+ sb.append("validTxnList:");
+ if (this.validTxnList == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.validTxnList);
+ }
+ first = false;
+ }
+ if (isSetInvalidationTime()) {
+ if (!first) sb.append(", ");
+ sb.append("invalidationTime:");
+ sb.append(this.invalidationTime);
+ first = false;
+ }
+ if (isSetSourceTablesUpdateDeleteModified()) {
+ if (!first) sb.append(", ");
+ sb.append("sourceTablesUpdateDeleteModified:");
+ sb.append(this.sourceTablesUpdateDeleteModified);
+ first = false;
+ }
+ sb.append(")");
+ return sb.toString();
+ }
+
+ public void validate() throws org.apache.thrift.TException {
+ // check for required fields
+ if (!isSetTablesUsed()) {
+ throw new org.apache.thrift.protocol.TProtocolException("Required field 'tablesUsed' is unset! 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, 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 MaterializationStandardSchemeFactory implements SchemeFactory {
+ public MaterializationStandardScheme getScheme() {
+ return new MaterializationStandardScheme();
+ }
+ }
+
+ private static class MaterializationStandardScheme extends StandardScheme<Materialization> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, Materialization 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: // TABLES_USED
+ if (schemeField.type == org.apache.thrift.protocol.TType.SET) {
+ {
+ org.apache.thrift.protocol.TSet _set864 = iprot.readSetBegin();
+ struct.tablesUsed = new HashSet<String>(2*_set864.size);
+ String _elem865;
+ for (int _i866 = 0; _i866 < _set864.size; ++_i866)
+ {
+ _elem865 = iprot.readString();
+ struct.tablesUsed.add(_elem865);
+ }
+ iprot.readSetEnd();
+ }
+ struct.setTablesUsedIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 2: // VALID_TXN_LIST
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.validTxnList = iprot.readString();
+ struct.setValidTxnListIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 3: // INVALIDATION_TIME
+ if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+ struct.invalidationTime = iprot.readI64();
+ struct.setInvalidationTimeIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 4: // SOURCE_TABLES_UPDATE_DELETE_MODIFIED
+ if (schemeField.type == org.apache.thrift.protocol.TType.BOOL) {
+ struct.sourceTablesUpdateDeleteModified = iprot.readBool();
+ struct.setSourceTablesUpdateDeleteModifiedIsSet(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();
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, Materialization struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.tablesUsed != null) {
+ oprot.writeFieldBegin(TABLES_USED_FIELD_DESC);
+ {
+ oprot.writeSetBegin(new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, struct.tablesUsed.size()));
+ for (String _iter867 : struct.tablesUsed)
+ {
+ oprot.writeString(_iter867);
+ }
+ oprot.writeSetEnd();
+ }
+ oprot.writeFieldEnd();
+ }
+ if (struct.validTxnList != null) {
+ if (struct.isSetValidTxnList()) {
+ oprot.writeFieldBegin(VALID_TXN_LIST_FIELD_DESC);
+ oprot.writeString(struct.validTxnList);
+ oprot.writeFieldEnd();
+ }
+ }
+ if (struct.isSetInvalidationTime()) {
+ oprot.writeFieldBegin(INVALIDATION_TIME_FIELD_DESC);
+ oprot.writeI64(struct.invalidationTime);
+ oprot.writeFieldEnd();
+ }
+ if (struct.isSetSourceTablesUpdateDeleteModified()) {
+ oprot.writeFieldBegin(SOURCE_TABLES_UPDATE_DELETE_MODIFIED_FIELD_DESC);
+ oprot.writeBool(struct.sourceTablesUpdateDeleteModified);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class MaterializationTupleSchemeFactory implements SchemeFactory {
+ public MaterializationTupleScheme getScheme() {
+ return new MaterializationTupleScheme();
+ }
+ }
+
+ private static class MaterializationTupleScheme extends TupleScheme<Materialization> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, Materialization struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ {
+ oprot.writeI32(struct.tablesUsed.size());
+ for (String _iter868 : struct.tablesUsed)
+ {
+ oprot.writeString(_iter868);
+ }
+ }
+ BitSet optionals = new BitSet();
+ if (struct.isSetValidTxnList()) {
+ optionals.set(0);
+ }
+ if (struct.isSetInvalidationTime()) {
+ optionals.set(1);
+ }
+ if (struct.isSetSourceTablesUpdateDeleteModified()) {
+ optionals.set(2);
+ }
+ oprot.writeBitSet(optionals, 3);
+ if (struct.isSetValidTxnList()) {
+ oprot.writeString(struct.validTxnList);
+ }
+ if (struct.isSetInvalidationTime()) {
+ oprot.writeI64(struct.invalidationTime);
+ }
+ if (struct.isSetSourceTablesUpdateDeleteModified()) {
+ oprot.writeBool(struct.sourceTablesUpdateDeleteModified);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, Materialization struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ {
+ org.apache.thrift.protocol.TSet _set869 = new org.apache.thrift.protocol.TSet(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
+ struct.tablesUsed = new HashSet<String>(2*_set869.size);
+ String _elem870;
+ for (int _i871 = 0; _i871 < _set869.size; ++_i871)
+ {
+ _elem870 = iprot.readString();
+ struct.tablesUsed.add(_elem870);
+ }
+ }
+ struct.setTablesUsedIsSet(true);
+ BitSet incoming = iprot.readBitSet(3);
+ if (incoming.get(0)) {
+ struct.validTxnList = iprot.readString();
+ struct.setValidTxnListIsSet(true);
+ }
+ if (incoming.get(1)) {
+ struct.invalidationTime = iprot.readI64();
+ struct.setInvalidationTimeIsSet(true);
+ }
+ if (incoming.get(2)) {
+ struct.sourceTablesUpdateDeleteModified = iprot.readBool();
+ struct.setSourceTablesUpdateDeleteModifiedIsSet(true);
+ }
+ }
+ }
+
+}
+
http://git-wip-us.apache.org/repos/asf/hive/blob/20eb7b51/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetaException.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetaException.java b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetaException.java
new file mode 100644
index 0000000..b699a0d
--- /dev/null
+++ b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetaException.java
@@ -0,0 +1,395 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.3)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ * @generated
+ */
+package org.apache.hadoop.hive.metastore.api;
+
+import org.apache.thrift.scheme.IScheme;
+import org.apache.thrift.scheme.SchemeFactory;
+import org.apache.thrift.scheme.StandardScheme;
+
+import org.apache.thrift.scheme.TupleScheme;
+import org.apache.thrift.protocol.TTupleProtocol;
+import org.apache.thrift.protocol.TProtocolException;
+import org.apache.thrift.EncodingUtils;
+import org.apache.thrift.TException;
+import org.apache.thrift.async.AsyncMethodCallback;
+import org.apache.thrift.server.AbstractNonblockingServer.*;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.EnumMap;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.EnumSet;
+import java.util.Collections;
+import java.util.BitSet;
+import java.nio.ByteBuffer;
+import java.util.Arrays;
+import javax.annotation.Generated;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@org.apache.hadoop.classification.InterfaceAudience.Public @org.apache.hadoop.classification.InterfaceStability.Stable public class MetaException extends TException implements org.apache.thrift.TBase<MetaException, MetaException._Fields>, java.io.Serializable, Cloneable, Comparable<MetaException> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("MetaException");
+
+ private static final org.apache.thrift.protocol.TField MESSAGE_FIELD_DESC = new org.apache.thrift.protocol.TField("message", org.apache.thrift.protocol.TType.STRING, (short)1);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new MetaExceptionStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new MetaExceptionTupleSchemeFactory());
+ }
+
+ private String message; // required
+
+ /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
+ public enum _Fields implements org.apache.thrift.TFieldIdEnum {
+ MESSAGE((short)1, "message");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // MESSAGE
+ return MESSAGE;
+ 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 IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.MESSAGE, new org.apache.thrift.meta_data.FieldMetaData("message", org.apache.thrift.TFieldRequirementType.DEFAULT,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(MetaException.class, metaDataMap);
+ }
+
+ public MetaException() {
+ }
+
+ public MetaException(
+ String message)
+ {
+ this();
+ this.message = message;
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public MetaException(MetaException other) {
+ if (other.isSetMessage()) {
+ this.message = other.message;
+ }
+ }
+
+ public MetaException deepCopy() {
+ return new MetaException(this);
+ }
+
+ @Override
+ public void clear() {
+ this.message = null;
+ }
+
+ public String getMessage() {
+ return this.message;
+ }
+
+ public void setMessage(String message) {
+ this.message = message;
+ }
+
+ public void unsetMessage() {
+ this.message = null;
+ }
+
+ /** Returns true if field message is set (has been assigned a value) and false otherwise */
+ public boolean isSetMessage() {
+ return this.message != null;
+ }
+
+ public void setMessageIsSet(boolean value) {
+ if (!value) {
+ this.message = null;
+ }
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case MESSAGE:
+ if (value == null) {
+ unsetMessage();
+ } else {
+ setMessage((String)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case MESSAGE:
+ return getMessage();
+
+ }
+ throw new 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 IllegalArgumentException();
+ }
+
+ switch (field) {
+ case MESSAGE:
+ return isSetMessage();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof MetaException)
+ return this.equals((MetaException)that);
+ return false;
+ }
+
+ public boolean equals(MetaException that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_message = true && this.isSetMessage();
+ boolean that_present_message = true && that.isSetMessage();
+ if (this_present_message || that_present_message) {
+ if (!(this_present_message && that_present_message))
+ return false;
+ if (!this.message.equals(that.message))
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_message = true && (isSetMessage());
+ list.add(present_message);
+ if (present_message)
+ list.add(message);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(MetaException other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetMessage()).compareTo(other.isSetMessage());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetMessage()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.message, other.message);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("MetaException(");
+ boolean first = true;
+
+ sb.append("message:");
+ if (this.message == null) {
+ sb.append("null");
+ } else {
+ sb.append(this.message);
+ }
+ 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, 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 MetaExceptionStandardSchemeFactory implements SchemeFactory {
+ public MetaExceptionStandardScheme getScheme() {
+ return new MetaExceptionStandardScheme();
+ }
+ }
+
+ private static class MetaExceptionStandardScheme extends StandardScheme<MetaException> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, MetaException 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: // MESSAGE
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.message = iprot.readString();
+ struct.setMessageIsSet(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();
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, MetaException struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.message != null) {
+ oprot.writeFieldBegin(MESSAGE_FIELD_DESC);
+ oprot.writeString(struct.message);
+ oprot.writeFieldEnd();
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class MetaExceptionTupleSchemeFactory implements SchemeFactory {
+ public MetaExceptionTupleScheme getScheme() {
+ return new MetaExceptionTupleScheme();
+ }
+ }
+
+ private static class MetaExceptionTupleScheme extends TupleScheme<MetaException> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, MetaException struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetMessage()) {
+ optionals.set(0);
+ }
+ oprot.writeBitSet(optionals, 1);
+ if (struct.isSetMessage()) {
+ oprot.writeString(struct.message);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, MetaException struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(1);
+ if (incoming.get(0)) {
+ struct.message = iprot.readString();
+ struct.setMessageIsSet(true);
+ }
+ }
+ }
+
+}
+
http://git-wip-us.apache.org/repos/asf/hive/blob/20eb7b51/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetadataPpdResult.java
----------------------------------------------------------------------
diff --git a/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetadataPpdResult.java b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetadataPpdResult.java
new file mode 100644
index 0000000..0679ff4
--- /dev/null
+++ b/standalone-metastore/metastore-common/src/gen/thrift/gen-javabean/org/apache/hadoop/hive/metastore/api/MetadataPpdResult.java
@@ -0,0 +1,517 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.3)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ * @generated
+ */
+package org.apache.hadoop.hive.metastore.api;
+
+import org.apache.thrift.scheme.IScheme;
+import org.apache.thrift.scheme.SchemeFactory;
+import org.apache.thrift.scheme.StandardScheme;
+
+import org.apache.thrift.scheme.TupleScheme;
+import org.apache.thrift.protocol.TTupleProtocol;
+import org.apache.thrift.protocol.TProtocolException;
+import org.apache.thrift.EncodingUtils;
+import org.apache.thrift.TException;
+import org.apache.thrift.async.AsyncMethodCallback;
+import org.apache.thrift.server.AbstractNonblockingServer.*;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.EnumMap;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.EnumSet;
+import java.util.Collections;
+import java.util.BitSet;
+import java.nio.ByteBuffer;
+import java.util.Arrays;
+import javax.annotation.Generated;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
+@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
+@org.apache.hadoop.classification.InterfaceAudience.Public @org.apache.hadoop.classification.InterfaceStability.Stable public class MetadataPpdResult implements org.apache.thrift.TBase<MetadataPpdResult, MetadataPpdResult._Fields>, java.io.Serializable, Cloneable, Comparable<MetadataPpdResult> {
+ private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("MetadataPpdResult");
+
+ private static final org.apache.thrift.protocol.TField METADATA_FIELD_DESC = new org.apache.thrift.protocol.TField("metadata", org.apache.thrift.protocol.TType.STRING, (short)1);
+ private static final org.apache.thrift.protocol.TField INCLUDE_BITSET_FIELD_DESC = new org.apache.thrift.protocol.TField("includeBitset", org.apache.thrift.protocol.TType.STRING, (short)2);
+
+ private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+ static {
+ schemes.put(StandardScheme.class, new MetadataPpdResultStandardSchemeFactory());
+ schemes.put(TupleScheme.class, new MetadataPpdResultTupleSchemeFactory());
+ }
+
+ private ByteBuffer metadata; // optional
+ private ByteBuffer includeBitset; // 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 {
+ METADATA((short)1, "metadata"),
+ INCLUDE_BITSET((short)2, "includeBitset");
+
+ private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+
+ static {
+ for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ byName.put(field.getFieldName(), field);
+ }
+ }
+
+ /**
+ * Find the _Fields constant that matches fieldId, or null if its not found.
+ */
+ public static _Fields findByThriftId(int fieldId) {
+ switch(fieldId) {
+ case 1: // METADATA
+ return METADATA;
+ case 2: // INCLUDE_BITSET
+ return INCLUDE_BITSET;
+ 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 IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ return fields;
+ }
+
+ /**
+ * Find the _Fields constant that matches name, or null if its not found.
+ */
+ public static _Fields findByName(String name) {
+ return byName.get(name);
+ }
+
+ private final short _thriftId;
+ private final String _fieldName;
+
+ _Fields(short thriftId, String fieldName) {
+ _thriftId = thriftId;
+ _fieldName = fieldName;
+ }
+
+ public short getThriftFieldId() {
+ return _thriftId;
+ }
+
+ public String getFieldName() {
+ return _fieldName;
+ }
+ }
+
+ // isset id assignments
+ private static final _Fields optionals[] = {_Fields.METADATA,_Fields.INCLUDE_BITSET};
+ public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ static {
+ Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ tmpMap.put(_Fields.METADATA, new org.apache.thrift.meta_data.FieldMetaData("metadata", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , true)));
+ tmpMap.put(_Fields.INCLUDE_BITSET, new org.apache.thrift.meta_data.FieldMetaData("includeBitset", org.apache.thrift.TFieldRequirementType.OPTIONAL,
+ new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , true)));
+ metaDataMap = Collections.unmodifiableMap(tmpMap);
+ org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(MetadataPpdResult.class, metaDataMap);
+ }
+
+ public MetadataPpdResult() {
+ }
+
+ /**
+ * Performs a deep copy on <i>other</i>.
+ */
+ public MetadataPpdResult(MetadataPpdResult other) {
+ if (other.isSetMetadata()) {
+ this.metadata = org.apache.thrift.TBaseHelper.copyBinary(other.metadata);
+ }
+ if (other.isSetIncludeBitset()) {
+ this.includeBitset = org.apache.thrift.TBaseHelper.copyBinary(other.includeBitset);
+ }
+ }
+
+ public MetadataPpdResult deepCopy() {
+ return new MetadataPpdResult(this);
+ }
+
+ @Override
+ public void clear() {
+ this.metadata = null;
+ this.includeBitset = null;
+ }
+
+ public byte[] getMetadata() {
+ setMetadata(org.apache.thrift.TBaseHelper.rightSize(metadata));
+ return metadata == null ? null : metadata.array();
+ }
+
+ public ByteBuffer bufferForMetadata() {
+ return org.apache.thrift.TBaseHelper.copyBinary(metadata);
+ }
+
+ public void setMetadata(byte[] metadata) {
+ this.metadata = metadata == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(metadata, metadata.length));
+ }
+
+ public void setMetadata(ByteBuffer metadata) {
+ this.metadata = org.apache.thrift.TBaseHelper.copyBinary(metadata);
+ }
+
+ public void unsetMetadata() {
+ this.metadata = null;
+ }
+
+ /** Returns true if field metadata is set (has been assigned a value) and false otherwise */
+ public boolean isSetMetadata() {
+ return this.metadata != null;
+ }
+
+ public void setMetadataIsSet(boolean value) {
+ if (!value) {
+ this.metadata = null;
+ }
+ }
+
+ public byte[] getIncludeBitset() {
+ setIncludeBitset(org.apache.thrift.TBaseHelper.rightSize(includeBitset));
+ return includeBitset == null ? null : includeBitset.array();
+ }
+
+ public ByteBuffer bufferForIncludeBitset() {
+ return org.apache.thrift.TBaseHelper.copyBinary(includeBitset);
+ }
+
+ public void setIncludeBitset(byte[] includeBitset) {
+ this.includeBitset = includeBitset == null ? (ByteBuffer)null : ByteBuffer.wrap(Arrays.copyOf(includeBitset, includeBitset.length));
+ }
+
+ public void setIncludeBitset(ByteBuffer includeBitset) {
+ this.includeBitset = org.apache.thrift.TBaseHelper.copyBinary(includeBitset);
+ }
+
+ public void unsetIncludeBitset() {
+ this.includeBitset = null;
+ }
+
+ /** Returns true if field includeBitset is set (has been assigned a value) and false otherwise */
+ public boolean isSetIncludeBitset() {
+ return this.includeBitset != null;
+ }
+
+ public void setIncludeBitsetIsSet(boolean value) {
+ if (!value) {
+ this.includeBitset = null;
+ }
+ }
+
+ public void setFieldValue(_Fields field, Object value) {
+ switch (field) {
+ case METADATA:
+ if (value == null) {
+ unsetMetadata();
+ } else {
+ setMetadata((ByteBuffer)value);
+ }
+ break;
+
+ case INCLUDE_BITSET:
+ if (value == null) {
+ unsetIncludeBitset();
+ } else {
+ setIncludeBitset((ByteBuffer)value);
+ }
+ break;
+
+ }
+ }
+
+ public Object getFieldValue(_Fields field) {
+ switch (field) {
+ case METADATA:
+ return getMetadata();
+
+ case INCLUDE_BITSET:
+ return getIncludeBitset();
+
+ }
+ throw new 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 IllegalArgumentException();
+ }
+
+ switch (field) {
+ case METADATA:
+ return isSetMetadata();
+ case INCLUDE_BITSET:
+ return isSetIncludeBitset();
+ }
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public boolean equals(Object that) {
+ if (that == null)
+ return false;
+ if (that instanceof MetadataPpdResult)
+ return this.equals((MetadataPpdResult)that);
+ return false;
+ }
+
+ public boolean equals(MetadataPpdResult that) {
+ if (that == null)
+ return false;
+
+ boolean this_present_metadata = true && this.isSetMetadata();
+ boolean that_present_metadata = true && that.isSetMetadata();
+ if (this_present_metadata || that_present_metadata) {
+ if (!(this_present_metadata && that_present_metadata))
+ return false;
+ if (!this.metadata.equals(that.metadata))
+ return false;
+ }
+
+ boolean this_present_includeBitset = true && this.isSetIncludeBitset();
+ boolean that_present_includeBitset = true && that.isSetIncludeBitset();
+ if (this_present_includeBitset || that_present_includeBitset) {
+ if (!(this_present_includeBitset && that_present_includeBitset))
+ return false;
+ if (!this.includeBitset.equals(that.includeBitset))
+ return false;
+ }
+
+ return true;
+ }
+
+ @Override
+ public int hashCode() {
+ List<Object> list = new ArrayList<Object>();
+
+ boolean present_metadata = true && (isSetMetadata());
+ list.add(present_metadata);
+ if (present_metadata)
+ list.add(metadata);
+
+ boolean present_includeBitset = true && (isSetIncludeBitset());
+ list.add(present_includeBitset);
+ if (present_includeBitset)
+ list.add(includeBitset);
+
+ return list.hashCode();
+ }
+
+ @Override
+ public int compareTo(MetadataPpdResult other) {
+ if (!getClass().equals(other.getClass())) {
+ return getClass().getName().compareTo(other.getClass().getName());
+ }
+
+ int lastComparison = 0;
+
+ lastComparison = Boolean.valueOf(isSetMetadata()).compareTo(other.isSetMetadata());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetMetadata()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.metadata, other.metadata);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ lastComparison = Boolean.valueOf(isSetIncludeBitset()).compareTo(other.isSetIncludeBitset());
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ if (isSetIncludeBitset()) {
+ lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.includeBitset, other.includeBitset);
+ if (lastComparison != 0) {
+ return lastComparison;
+ }
+ }
+ return 0;
+ }
+
+ public _Fields fieldForId(int fieldId) {
+ return _Fields.findByThriftId(fieldId);
+ }
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
+ schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
+ schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder("MetadataPpdResult(");
+ boolean first = true;
+
+ if (isSetMetadata()) {
+ sb.append("metadata:");
+ if (this.metadata == null) {
+ sb.append("null");
+ } else {
+ org.apache.thrift.TBaseHelper.toString(this.metadata, sb);
+ }
+ first = false;
+ }
+ if (isSetIncludeBitset()) {
+ if (!first) sb.append(", ");
+ sb.append("includeBitset:");
+ if (this.includeBitset == null) {
+ sb.append("null");
+ } else {
+ org.apache.thrift.TBaseHelper.toString(this.includeBitset, sb);
+ }
+ 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, 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 MetadataPpdResultStandardSchemeFactory implements SchemeFactory {
+ public MetadataPpdResultStandardScheme getScheme() {
+ return new MetadataPpdResultStandardScheme();
+ }
+ }
+
+ private static class MetadataPpdResultStandardScheme extends StandardScheme<MetadataPpdResult> {
+
+ public void read(org.apache.thrift.protocol.TProtocol iprot, MetadataPpdResult 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: // METADATA
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.metadata = iprot.readBinary();
+ struct.setMetadataIsSet(true);
+ } else {
+ org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+ }
+ break;
+ case 2: // INCLUDE_BITSET
+ if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+ struct.includeBitset = iprot.readBinary();
+ struct.setIncludeBitsetIsSet(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();
+ struct.validate();
+ }
+
+ public void write(org.apache.thrift.protocol.TProtocol oprot, MetadataPpdResult struct) throws org.apache.thrift.TException {
+ struct.validate();
+
+ oprot.writeStructBegin(STRUCT_DESC);
+ if (struct.metadata != null) {
+ if (struct.isSetMetadata()) {
+ oprot.writeFieldBegin(METADATA_FIELD_DESC);
+ oprot.writeBinary(struct.metadata);
+ oprot.writeFieldEnd();
+ }
+ }
+ if (struct.includeBitset != null) {
+ if (struct.isSetIncludeBitset()) {
+ oprot.writeFieldBegin(INCLUDE_BITSET_FIELD_DESC);
+ oprot.writeBinary(struct.includeBitset);
+ oprot.writeFieldEnd();
+ }
+ }
+ oprot.writeFieldStop();
+ oprot.writeStructEnd();
+ }
+
+ }
+
+ private static class MetadataPpdResultTupleSchemeFactory implements SchemeFactory {
+ public MetadataPpdResultTupleScheme getScheme() {
+ return new MetadataPpdResultTupleScheme();
+ }
+ }
+
+ private static class MetadataPpdResultTupleScheme extends TupleScheme<MetadataPpdResult> {
+
+ @Override
+ public void write(org.apache.thrift.protocol.TProtocol prot, MetadataPpdResult struct) throws org.apache.thrift.TException {
+ TTupleProtocol oprot = (TTupleProtocol) prot;
+ BitSet optionals = new BitSet();
+ if (struct.isSetMetadata()) {
+ optionals.set(0);
+ }
+ if (struct.isSetIncludeBitset()) {
+ optionals.set(1);
+ }
+ oprot.writeBitSet(optionals, 2);
+ if (struct.isSetMetadata()) {
+ oprot.writeBinary(struct.metadata);
+ }
+ if (struct.isSetIncludeBitset()) {
+ oprot.writeBinary(struct.includeBitset);
+ }
+ }
+
+ @Override
+ public void read(org.apache.thrift.protocol.TProtocol prot, MetadataPpdResult struct) throws org.apache.thrift.TException {
+ TTupleProtocol iprot = (TTupleProtocol) prot;
+ BitSet incoming = iprot.readBitSet(2);
+ if (incoming.get(0)) {
+ struct.metadata = iprot.readBinary();
+ struct.setMetadataIsSet(true);
+ }
+ if (incoming.get(1)) {
+ struct.includeBitset = iprot.readBinary();
+ struct.setIncludeBitsetIsSet(true);
+ }
+ }
+ }
+
+}
+