static Scan createScanForNamespaceSnapshotSizes(String namespace) {
    Scan s = new Scan();
    if (namespace == null || namespace.isEmpty()) {
      // Read all namespaces, just look at the row prefix
      s.setStartStopRowForPrefixScan(QUOTA_NAMESPACE_ROW_KEY_PREFIX);
    } else {
      // Fetch the exact row for the table
      byte[] rowkey = getNamespaceRowKey(namespace);
      // Fetch just this one row
      s.withStartRow(rowkey).withStopRow(rowkey, true);
    }

    // Just the usage family and only the snapshot size qualifiers
    return s.addFamily(QUOTA_FAMILY_USAGE)
      .setFilter(new ColumnPrefixFilter(QUOTA_SNAPSHOT_SIZE_QUALIFIER));
  }
Returns a scanner for all namespace snapshot entries of the given namespace
@param namespace name of the namespace whose snapshot entries are to be scanned
hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaTableUtil.java