@Override
  public OperationQuota checkBatchQuota(final Region region,
    final OperationQuota.OperationType type) throws IOException, RpcThrottlingException {
    switch (type) {
      case GET:
        return this.checkBatchQuota(region, 0, 1, false);
      case MUTATE:
        return this.checkBatchQuota(region, 1, 0, false);
      case CHECK_AND_MUTATE:
        return this.checkBatchQuota(region, 1, 1, true);
    }
    throw new RuntimeException("Invalid operation type: " + type);
  }
Returns the quota for an operation.
@param ugi   the user that is executing the operation
@param table the table where the operation will be executed
@return the OperationQuota
hbase-server/src/main/java/org/apache/hadoop/hbase/quotas/RegionServerRpcQuotaManager.java