org.apache.pig.data
Class DataReaderWriter

java.lang.Object
  extended by org.apache.pig.data.DataReaderWriter

@InterfaceAudience.Private
@InterfaceStability.Stable
public class DataReaderWriter
extends Object

This class was used to handle reading and writing of intermediate results of data types. Now that functionality is in BinInterSedes This class could also be used for storing permanent results, it used by BinStorage and Zebra through DefaultTuple class.


Field Summary
static String UTF8
           
 
Constructor Summary
DataReaderWriter()
           
 
Method Summary
static DataBag bytesToBag(DataInput in)
           
static String bytesToBigCharArray(DataInput in)
           
static String bytesToCharArray(DataInput in)
           
static InternalMap bytesToInternalMap(DataInput in)
           
static Map<String,Object> bytesToMap(DataInput in)
           
static Tuple bytesToTuple(DataInput in)
           
static org.apache.hadoop.io.Writable bytesToWritable(DataInput in)
           
static Object readDatum(DataInput in)
           
static Object readDatum(DataInput in, byte type)
           
static void writeDatum(DataOutput out, Object val)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

UTF8

public static final String UTF8
See Also:
Constant Field Values
Constructor Detail

DataReaderWriter

public DataReaderWriter()
Method Detail

bytesToTuple

public static Tuple bytesToTuple(DataInput in)
                          throws IOException
Throws:
IOException

bytesToBag

public static DataBag bytesToBag(DataInput in)
                          throws IOException
Throws:
IOException

bytesToMap

public static Map<String,Object> bytesToMap(DataInput in)
                                     throws IOException
Throws:
IOException

bytesToInternalMap

public static InternalMap bytesToInternalMap(DataInput in)
                                      throws IOException
Throws:
IOException

bytesToCharArray

public static String bytesToCharArray(DataInput in)
                               throws IOException
Throws:
IOException

bytesToBigCharArray

public static String bytesToBigCharArray(DataInput in)
                                  throws IOException
Throws:
IOException

bytesToWritable

public static org.apache.hadoop.io.Writable bytesToWritable(DataInput in)
                                                     throws IOException
Throws:
IOException

readDatum

public static Object readDatum(DataInput in)
                        throws IOException,
                               ExecException
Throws:
IOException
ExecException

readDatum

public static Object readDatum(DataInput in,
                               byte type)
                        throws IOException,
                               ExecException
Throws:
IOException
ExecException

writeDatum

public static void writeDatum(DataOutput out,
                              Object val)
                       throws IOException
Throws:
IOException


Copyright © ${year} The Apache Software Foundation