Search in sources :

Example 16 with ByteBufferInputStream

use of org.apache.hyracks.dataflow.common.comm.util.ByteBufferInputStream in project asterixdb by apache.

the class FrameDebugUtils method prettyPrint.

/**
     * Debugging method
     * @param fta
     * @param recordDescriptor
     * @param tIdx
     * @param recordFields
     * @throws IOException
     */
public void prettyPrint(IFrameTupleAccessor fta, RecordDescriptor recordDescriptor, int tIdx, int[] recordFields) throws IOException {
    try (ByteBufferInputStream bbis = new ByteBufferInputStream();
        DataInputStream dis = new DataInputStream(bbis)) {
        StringBuilder sb = new StringBuilder();
        prettyPrint(fta, recordDescriptor, tIdx, bbis, dis, sb, recordFields);
        System.err.println(sb.toString());
    }
}
Also used : ByteBufferInputStream(org.apache.hyracks.dataflow.common.comm.util.ByteBufferInputStream) DataInputStream(java.io.DataInputStream)

Aggregations

ByteBufferInputStream (org.apache.hyracks.dataflow.common.comm.util.ByteBufferInputStream)16 DataInputStream (java.io.DataInputStream)14 IOException (java.io.IOException)7 ByteBuffer (java.nio.ByteBuffer)3 IFrameTupleAccessor (org.apache.hyracks.api.comm.IFrameTupleAccessor)3 VSizeFrame (org.apache.hyracks.api.comm.VSizeFrame)2 RecordDescriptor (org.apache.hyracks.api.dataflow.value.RecordDescriptor)2 IHyracksDataset (org.apache.hyracks.api.dataset.IHyracksDataset)2 IHyracksDatasetReader (org.apache.hyracks.api.dataset.IHyracksDatasetReader)2 HyracksDataException (org.apache.hyracks.api.exceptions.HyracksDataException)2 HyracksDataset (org.apache.hyracks.client.dataset.HyracksDataset)2 FrameManager (org.apache.hyracks.control.nc.resources.memory.FrameManager)2 FrameTupleAccessor (org.apache.hyracks.dataflow.common.comm.io.FrameTupleAccessor)2 ResultFrameTupleAccessor (org.apache.hyracks.dataflow.common.comm.io.ResultFrameTupleAccessor)2 ObjectMapper (com.fasterxml.jackson.databind.ObjectMapper)1 ArrayNode (com.fasterxml.jackson.databind.node.ArrayNode)1 BufferedWriter (java.io.BufferedWriter)1 FileWriter (java.io.FileWriter)1 PrintStream (java.io.PrintStream)1 ArrayList (java.util.ArrayList)1