public static String printFrameTuples(
     ITreeIndexFrame frame, ISerializerDeserializer[] fieldSerdes) throws HyracksDataException {
   StringBuilder strBuilder = new StringBuilder();
   ITreeIndexTupleReference tuple = frame.createTupleReference();
   for (int i = 0; i < frame.getTupleCount(); i++) {
     tuple.resetByTupleIndex(frame, i);
     String tupleString = TupleUtils.printTuple(tuple, fieldSerdes);
     strBuilder.append(tupleString);
     if (i != frame.getTupleCount() - 1) {
       strBuilder.append(" | ");
     }
   }
   return strBuilder.toString();
 }
 @Override
 public ITupleReference getMaxTuple() {
   maxTuple.resetByTupleOffset(buf, maxTupleOff);
   return maxTuple;
 }