public void sameAs(ResourceManager other) {
    if (getCriticalHeapPercentage() != other.getCriticalHeapPercentage()) {
      throw new RuntimeException("Resource Manager critical heap percentages differ: "
          + getCriticalHeapPercentage() + " != " + other.getCriticalHeapPercentage());
    }
    if (getCriticalOffHeapPercentage() != other.getCriticalOffHeapPercentage()) {
      throw new RuntimeException("Resource Manager critical off-heap percentages differ: "
          + getCriticalOffHeapPercentage() + " != " + other.getCriticalOffHeapPercentage());
    }
    if (hasEvictionHeap()) {
      // If we don't have it set don't compare since other may have been set to
      // a smart default.
      if (getEvictionHeapPercentage() != other.getEvictionHeapPercentage()) {
        throw new RuntimeException("Resource Manager eviction heap percentages differ: "
            + getEvictionHeapPercentage() + " != " + other.getEvictionHeapPercentage());
      }
    }
    if (hasEvictionOffHeap()) {
      // If we don't have it set don't compare since other may have been set to
      // a smart default.
      if (getEvictionOffHeapPercentage() != other.getEvictionOffHeapPercentage()) {
        throw new RuntimeException("Resource Manager eviction off-heap percentages differ: "
            + getEvictionOffHeapPercentage() + " != " + other.getEvictionOffHeapPercentage());
      }
    }
  }
@param other the other ResourceManager with which to compare
geode-core/src/main/java/org/apache/geode/internal/cache/xmlcache/ResourceManagerCreation.java