org.apache.hadoop.hbase.filter
Class SingleColumnValueExcludeFilter

java.lang.Object
  extended by org.apache.hadoop.hbase.filter.FilterBase
      extended by org.apache.hadoop.hbase.filter.SingleColumnValueFilter
          extended by org.apache.hadoop.hbase.filter.SingleColumnValueExcludeFilter
All Implemented Interfaces:
Filter, org.apache.hadoop.io.Writable

public class SingleColumnValueExcludeFilter
extends SingleColumnValueFilter

A Filter that checks a single column value, but does not emit the tested column. This will enable a performance boost over SingleColumnValueFilter, if the tested column value is not actually needed as input (besides for the filtering itself).


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.hadoop.hbase.filter.Filter
Filter.ReturnCode
 
Field Summary
 
Fields inherited from class org.apache.hadoop.hbase.filter.SingleColumnValueFilter
columnFamily, columnQualifier
 
Constructor Summary
SingleColumnValueExcludeFilter()
          Writable constructor, do not use.
SingleColumnValueExcludeFilter(byte[] family, byte[] qualifier, CompareFilter.CompareOp compareOp, byte[] value)
          Constructor for binary compare of the value of a single column.
SingleColumnValueExcludeFilter(byte[] family, byte[] qualifier, CompareFilter.CompareOp compareOp, WritableByteArrayComparable comparator)
          Constructor for binary compare of the value of a single column.
 
Method Summary
static Filter createFilterFromArguments(ArrayList<byte[]> filterArguments)
           
 void filterRow(List<KeyValue> kvs)
          Filters that never filter by modifying the returned List of KeyValues can inherit this implementation that does nothing.
 boolean hasFilterRow()
          Fitlers that never filter by modifying the returned List of KeyValues can inherit this implementation that does nothing.
 
Methods inherited from class org.apache.hadoop.hbase.filter.SingleColumnValueFilter
filterKeyValue, filterRow, getComparator, getFamily, getFilterIfMissing, getLatestVersionOnly, getOperator, getQualifier, isFamilyEssential, readFields, reset, setFilterIfMissing, setLatestVersionOnly, toString, write
 
Methods inherited from class org.apache.hadoop.hbase.filter.FilterBase
filterAllRemaining, filterRowKey, getNextKeyHint, isFamilyEssential, transform
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SingleColumnValueExcludeFilter

public SingleColumnValueExcludeFilter()
Writable constructor, do not use.


SingleColumnValueExcludeFilter

public SingleColumnValueExcludeFilter(byte[] family,
                                      byte[] qualifier,
                                      CompareFilter.CompareOp compareOp,
                                      byte[] value)
Constructor for binary compare of the value of a single column. If the column is found and the condition passes, all columns of the row will be emitted; except for the tested column value. If the column is not found or the condition fails, the row will not be emitted.

Parameters:
family - name of column family
qualifier - name of column qualifier
compareOp - operator
value - value to compare column values against

SingleColumnValueExcludeFilter

public SingleColumnValueExcludeFilter(byte[] family,
                                      byte[] qualifier,
                                      CompareFilter.CompareOp compareOp,
                                      WritableByteArrayComparable comparator)
Constructor for binary compare of the value of a single column. If the column is found and the condition passes, all columns of the row will be emitted; except for the tested column value. If the condition fails, the row will not be emitted.

Use the filterIfColumnMissing flag to set whether the rest of the columns in a row will be emitted if the specified column to check is not found in the row.

Parameters:
family - name of column family
qualifier - name of column qualifier
compareOp - operator
comparator - Comparator to use.
Method Detail

hasFilterRow

public boolean hasFilterRow()
Description copied from class: FilterBase
Fitlers that never filter by modifying the returned List of KeyValues can inherit this implementation that does nothing.

Specified by:
hasFilterRow in interface Filter
Overrides:
hasFilterRow in class FilterBase
Returns:
True if this filter actively uses filterRow(List). Primarily used to check for conflicts with scans(such as scans that do not read a full row at a time)

filterRow

public void filterRow(List<KeyValue> kvs)
Description copied from class: FilterBase
Filters that never filter by modifying the returned List of KeyValues can inherit this implementation that does nothing.

Specified by:
filterRow in interface Filter
Overrides:
filterRow in class FilterBase
Parameters:
kvs - the list of keyvalues to be filtered

createFilterFromArguments

public static Filter createFilterFromArguments(ArrayList<byte[]> filterArguments)


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