incubator-blur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amccu...@apache.org
Subject [7/29] Added the distribution project to allow for automatically creating build artifacts during a maven build.
Date Fri, 04 Jan 2013 22:42:52 GMT
http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/70b69ecb/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ScoreDoc.java
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ScoreDoc.java b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ScoreDoc.java
new file mode 100644
index 0000000..a0592bd
--- /dev/null
+++ b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ScoreDoc.java
@@ -0,0 +1,651 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.0)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *  @generated
+ */
+package org.apache.blur.thrift.generated;
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+
+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 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 org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class ScoreDoc implements org.apache.thrift.TBase<ScoreDoc, ScoreDoc._Fields>, java.io.Serializable, Cloneable {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ScoreDoc");
+
+  private static final org.apache.thrift.protocol.TField SCORE_FIELD_DESC = new org.apache.thrift.protocol.TField("score", org.apache.thrift.protocol.TType.DOUBLE, (short)1);
+  private static final org.apache.thrift.protocol.TField DOC_LOCATION_FIELD_DESC = new org.apache.thrift.protocol.TField("docLocation", org.apache.thrift.protocol.TType.I64, (short)2);
+  private static final org.apache.thrift.protocol.TField FIELDS_FIELD_DESC = new org.apache.thrift.protocol.TField("fields", org.apache.thrift.protocol.TType.LIST, (short)4);
+
+  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+  static {
+    schemes.put(StandardScheme.class, new ScoreDocStandardSchemeFactory());
+    schemes.put(TupleScheme.class, new ScoreDocTupleSchemeFactory());
+  }
+
+  public double score; // required
+  public long docLocation; // required
+  public List<ByteBuffer> fields; // 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 {
+    SCORE((short)1, "score"),
+    DOC_LOCATION((short)2, "docLocation"),
+    FIELDS((short)4, "fields");
+
+    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: // SCORE
+          return SCORE;
+        case 2: // DOC_LOCATION
+          return DOC_LOCATION;
+        case 4: // FIELDS
+          return FIELDS;
+        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 __SCORE_ISSET_ID = 0;
+  private static final int __DOCLOCATION_ISSET_ID = 1;
+  private byte __isset_bitfield = 0;
+  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.SCORE, new org.apache.thrift.meta_data.FieldMetaData("score", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
+    tmpMap.put(_Fields.DOC_LOCATION, new org.apache.thrift.meta_data.FieldMetaData("docLocation", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
+    tmpMap.put(_Fields.FIELDS, new org.apache.thrift.meta_data.FieldMetaData("fields", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        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            , true))));
+    metaDataMap = Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ScoreDoc.class, metaDataMap);
+  }
+
+  public ScoreDoc() {
+  }
+
+  public ScoreDoc(
+    double score,
+    long docLocation,
+    List<ByteBuffer> fields)
+  {
+    this();
+    this.score = score;
+    setScoreIsSet(true);
+    this.docLocation = docLocation;
+    setDocLocationIsSet(true);
+    this.fields = fields;
+  }
+
+  /**
+   * Performs a deep copy on <i>other</i>.
+   */
+  public ScoreDoc(ScoreDoc other) {
+    __isset_bitfield = other.__isset_bitfield;
+    this.score = other.score;
+    this.docLocation = other.docLocation;
+    if (other.isSetFields()) {
+      List<ByteBuffer> __this__fields = new ArrayList<ByteBuffer>();
+      for (ByteBuffer other_element : other.fields) {
+        ByteBuffer temp_binary_element = org.apache.thrift.TBaseHelper.copyBinary(other_element);
+;
+        __this__fields.add(temp_binary_element);
+      }
+      this.fields = __this__fields;
+    }
+  }
+
+  public ScoreDoc deepCopy() {
+    return new ScoreDoc(this);
+  }
+
+  @Override
+  public void clear() {
+    setScoreIsSet(false);
+    this.score = 0.0;
+    setDocLocationIsSet(false);
+    this.docLocation = 0;
+    this.fields = null;
+  }
+
+  public double getScore() {
+    return this.score;
+  }
+
+  public ScoreDoc setScore(double score) {
+    this.score = score;
+    setScoreIsSet(true);
+    return this;
+  }
+
+  public void unsetScore() {
+    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __SCORE_ISSET_ID);
+  }
+
+  /** Returns true if field score is set (has been assigned a value) and false otherwise */
+  public boolean isSetScore() {
+    return EncodingUtils.testBit(__isset_bitfield, __SCORE_ISSET_ID);
+  }
+
+  public void setScoreIsSet(boolean value) {
+    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __SCORE_ISSET_ID, value);
+  }
+
+  public long getDocLocation() {
+    return this.docLocation;
+  }
+
+  public ScoreDoc setDocLocation(long docLocation) {
+    this.docLocation = docLocation;
+    setDocLocationIsSet(true);
+    return this;
+  }
+
+  public void unsetDocLocation() {
+    __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __DOCLOCATION_ISSET_ID);
+  }
+
+  /** Returns true if field docLocation is set (has been assigned a value) and false otherwise */
+  public boolean isSetDocLocation() {
+    return EncodingUtils.testBit(__isset_bitfield, __DOCLOCATION_ISSET_ID);
+  }
+
+  public void setDocLocationIsSet(boolean value) {
+    __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __DOCLOCATION_ISSET_ID, value);
+  }
+
+  public int getFieldsSize() {
+    return (this.fields == null) ? 0 : this.fields.size();
+  }
+
+  public java.util.Iterator<ByteBuffer> getFieldsIterator() {
+    return (this.fields == null) ? null : this.fields.iterator();
+  }
+
+  public void addToFields(ByteBuffer elem) {
+    if (this.fields == null) {
+      this.fields = new ArrayList<ByteBuffer>();
+    }
+    this.fields.add(elem);
+  }
+
+  public List<ByteBuffer> getFields() {
+    return this.fields;
+  }
+
+  public ScoreDoc setFields(List<ByteBuffer> fields) {
+    this.fields = fields;
+    return this;
+  }
+
+  public void unsetFields() {
+    this.fields = null;
+  }
+
+  /** Returns true if field fields is set (has been assigned a value) and false otherwise */
+  public boolean isSetFields() {
+    return this.fields != null;
+  }
+
+  public void setFieldsIsSet(boolean value) {
+    if (!value) {
+      this.fields = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, Object value) {
+    switch (field) {
+    case SCORE:
+      if (value == null) {
+        unsetScore();
+      } else {
+        setScore((Double)value);
+      }
+      break;
+
+    case DOC_LOCATION:
+      if (value == null) {
+        unsetDocLocation();
+      } else {
+        setDocLocation((Long)value);
+      }
+      break;
+
+    case FIELDS:
+      if (value == null) {
+        unsetFields();
+      } else {
+        setFields((List<ByteBuffer>)value);
+      }
+      break;
+
+    }
+  }
+
+  public Object getFieldValue(_Fields field) {
+    switch (field) {
+    case SCORE:
+      return Double.valueOf(getScore());
+
+    case DOC_LOCATION:
+      return Long.valueOf(getDocLocation());
+
+    case FIELDS:
+      return getFields();
+
+    }
+    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 SCORE:
+      return isSetScore();
+    case DOC_LOCATION:
+      return isSetDocLocation();
+    case FIELDS:
+      return isSetFields();
+    }
+    throw new IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(Object that) {
+    if (that == null)
+      return false;
+    if (that instanceof ScoreDoc)
+      return this.equals((ScoreDoc)that);
+    return false;
+  }
+
+  public boolean equals(ScoreDoc that) {
+    if (that == null)
+      return false;
+
+    boolean this_present_score = true;
+    boolean that_present_score = true;
+    if (this_present_score || that_present_score) {
+      if (!(this_present_score && that_present_score))
+        return false;
+      if (this.score != that.score)
+        return false;
+    }
+
+    boolean this_present_docLocation = true;
+    boolean that_present_docLocation = true;
+    if (this_present_docLocation || that_present_docLocation) {
+      if (!(this_present_docLocation && that_present_docLocation))
+        return false;
+      if (this.docLocation != that.docLocation)
+        return false;
+    }
+
+    boolean this_present_fields = true && this.isSetFields();
+    boolean that_present_fields = true && that.isSetFields();
+    if (this_present_fields || that_present_fields) {
+      if (!(this_present_fields && that_present_fields))
+        return false;
+      if (!this.fields.equals(that.fields))
+        return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    return 0;
+  }
+
+  public int compareTo(ScoreDoc other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+    ScoreDoc typedOther = (ScoreDoc)other;
+
+    lastComparison = Boolean.valueOf(isSetScore()).compareTo(typedOther.isSetScore());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetScore()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.score, typedOther.score);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison = Boolean.valueOf(isSetDocLocation()).compareTo(typedOther.isSetDocLocation());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetDocLocation()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.docLocation, typedOther.docLocation);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison = Boolean.valueOf(isSetFields()).compareTo(typedOther.isSetFields());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetFields()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fields, typedOther.fields);
+      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("ScoreDoc(");
+    boolean first = true;
+
+    sb.append("score:");
+    sb.append(this.score);
+    first = false;
+    if (!first) sb.append(", ");
+    sb.append("docLocation:");
+    sb.append(this.docLocation);
+    first = false;
+    if (!first) sb.append(", ");
+    sb.append("fields:");
+    if (this.fields == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.fields);
+    }
+    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 {
+      // 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 ScoreDocStandardSchemeFactory implements SchemeFactory {
+    public ScoreDocStandardScheme getScheme() {
+      return new ScoreDocStandardScheme();
+    }
+  }
+
+  private static class ScoreDocStandardScheme extends StandardScheme<ScoreDoc> {
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot, ScoreDoc 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: // SCORE
+            if (schemeField.type == org.apache.thrift.protocol.TType.DOUBLE) {
+              struct.score = iprot.readDouble();
+              struct.setScoreIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          case 2: // DOC_LOCATION
+            if (schemeField.type == org.apache.thrift.protocol.TType.I64) {
+              struct.docLocation = iprot.readI64();
+              struct.setDocLocationIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          case 4: // FIELDS
+            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
+              {
+                org.apache.thrift.protocol.TList _list72 = iprot.readListBegin();
+                struct.fields = new ArrayList<ByteBuffer>(_list72.size);
+                for (int _i73 = 0; _i73 < _list72.size; ++_i73)
+                {
+                  ByteBuffer _elem74; // required
+                  _elem74 = iprot.readBinary();
+                  struct.fields.add(_elem74);
+                }
+                iprot.readListEnd();
+              }
+              struct.setFieldsIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked in the validate method
+      struct.validate();
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot, ScoreDoc struct) throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      oprot.writeFieldBegin(SCORE_FIELD_DESC);
+      oprot.writeDouble(struct.score);
+      oprot.writeFieldEnd();
+      oprot.writeFieldBegin(DOC_LOCATION_FIELD_DESC);
+      oprot.writeI64(struct.docLocation);
+      oprot.writeFieldEnd();
+      if (struct.fields != null) {
+        oprot.writeFieldBegin(FIELDS_FIELD_DESC);
+        {
+          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.fields.size()));
+          for (ByteBuffer _iter75 : struct.fields)
+          {
+            oprot.writeBinary(_iter75);
+          }
+          oprot.writeListEnd();
+        }
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+
+  }
+
+  private static class ScoreDocTupleSchemeFactory implements SchemeFactory {
+    public ScoreDocTupleScheme getScheme() {
+      return new ScoreDocTupleScheme();
+    }
+  }
+
+  private static class ScoreDocTupleScheme extends TupleScheme<ScoreDoc> {
+
+    @Override
+    public void write(org.apache.thrift.protocol.TProtocol prot, ScoreDoc struct) throws org.apache.thrift.TException {
+      TTupleProtocol oprot = (TTupleProtocol) prot;
+      BitSet optionals = new BitSet();
+      if (struct.isSetScore()) {
+        optionals.set(0);
+      }
+      if (struct.isSetDocLocation()) {
+        optionals.set(1);
+      }
+      if (struct.isSetFields()) {
+        optionals.set(2);
+      }
+      oprot.writeBitSet(optionals, 3);
+      if (struct.isSetScore()) {
+        oprot.writeDouble(struct.score);
+      }
+      if (struct.isSetDocLocation()) {
+        oprot.writeI64(struct.docLocation);
+      }
+      if (struct.isSetFields()) {
+        {
+          oprot.writeI32(struct.fields.size());
+          for (ByteBuffer _iter76 : struct.fields)
+          {
+            oprot.writeBinary(_iter76);
+          }
+        }
+      }
+    }
+
+    @Override
+    public void read(org.apache.thrift.protocol.TProtocol prot, ScoreDoc struct) throws org.apache.thrift.TException {
+      TTupleProtocol iprot = (TTupleProtocol) prot;
+      BitSet incoming = iprot.readBitSet(3);
+      if (incoming.get(0)) {
+        struct.score = iprot.readDouble();
+        struct.setScoreIsSet(true);
+      }
+      if (incoming.get(1)) {
+        struct.docLocation = iprot.readI64();
+        struct.setDocLocationIsSet(true);
+      }
+      if (incoming.get(2)) {
+        {
+          org.apache.thrift.protocol.TList _list77 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
+          struct.fields = new ArrayList<ByteBuffer>(_list77.size);
+          for (int _i78 = 0; _i78 < _list77.size; ++_i78)
+          {
+            ByteBuffer _elem79; // required
+            _elem79 = iprot.readBinary();
+            struct.fields.add(_elem79);
+          }
+        }
+        struct.setFieldsIsSet(true);
+      }
+    }
+  }
+
+}
+

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/70b69ecb/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Session.java
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Session.java b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Session.java
new file mode 100644
index 0000000..283736a
--- /dev/null
+++ b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Session.java
@@ -0,0 +1,505 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.0)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *  @generated
+ */
+package org.apache.blur.thrift.generated;
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+
+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 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 org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class Session implements org.apache.thrift.TBase<Session, Session._Fields>, java.io.Serializable, Cloneable {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Session");
+
+  private static final org.apache.thrift.protocol.TField SESSION_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sessionId", org.apache.thrift.protocol.TType.STRING, (short)1);
+  private static final org.apache.thrift.protocol.TField TABLE_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("tableName", org.apache.thrift.protocol.TType.STRING, (short)2);
+
+  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+  static {
+    schemes.put(StandardScheme.class, new SessionStandardSchemeFactory());
+    schemes.put(TupleScheme.class, new SessionTupleSchemeFactory());
+  }
+
+  public String sessionId; // required
+  public String tableName; // 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 {
+    SESSION_ID((short)1, "sessionId"),
+    TABLE_NAME((short)2, "tableName");
+
+    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: // SESSION_ID
+          return SESSION_ID;
+        case 2: // TABLE_NAME
+          return TABLE_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.SESSION_ID, new org.apache.thrift.meta_data.FieldMetaData("sessionId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+    tmpMap.put(_Fields.TABLE_NAME, new org.apache.thrift.meta_data.FieldMetaData("tableName", 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(Session.class, metaDataMap);
+  }
+
+  public Session() {
+  }
+
+  public Session(
+    String sessionId,
+    String tableName)
+  {
+    this();
+    this.sessionId = sessionId;
+    this.tableName = tableName;
+  }
+
+  /**
+   * Performs a deep copy on <i>other</i>.
+   */
+  public Session(Session other) {
+    if (other.isSetSessionId()) {
+      this.sessionId = other.sessionId;
+    }
+    if (other.isSetTableName()) {
+      this.tableName = other.tableName;
+    }
+  }
+
+  public Session deepCopy() {
+    return new Session(this);
+  }
+
+  @Override
+  public void clear() {
+    this.sessionId = null;
+    this.tableName = null;
+  }
+
+  public String getSessionId() {
+    return this.sessionId;
+  }
+
+  public Session setSessionId(String sessionId) {
+    this.sessionId = sessionId;
+    return this;
+  }
+
+  public void unsetSessionId() {
+    this.sessionId = null;
+  }
+
+  /** Returns true if field sessionId is set (has been assigned a value) and false otherwise */
+  public boolean isSetSessionId() {
+    return this.sessionId != null;
+  }
+
+  public void setSessionIdIsSet(boolean value) {
+    if (!value) {
+      this.sessionId = null;
+    }
+  }
+
+  public String getTableName() {
+    return this.tableName;
+  }
+
+  public Session setTableName(String tableName) {
+    this.tableName = tableName;
+    return this;
+  }
+
+  public void unsetTableName() {
+    this.tableName = null;
+  }
+
+  /** Returns true if field tableName is set (has been assigned a value) and false otherwise */
+  public boolean isSetTableName() {
+    return this.tableName != null;
+  }
+
+  public void setTableNameIsSet(boolean value) {
+    if (!value) {
+      this.tableName = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, Object value) {
+    switch (field) {
+    case SESSION_ID:
+      if (value == null) {
+        unsetSessionId();
+      } else {
+        setSessionId((String)value);
+      }
+      break;
+
+    case TABLE_NAME:
+      if (value == null) {
+        unsetTableName();
+      } else {
+        setTableName((String)value);
+      }
+      break;
+
+    }
+  }
+
+  public Object getFieldValue(_Fields field) {
+    switch (field) {
+    case SESSION_ID:
+      return getSessionId();
+
+    case TABLE_NAME:
+      return getTableName();
+
+    }
+    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 SESSION_ID:
+      return isSetSessionId();
+    case TABLE_NAME:
+      return isSetTableName();
+    }
+    throw new IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(Object that) {
+    if (that == null)
+      return false;
+    if (that instanceof Session)
+      return this.equals((Session)that);
+    return false;
+  }
+
+  public boolean equals(Session that) {
+    if (that == null)
+      return false;
+
+    boolean this_present_sessionId = true && this.isSetSessionId();
+    boolean that_present_sessionId = true && that.isSetSessionId();
+    if (this_present_sessionId || that_present_sessionId) {
+      if (!(this_present_sessionId && that_present_sessionId))
+        return false;
+      if (!this.sessionId.equals(that.sessionId))
+        return false;
+    }
+
+    boolean this_present_tableName = true && this.isSetTableName();
+    boolean that_present_tableName = true && that.isSetTableName();
+    if (this_present_tableName || that_present_tableName) {
+      if (!(this_present_tableName && that_present_tableName))
+        return false;
+      if (!this.tableName.equals(that.tableName))
+        return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    return 0;
+  }
+
+  public int compareTo(Session other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+    Session typedOther = (Session)other;
+
+    lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(typedOther.isSetSessionId());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetSessionId()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sessionId, typedOther.sessionId);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison = Boolean.valueOf(isSetTableName()).compareTo(typedOther.isSetTableName());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetTableName()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tableName, typedOther.tableName);
+      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("Session(");
+    boolean first = true;
+
+    sb.append("sessionId:");
+    if (this.sessionId == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.sessionId);
+    }
+    first = false;
+    if (!first) sb.append(", ");
+    sb.append("tableName:");
+    if (this.tableName == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.tableName);
+    }
+    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 SessionStandardSchemeFactory implements SchemeFactory {
+    public SessionStandardScheme getScheme() {
+      return new SessionStandardScheme();
+    }
+  }
+
+  private static class SessionStandardScheme extends StandardScheme<Session> {
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot, Session 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.STRING) {
+              struct.sessionId = iprot.readString();
+              struct.setSessionIdIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          case 2: // TABLE_NAME
+            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+              struct.tableName = iprot.readString();
+              struct.setTableNameIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked in the validate method
+      struct.validate();
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot, Session struct) throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      if (struct.sessionId != null) {
+        oprot.writeFieldBegin(SESSION_ID_FIELD_DESC);
+        oprot.writeString(struct.sessionId);
+        oprot.writeFieldEnd();
+      }
+      if (struct.tableName != null) {
+        oprot.writeFieldBegin(TABLE_NAME_FIELD_DESC);
+        oprot.writeString(struct.tableName);
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+
+  }
+
+  private static class SessionTupleSchemeFactory implements SchemeFactory {
+    public SessionTupleScheme getScheme() {
+      return new SessionTupleScheme();
+    }
+  }
+
+  private static class SessionTupleScheme extends TupleScheme<Session> {
+
+    @Override
+    public void write(org.apache.thrift.protocol.TProtocol prot, Session struct) throws org.apache.thrift.TException {
+      TTupleProtocol oprot = (TTupleProtocol) prot;
+      BitSet optionals = new BitSet();
+      if (struct.isSetSessionId()) {
+        optionals.set(0);
+      }
+      if (struct.isSetTableName()) {
+        optionals.set(1);
+      }
+      oprot.writeBitSet(optionals, 2);
+      if (struct.isSetSessionId()) {
+        oprot.writeString(struct.sessionId);
+      }
+      if (struct.isSetTableName()) {
+        oprot.writeString(struct.tableName);
+      }
+    }
+
+    @Override
+    public void read(org.apache.thrift.protocol.TProtocol prot, Session struct) throws org.apache.thrift.TException {
+      TTupleProtocol iprot = (TTupleProtocol) prot;
+      BitSet incoming = iprot.readBitSet(2);
+      if (incoming.get(0)) {
+        struct.sessionId = iprot.readString();
+        struct.setSessionIdIsSet(true);
+      }
+      if (incoming.get(1)) {
+        struct.tableName = iprot.readString();
+        struct.setTableNameIsSet(true);
+      }
+    }
+  }
+
+}
+

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/70b69ecb/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ShardLayout.java
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ShardLayout.java b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ShardLayout.java
new file mode 100644
index 0000000..f4c359e
--- /dev/null
+++ b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/ShardLayout.java
@@ -0,0 +1,581 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.0)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *  @generated
+ */
+package org.apache.blur.thrift.generated;
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+
+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 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 org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class ShardLayout implements org.apache.thrift.TBase<ShardLayout, ShardLayout._Fields>, java.io.Serializable, Cloneable {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ShardLayout");
+
+  private static final org.apache.thrift.protocol.TField SERVER_FIELD_DESC = new org.apache.thrift.protocol.TField("server", org.apache.thrift.protocol.TType.STRING, (short)1);
+  private static final org.apache.thrift.protocol.TField SHARDS_FIELD_DESC = new org.apache.thrift.protocol.TField("shards", org.apache.thrift.protocol.TType.LIST, (short)2);
+
+  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+  static {
+    schemes.put(StandardScheme.class, new ShardLayoutStandardSchemeFactory());
+    schemes.put(TupleScheme.class, new ShardLayoutTupleSchemeFactory());
+  }
+
+  /**
+   * The server for this layout.
+   */
+  public String server; // required
+  /**
+   * A list of shard ids for the given server.
+   */
+  public List<Integer> shards; // 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 {
+    /**
+     * The server for this layout.
+     */
+    SERVER((short)1, "server"),
+    /**
+     * A list of shard ids for the given server.
+     */
+    SHARDS((short)2, "shards");
+
+    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: // SERVER
+          return SERVER;
+        case 2: // SHARDS
+          return SHARDS;
+        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.SERVER, new org.apache.thrift.meta_data.FieldMetaData("server", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
+    tmpMap.put(_Fields.SHARDS, new org.apache.thrift.meta_data.FieldMetaData("shards", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        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))));
+    metaDataMap = Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ShardLayout.class, metaDataMap);
+  }
+
+  public ShardLayout() {
+  }
+
+  public ShardLayout(
+    String server,
+    List<Integer> shards)
+  {
+    this();
+    this.server = server;
+    this.shards = shards;
+  }
+
+  /**
+   * Performs a deep copy on <i>other</i>.
+   */
+  public ShardLayout(ShardLayout other) {
+    if (other.isSetServer()) {
+      this.server = other.server;
+    }
+    if (other.isSetShards()) {
+      List<Integer> __this__shards = new ArrayList<Integer>();
+      for (Integer other_element : other.shards) {
+        __this__shards.add(other_element);
+      }
+      this.shards = __this__shards;
+    }
+  }
+
+  public ShardLayout deepCopy() {
+    return new ShardLayout(this);
+  }
+
+  @Override
+  public void clear() {
+    this.server = null;
+    this.shards = null;
+  }
+
+  /**
+   * The server for this layout.
+   */
+  public String getServer() {
+    return this.server;
+  }
+
+  /**
+   * The server for this layout.
+   */
+  public ShardLayout setServer(String server) {
+    this.server = server;
+    return this;
+  }
+
+  public void unsetServer() {
+    this.server = null;
+  }
+
+  /** Returns true if field server is set (has been assigned a value) and false otherwise */
+  public boolean isSetServer() {
+    return this.server != null;
+  }
+
+  public void setServerIsSet(boolean value) {
+    if (!value) {
+      this.server = null;
+    }
+  }
+
+  public int getShardsSize() {
+    return (this.shards == null) ? 0 : this.shards.size();
+  }
+
+  public java.util.Iterator<Integer> getShardsIterator() {
+    return (this.shards == null) ? null : this.shards.iterator();
+  }
+
+  public void addToShards(int elem) {
+    if (this.shards == null) {
+      this.shards = new ArrayList<Integer>();
+    }
+    this.shards.add(elem);
+  }
+
+  /**
+   * A list of shard ids for the given server.
+   */
+  public List<Integer> getShards() {
+    return this.shards;
+  }
+
+  /**
+   * A list of shard ids for the given server.
+   */
+  public ShardLayout setShards(List<Integer> shards) {
+    this.shards = shards;
+    return this;
+  }
+
+  public void unsetShards() {
+    this.shards = null;
+  }
+
+  /** Returns true if field shards is set (has been assigned a value) and false otherwise */
+  public boolean isSetShards() {
+    return this.shards != null;
+  }
+
+  public void setShardsIsSet(boolean value) {
+    if (!value) {
+      this.shards = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, Object value) {
+    switch (field) {
+    case SERVER:
+      if (value == null) {
+        unsetServer();
+      } else {
+        setServer((String)value);
+      }
+      break;
+
+    case SHARDS:
+      if (value == null) {
+        unsetShards();
+      } else {
+        setShards((List<Integer>)value);
+      }
+      break;
+
+    }
+  }
+
+  public Object getFieldValue(_Fields field) {
+    switch (field) {
+    case SERVER:
+      return getServer();
+
+    case SHARDS:
+      return getShards();
+
+    }
+    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 SERVER:
+      return isSetServer();
+    case SHARDS:
+      return isSetShards();
+    }
+    throw new IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(Object that) {
+    if (that == null)
+      return false;
+    if (that instanceof ShardLayout)
+      return this.equals((ShardLayout)that);
+    return false;
+  }
+
+  public boolean equals(ShardLayout that) {
+    if (that == null)
+      return false;
+
+    boolean this_present_server = true && this.isSetServer();
+    boolean that_present_server = true && that.isSetServer();
+    if (this_present_server || that_present_server) {
+      if (!(this_present_server && that_present_server))
+        return false;
+      if (!this.server.equals(that.server))
+        return false;
+    }
+
+    boolean this_present_shards = true && this.isSetShards();
+    boolean that_present_shards = true && that.isSetShards();
+    if (this_present_shards || that_present_shards) {
+      if (!(this_present_shards && that_present_shards))
+        return false;
+      if (!this.shards.equals(that.shards))
+        return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    return 0;
+  }
+
+  public int compareTo(ShardLayout other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+    ShardLayout typedOther = (ShardLayout)other;
+
+    lastComparison = Boolean.valueOf(isSetServer()).compareTo(typedOther.isSetServer());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetServer()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.server, typedOther.server);
+      if (lastComparison != 0) {
+        return lastComparison;
+      }
+    }
+    lastComparison = Boolean.valueOf(isSetShards()).compareTo(typedOther.isSetShards());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetShards()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shards, typedOther.shards);
+      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("ShardLayout(");
+    boolean first = true;
+
+    sb.append("server:");
+    if (this.server == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.server);
+    }
+    first = false;
+    if (!first) sb.append(", ");
+    sb.append("shards:");
+    if (this.shards == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.shards);
+    }
+    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 ShardLayoutStandardSchemeFactory implements SchemeFactory {
+    public ShardLayoutStandardScheme getScheme() {
+      return new ShardLayoutStandardScheme();
+    }
+  }
+
+  private static class ShardLayoutStandardScheme extends StandardScheme<ShardLayout> {
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot, ShardLayout 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: // SERVER
+            if (schemeField.type == org.apache.thrift.protocol.TType.STRING) {
+              struct.server = iprot.readString();
+              struct.setServerIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          case 2: // SHARDS
+            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
+              {
+                org.apache.thrift.protocol.TList _list120 = iprot.readListBegin();
+                struct.shards = new ArrayList<Integer>(_list120.size);
+                for (int _i121 = 0; _i121 < _list120.size; ++_i121)
+                {
+                  int _elem122; // required
+                  _elem122 = iprot.readI32();
+                  struct.shards.add(_elem122);
+                }
+                iprot.readListEnd();
+              }
+              struct.setShardsIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked in the validate method
+      struct.validate();
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot, ShardLayout struct) throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      if (struct.server != null) {
+        oprot.writeFieldBegin(SERVER_FIELD_DESC);
+        oprot.writeString(struct.server);
+        oprot.writeFieldEnd();
+      }
+      if (struct.shards != null) {
+        oprot.writeFieldBegin(SHARDS_FIELD_DESC);
+        {
+          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, struct.shards.size()));
+          for (int _iter123 : struct.shards)
+          {
+            oprot.writeI32(_iter123);
+          }
+          oprot.writeListEnd();
+        }
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+
+  }
+
+  private static class ShardLayoutTupleSchemeFactory implements SchemeFactory {
+    public ShardLayoutTupleScheme getScheme() {
+      return new ShardLayoutTupleScheme();
+    }
+  }
+
+  private static class ShardLayoutTupleScheme extends TupleScheme<ShardLayout> {
+
+    @Override
+    public void write(org.apache.thrift.protocol.TProtocol prot, ShardLayout struct) throws org.apache.thrift.TException {
+      TTupleProtocol oprot = (TTupleProtocol) prot;
+      BitSet optionals = new BitSet();
+      if (struct.isSetServer()) {
+        optionals.set(0);
+      }
+      if (struct.isSetShards()) {
+        optionals.set(1);
+      }
+      oprot.writeBitSet(optionals, 2);
+      if (struct.isSetServer()) {
+        oprot.writeString(struct.server);
+      }
+      if (struct.isSetShards()) {
+        {
+          oprot.writeI32(struct.shards.size());
+          for (int _iter124 : struct.shards)
+          {
+            oprot.writeI32(_iter124);
+          }
+        }
+      }
+    }
+
+    @Override
+    public void read(org.apache.thrift.protocol.TProtocol prot, ShardLayout struct) throws org.apache.thrift.TException {
+      TTupleProtocol iprot = (TTupleProtocol) prot;
+      BitSet incoming = iprot.readBitSet(2);
+      if (incoming.get(0)) {
+        struct.server = iprot.readString();
+        struct.setServerIsSet(true);
+      }
+      if (incoming.get(1)) {
+        {
+          org.apache.thrift.protocol.TList _list125 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, iprot.readI32());
+          struct.shards = new ArrayList<Integer>(_list125.size);
+          for (int _i126 = 0; _i126 < _list125.size; ++_i126)
+          {
+            int _elem127; // required
+            _elem127 = iprot.readI32();
+            struct.shards.add(_elem127);
+          }
+        }
+        struct.setShardsIsSet(true);
+      }
+    }
+  }
+
+}
+

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/70b69ecb/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Sort.java
----------------------------------------------------------------------
diff --git a/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Sort.java b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Sort.java
new file mode 100644
index 0000000..3dcf8b9
--- /dev/null
+++ b/src/distribution/src/main/scripts/interface/gen-java/org/apache/blur/thrift/generated/Sort.java
@@ -0,0 +1,459 @@
+/**
+ * Autogenerated by Thrift Compiler (0.9.0)
+ *
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+ *  @generated
+ */
+package org.apache.blur.thrift.generated;
+
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+
+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 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 org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class Sort implements org.apache.thrift.TBase<Sort, Sort._Fields>, java.io.Serializable, Cloneable {
+  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("Sort");
+
+  private static final org.apache.thrift.protocol.TField FIELDS_FIELD_DESC = new org.apache.thrift.protocol.TField("fields", org.apache.thrift.protocol.TType.LIST, (short)1);
+
+  private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
+  static {
+    schemes.put(StandardScheme.class, new SortStandardSchemeFactory());
+    schemes.put(TupleScheme.class, new SortTupleSchemeFactory());
+  }
+
+  public List<SortField> fields; // 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 {
+    FIELDS((short)1, "fields");
+
+    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: // FIELDS
+          return FIELDS;
+        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.FIELDS, new org.apache.thrift.meta_data.FieldMetaData("fields", org.apache.thrift.TFieldRequirementType.DEFAULT, 
+        new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
+            new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, SortField.class))));
+    metaDataMap = Collections.unmodifiableMap(tmpMap);
+    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Sort.class, metaDataMap);
+  }
+
+  public Sort() {
+  }
+
+  public Sort(
+    List<SortField> fields)
+  {
+    this();
+    this.fields = fields;
+  }
+
+  /**
+   * Performs a deep copy on <i>other</i>.
+   */
+  public Sort(Sort other) {
+    if (other.isSetFields()) {
+      List<SortField> __this__fields = new ArrayList<SortField>();
+      for (SortField other_element : other.fields) {
+        __this__fields.add(new SortField(other_element));
+      }
+      this.fields = __this__fields;
+    }
+  }
+
+  public Sort deepCopy() {
+    return new Sort(this);
+  }
+
+  @Override
+  public void clear() {
+    this.fields = null;
+  }
+
+  public int getFieldsSize() {
+    return (this.fields == null) ? 0 : this.fields.size();
+  }
+
+  public java.util.Iterator<SortField> getFieldsIterator() {
+    return (this.fields == null) ? null : this.fields.iterator();
+  }
+
+  public void addToFields(SortField elem) {
+    if (this.fields == null) {
+      this.fields = new ArrayList<SortField>();
+    }
+    this.fields.add(elem);
+  }
+
+  public List<SortField> getFields() {
+    return this.fields;
+  }
+
+  public Sort setFields(List<SortField> fields) {
+    this.fields = fields;
+    return this;
+  }
+
+  public void unsetFields() {
+    this.fields = null;
+  }
+
+  /** Returns true if field fields is set (has been assigned a value) and false otherwise */
+  public boolean isSetFields() {
+    return this.fields != null;
+  }
+
+  public void setFieldsIsSet(boolean value) {
+    if (!value) {
+      this.fields = null;
+    }
+  }
+
+  public void setFieldValue(_Fields field, Object value) {
+    switch (field) {
+    case FIELDS:
+      if (value == null) {
+        unsetFields();
+      } else {
+        setFields((List<SortField>)value);
+      }
+      break;
+
+    }
+  }
+
+  public Object getFieldValue(_Fields field) {
+    switch (field) {
+    case FIELDS:
+      return getFields();
+
+    }
+    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 FIELDS:
+      return isSetFields();
+    }
+    throw new IllegalStateException();
+  }
+
+  @Override
+  public boolean equals(Object that) {
+    if (that == null)
+      return false;
+    if (that instanceof Sort)
+      return this.equals((Sort)that);
+    return false;
+  }
+
+  public boolean equals(Sort that) {
+    if (that == null)
+      return false;
+
+    boolean this_present_fields = true && this.isSetFields();
+    boolean that_present_fields = true && that.isSetFields();
+    if (this_present_fields || that_present_fields) {
+      if (!(this_present_fields && that_present_fields))
+        return false;
+      if (!this.fields.equals(that.fields))
+        return false;
+    }
+
+    return true;
+  }
+
+  @Override
+  public int hashCode() {
+    return 0;
+  }
+
+  public int compareTo(Sort other) {
+    if (!getClass().equals(other.getClass())) {
+      return getClass().getName().compareTo(other.getClass().getName());
+    }
+
+    int lastComparison = 0;
+    Sort typedOther = (Sort)other;
+
+    lastComparison = Boolean.valueOf(isSetFields()).compareTo(typedOther.isSetFields());
+    if (lastComparison != 0) {
+      return lastComparison;
+    }
+    if (isSetFields()) {
+      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fields, typedOther.fields);
+      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("Sort(");
+    boolean first = true;
+
+    sb.append("fields:");
+    if (this.fields == null) {
+      sb.append("null");
+    } else {
+      sb.append(this.fields);
+    }
+    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 SortStandardSchemeFactory implements SchemeFactory {
+    public SortStandardScheme getScheme() {
+      return new SortStandardScheme();
+    }
+  }
+
+  private static class SortStandardScheme extends StandardScheme<Sort> {
+
+    public void read(org.apache.thrift.protocol.TProtocol iprot, Sort 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: // FIELDS
+            if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
+              {
+                org.apache.thrift.protocol.TList _list64 = iprot.readListBegin();
+                struct.fields = new ArrayList<SortField>(_list64.size);
+                for (int _i65 = 0; _i65 < _list64.size; ++_i65)
+                {
+                  SortField _elem66; // required
+                  _elem66 = new SortField();
+                  _elem66.read(iprot);
+                  struct.fields.add(_elem66);
+                }
+                iprot.readListEnd();
+              }
+              struct.setFieldsIsSet(true);
+            } else { 
+              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+            }
+            break;
+          default:
+            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
+        }
+        iprot.readFieldEnd();
+      }
+      iprot.readStructEnd();
+
+      // check for required fields of primitive type, which can't be checked in the validate method
+      struct.validate();
+    }
+
+    public void write(org.apache.thrift.protocol.TProtocol oprot, Sort struct) throws org.apache.thrift.TException {
+      struct.validate();
+
+      oprot.writeStructBegin(STRUCT_DESC);
+      if (struct.fields != null) {
+        oprot.writeFieldBegin(FIELDS_FIELD_DESC);
+        {
+          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, struct.fields.size()));
+          for (SortField _iter67 : struct.fields)
+          {
+            _iter67.write(oprot);
+          }
+          oprot.writeListEnd();
+        }
+        oprot.writeFieldEnd();
+      }
+      oprot.writeFieldStop();
+      oprot.writeStructEnd();
+    }
+
+  }
+
+  private static class SortTupleSchemeFactory implements SchemeFactory {
+    public SortTupleScheme getScheme() {
+      return new SortTupleScheme();
+    }
+  }
+
+  private static class SortTupleScheme extends TupleScheme<Sort> {
+
+    @Override
+    public void write(org.apache.thrift.protocol.TProtocol prot, Sort struct) throws org.apache.thrift.TException {
+      TTupleProtocol oprot = (TTupleProtocol) prot;
+      BitSet optionals = new BitSet();
+      if (struct.isSetFields()) {
+        optionals.set(0);
+      }
+      oprot.writeBitSet(optionals, 1);
+      if (struct.isSetFields()) {
+        {
+          oprot.writeI32(struct.fields.size());
+          for (SortField _iter68 : struct.fields)
+          {
+            _iter68.write(oprot);
+          }
+        }
+      }
+    }
+
+    @Override
+    public void read(org.apache.thrift.protocol.TProtocol prot, Sort struct) throws org.apache.thrift.TException {
+      TTupleProtocol iprot = (TTupleProtocol) prot;
+      BitSet incoming = iprot.readBitSet(1);
+      if (incoming.get(0)) {
+        {
+          org.apache.thrift.protocol.TList _list69 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32());
+          struct.fields = new ArrayList<SortField>(_list69.size);
+          for (int _i70 = 0; _i70 < _list69.size; ++_i70)
+          {
+            SortField _elem71; // required
+            _elem71 = new SortField();
+            _elem71.read(iprot);
+            struct.fields.add(_elem71);
+          }
+        }
+        struct.setFieldsIsSet(true);
+      }
+    }
+  }
+
+}
+


Mime
View raw message