This project has retired. For details please refer to its Attic page.
PersistentDatumReader (Apache Gora 0.2 API)

org.apache.gora.avro
Class PersistentDatumReader<T extends Persistent>

java.lang.Object
  extended by org.apache.avro.generic.GenericDatumReader<T>
      extended by org.apache.avro.specific.SpecificDatumReader<T>
          extended by org.apache.gora.avro.PersistentDatumReader<T>
All Implemented Interfaces:
org.apache.avro.io.DatumReader<T>

public class PersistentDatumReader<T extends Persistent>
extends org.apache.avro.specific.SpecificDatumReader<T>

PersistentDatumReader reads, fields' dirty and readable information.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.avro.specific.SpecificDatumReader
org.apache.avro.specific.SpecificDatumReader.SchemaConstructable
 
Constructor Summary
PersistentDatumReader()
           
PersistentDatumReader(org.apache.avro.Schema schema, boolean readDirtyBits)
           
 
Method Summary
 Persistent clone(Persistent persistent, org.apache.avro.Schema schema)
           
protected  Object cloneObject(org.apache.avro.Schema schema, Object toClone, Object cloned)
           
protected  org.apache.avro.io.ResolvingDecoder getResolvingDecoder(org.apache.avro.io.Decoder decoder)
           
protected  Object newArray(Object old, int size, org.apache.avro.Schema schema)
          Called to create new array instances.
protected  Object newMap(Object old, int size)
           
 T newPersistent()
           
protected  Object newRecord(Object old, org.apache.avro.Schema schema)
           
 Object read(Object reuse, org.apache.avro.Schema schema, org.apache.avro.io.Decoder decoder)
           
 T read(T reuse, org.apache.avro.io.Decoder in)
           
protected  Object readMap(Object old, org.apache.avro.Schema expected, org.apache.avro.io.ResolvingDecoder in)
           
protected  Object readRecord(Object old, org.apache.avro.Schema expected, org.apache.avro.io.ResolvingDecoder in)
           
 void setSchema(org.apache.avro.Schema actual)
           
 
Methods inherited from class org.apache.avro.specific.SpecificDatumReader
createEnum, createFixed, newInstance
 
Methods inherited from class org.apache.avro.generic.GenericDatumReader
addToArray, addToMap, createBytes, createFixed, createString, getField, peekArray, read, readArray, readBytes, readEnum, readFixed, readInt, readString, readString, removeField, setExpected, setField, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PersistentDatumReader

public PersistentDatumReader()

PersistentDatumReader

public PersistentDatumReader(org.apache.avro.Schema schema,
                             boolean readDirtyBits)
Method Detail

setSchema

public void setSchema(org.apache.avro.Schema actual)
Specified by:
setSchema in interface org.apache.avro.io.DatumReader<T extends Persistent>
Overrides:
setSchema in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>

newPersistent

public T newPersistent()

newRecord

protected Object newRecord(Object old,
                           org.apache.avro.Schema schema)
Overrides:
newRecord in class org.apache.avro.specific.SpecificDatumReader<T extends Persistent>

read

public T read(T reuse,
              org.apache.avro.io.Decoder in)
                          throws IOException
Specified by:
read in interface org.apache.avro.io.DatumReader<T extends Persistent>
Overrides:
read in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>
Throws:
IOException

read

public Object read(Object reuse,
                   org.apache.avro.Schema schema,
                   org.apache.avro.io.Decoder decoder)
            throws IOException
Throws:
IOException

getResolvingDecoder

protected org.apache.avro.io.ResolvingDecoder getResolvingDecoder(org.apache.avro.io.Decoder decoder)
                                                           throws IOException
Throws:
IOException

readRecord

protected Object readRecord(Object old,
                            org.apache.avro.Schema expected,
                            org.apache.avro.io.ResolvingDecoder in)
                     throws IOException
Overrides:
readRecord in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>
Throws:
IOException

readMap

protected Object readMap(Object old,
                         org.apache.avro.Schema expected,
                         org.apache.avro.io.ResolvingDecoder in)
                  throws IOException
Overrides:
readMap in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>
Throws:
IOException

newMap

protected Object newMap(Object old,
                        int size)
Overrides:
newMap in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>

newArray

protected Object newArray(Object old,
                          int size,
                          org.apache.avro.Schema schema)
Called to create new array instances. Subclasses may override to use a different array implementation. By default, this returns a GenericData.Array instance.

Overrides:
newArray in class org.apache.avro.generic.GenericDatumReader<T extends Persistent>

clone

public Persistent clone(Persistent persistent,
                        org.apache.avro.Schema schema)

cloneObject

protected Object cloneObject(org.apache.avro.Schema schema,
                             Object toClone,
                             Object cloned)


Copyright © 2010-2013 The Apache Software Foundation. All Rights Reserved.