@Override
  public CacheClosedException getCacheClosedException(String reason, Throwable cause) {
    CacheClosedException result;
    if (cause != null) {
      result = new CacheClosedException(reason, cause);
    } else if (disconnectCause != null) {
      result = new CacheClosedException(reason, disconnectCause);
    } else {
      result = new CacheClosedException(reason);
    }
    return result;
  }
Initialize the contents of this {@code Cache} according to the declarative caching XML file
specified by the given {@code DistributedSystem}. Note that this operation cannot be performed
in the constructor because creating regions in the cache, etc. uses the cache itself (which
isn't initialized until the constructor returns).

@throws CacheXmlException If something goes wrong while parsing the declarative caching XML
        file.
@throws TimeoutException If a {@link Region#put(Object, Object)}times out while initializing
        the cache.
@throws CacheWriterException If a {@code CacheWriterException} is thrown while initializing the
        cache.
@throws RegionExistsException If the declarative caching XML file describes a region that
        already exists (including the root region).
@throws GatewayException If a {@code GatewayException} is thrown while initializing the cache.
@see #loadCacheXml
geode-core/src/main/java/org/apache/geode/internal/cache/GemFireCacheImpl.java