code: @Override
  	public void setAggregator(IAggregator aggregator) {
  		if (this.aggregator != null) {
  			throw new IllegalStateException();
  		}
  		this.aggregator = aggregator;
  
  		// See if the max cache entries init-param has changed and
  		int newMaxCapacity = getMaxCapacity(aggregator);
  
  		// If the maximum size has changed, then create a new layerBuildMap with the new
  		// max size and copy the entries from the existing map to the new map
  		ConcurrentLinkedHashMap<String, CacheEntry> oldLayerBuildMap = null;
  		// have no layer builds in the layerBuildMap
  		if (maxCapacity != newMaxCapacity) {
  			maxCapacity = newMaxCapacity;
  			oldLayerBuildMap = layerBuildMap;
  			layerBuildMap = new ConcurrentLinkedHashMap.Builder<String, CacheEntry>()
  					.maximumWeightedCapacity(maxCapacity)
  					.listener(newEvictionListener())
  					.weigher(newWeigher())
  					.build();
  			// Need to call setLayerBuildAccessors BEFORE calling putAll because
  			// it might result in the eviction handler being called.
  			setLayerBuildAccessors(oldLayerBuildMap.keySet());
  			layerBuildMap.putAll(oldLayerBuildMap.ascendingMap());
  			oldLayerBuildMap.clear();
  		} else {
  			setLayerBuildAccessors(layerBuildMap.keySet());
  		}
  	}
docs: /* (non-Javadoc)
  @see com.ibm.jaggr.service.layer.ILayerCache#setAggregator(com.ibm.jaggr.service.IAggregator)