|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.hbase.filter.Filter
org.apache.hadoop.hbase.filter.FilterBase
org.apache.hadoop.hbase.filter.PrefixFilter
@InterfaceAudience.Public @InterfaceStability.Stable public class PrefixFilter
Pass results that have same row prefix.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.hadoop.hbase.filter.Filter |
---|
Filter.ReturnCode |
Field Summary | |
---|---|
protected boolean |
filterRow
|
protected boolean |
passedPrefix
|
protected byte[] |
prefix
|
Fields inherited from class org.apache.hadoop.hbase.filter.Filter |
---|
reversed |
Constructor Summary | |
---|---|
PrefixFilter(byte[] prefix)
|
Method Summary | |
---|---|
static Filter |
createFilterFromArguments(ArrayList<byte[]> filterArguments)
|
boolean |
filterAllRemaining()
Filters that never filter all remaining can inherit this implementation that never stops the filter early. |
Filter.ReturnCode |
filterKeyValue(Cell v)
Filters that dont filter by key value can inherit this implementation that includes all Cells. |
boolean |
filterRow()
Filters that never filter by rows based on previously gathered state from FilterBase.filterKeyValue(Cell) can inherit this implementation that
never filters a row. |
boolean |
filterRowKey(byte[] buffer,
int offset,
int length)
Filters that do not filter by row key can inherit this implementation that never filters anything. |
byte[] |
getPrefix()
|
static PrefixFilter |
parseFrom(byte[] pbBytes)
|
void |
reset()
Filters that are purely stateless and do nothing in their reset() methods can inherit this null/empty implementation. |
byte[] |
toByteArray()
Return length 0 byte array for Filters that don't require special serialization |
String |
toString()
Return filter's info for debugging and logging purpose. |
Methods inherited from class org.apache.hadoop.hbase.filter.FilterBase |
---|
filterRow, filterRowCells, getNextCellHint, getNextKeyHint, hasFilterRow, isFamilyEssential, transform, transformCell |
Methods inherited from class org.apache.hadoop.hbase.filter.Filter |
---|
isReversed, setReversed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected byte[] prefix
protected boolean passedPrefix
protected boolean filterRow
Constructor Detail |
---|
public PrefixFilter(byte[] prefix)
Method Detail |
---|
public byte[] getPrefix()
public boolean filterRowKey(byte[] buffer, int offset, int length)
FilterBase
filterRowKey
in class FilterBase
buffer
- buffer containing row keyoffset
- offset into buffer where row key startslength
- length of the row key
public Filter.ReturnCode filterKeyValue(Cell v)
FilterBase
filterKeyValue
in class FilterBase
v
- the Cell in question
Filter.ReturnCode
public boolean filterRow()
FilterBase
FilterBase.filterKeyValue(Cell)
can inherit this implementation that
never filters a row.
filterRow
in class FilterBase
public void reset()
FilterBase
reset
in class FilterBase
public boolean filterAllRemaining()
FilterBase
filterAllRemaining
in class FilterBase
public static Filter createFilterFromArguments(ArrayList<byte[]> filterArguments)
public byte[] toByteArray()
FilterBase
toByteArray
in class FilterBase
public static PrefixFilter parseFrom(byte[] pbBytes) throws DeserializationException
pbBytes
- A pb serialized PrefixFilter
instance
PrefixFilter
made from bytes
DeserializationException
toByteArray()
public String toString()
FilterBase
toString
in class FilterBase
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |