ColumnCountGetFilterAdapter extends TypedFilterAdapterBase<ColumnCountGetFilter> { @Override public Filter adapt(FilterAdapterContext context, ColumnCountGetFilter filter) throws IOException { return FILTERS .chain() .filter(FILTERS.limit().cellsPerColumn(1)) .filter(FILTERS.limit().cellsPerRow(filter.getLimit())); }  @Override Filter adapt(FilterAdapterContext context, ColumnCountGetFilter filter); @Override FilterSupportStatus isFilterSupported(
      FilterAdapterContext context, ColumnCountGetFilter filter);  }
@Test public void testSimpleColumnCount() throws IOException { Filters.Filter adaptedFilter = adapter.adapt(new FilterAdapterContext(new Scan(), null), new ColumnCountGetFilter(2)); Assert.assertEquals( FILTERS .chain() .filter(FILTERS.limit().cellsPerColumn(1)) .filter(FILTERS.limit().cellsPerRow(2)) .toProto(), adaptedFilter.toProto()); }