com.google.cloud.bigtable.hbase.adapters.filters
Class SingleFilterAdapter<T extends Filter>
- java.lang.Object
-
- com.google.cloud.bigtable.hbase.adapters.filters.SingleFilterAdapter<T>
-
-
Constructor Summary
Constructors Constructor and Description SingleFilterAdapter(Class<T> filterClass, TypedFilterAdapter<T> adapter)
Constructor for SingleFilterAdapter.SingleFilterAdapter(Class<T> filterClass, TypedFilterAdapter<T> adapter, UnsupportedStatusCollector<T> unsupportedStatusCollector)
Constructor for SingleFilterAdapter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description com.google.cloud.bigtable.data.v2.models.Filters.Filter
adapt(FilterAdapterContext context, Filter hbaseFilter)
Adapt the untyped hbaseFilter instance into a RowFilter.void
collectUnsupportedStatuses(FilterAdapterContext context, Filter filter, List<FilterSupportStatus> statuses)
Collect unsupported status objects into the given list.RangeSet<RowKeyWrapper>
getIndexScanHint(Filter filter)
protected T
getTypedFilter(Filter filter)
getTypedFilter.protected boolean
isFilterAProperSublcass(Filter filter)
isFilterAProperSublcass.FilterSupportStatus
isSupported(FilterAdapterContext context, Filter hbaseFilter)
Determine if the untyped filter is supported.
-
-
-
Constructor Detail
-
SingleFilterAdapter
public SingleFilterAdapter(Class<T> filterClass, TypedFilterAdapter<T> adapter)
Constructor for SingleFilterAdapter.- Parameters:
filterClass
- aClass
object.adapter
- aTypedFilterAdapter
object.
-
SingleFilterAdapter
public SingleFilterAdapter(Class<T> filterClass, TypedFilterAdapter<T> adapter, UnsupportedStatusCollector<T> unsupportedStatusCollector)
Constructor for SingleFilterAdapter.- Parameters:
filterClass
- aClass
object.adapter
- aTypedFilterAdapter
object.unsupportedStatusCollector
- aUnsupportedStatusCollector
object.
-
-
Method Detail
-
adapt
public com.google.cloud.bigtable.data.v2.models.Filters.Filter adapt(FilterAdapterContext context, Filter hbaseFilter) throws IOException
Adapt the untyped hbaseFilter instance into a RowFilter.- Parameters:
context
- aFilterAdapterContext
object.hbaseFilter
- aFilter
object.- Returns:
- a
RowFilter
object. - Throws:
IOException
- if any.
-
isSupported
public FilterSupportStatus isSupported(FilterAdapterContext context, Filter hbaseFilter)
Determine if the untyped filter is supported.- Parameters:
context
- aFilterAdapterContext
object.hbaseFilter
- aFilter
object.- Returns:
- a
FilterSupportStatus
object.
-
collectUnsupportedStatuses
public void collectUnsupportedStatuses(FilterAdapterContext context, Filter filter, List<FilterSupportStatus> statuses)
Collect unsupported status objects into the given list.- Parameters:
context
- aFilterAdapterContext
object.filter
- aFilter
object.statuses
- aList
object.
-
getIndexScanHint
public RangeSet<RowKeyWrapper> getIndexScanHint(Filter filter)
-
getTypedFilter
protected T getTypedFilter(Filter filter)
getTypedFilter.- Parameters:
filter
- aFilter
object.- Returns:
- a T object.
-
-