NamespaceTableAndRegionInfo addNamespace(String namespace) {
    if (!nsStateCache.containsKey(namespace)) {
      NamespaceTableAndRegionInfo a1 = new NamespaceTableAndRegionInfo(namespace);
      nsStateCache.put(namespace, a1);
    }
    return nsStateCache.get(namespace);
  }
Check and update region count for an existing table. To handle scenarios like restore snapshot
@param name name of the table for region count needs to be checked and updated
@param incr count of regions
@throws QuotaExceededException if quota exceeds for the number of regions allowed in a
                               namespace
@throws IOException            Signals that an I/O exception has occurred.
hbase-server/src/main/java/org/apache/hadoop/hbase/namespace/NamespaceStateManager.java