org.apache.hadoop.hbase.codec
Class BaseDecoder

java.lang.Object
  extended by org.apache.hadoop.hbase.codec.BaseDecoder
All Implemented Interfaces:
Decoder
Direct Known Subclasses:
KeyValueCodec.KeyValueDecoder

public abstract class BaseDecoder
extends Object
implements Decoder


Field Summary
protected  KeyValue current
           
protected  InputStream in
           
protected static org.apache.commons.logging.Log LOG
           
 
Constructor Summary
BaseDecoder(InputStream in)
           
 
Method Summary
 boolean advance()
          Advance the scanner 1 object
 KeyValue current()
           
protected abstract  KeyValue parseCell()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

protected static final org.apache.commons.logging.Log LOG

in

protected final InputStream in

current

protected KeyValue current
Constructor Detail

BaseDecoder

public BaseDecoder(InputStream in)
Method Detail

advance

public boolean advance()
                throws IOException
Description copied from interface: Decoder
Advance the scanner 1 object

Specified by:
advance in interface Decoder
Returns:
true if the next cell is found and Decoder.current() will return a valid object
Throws:
IOException - if there is an error reading the next entry

parseCell

protected abstract KeyValue parseCell()
                               throws IOException
Returns:
extract a Cell
Throws:
IOException

current

public KeyValue current()
Specified by:
current in interface Decoder
Returns:
the current object which may be mutable


Copyright © 2015 The Apache Software Foundation. All Rights Reserved.