MultiValueWithWeightFacetDataCache<?> dataCache = new MultiValueWithWeightFacetDataCache();
dataCache.setMaxItems(_maxItems);
if (_sizePayloadTerm == null) {
dataCache.load(_indexFieldName, reader, _termListFactory, workArea);
} else {
dataCache.load(_indexFieldName, reader, _termListFactory, _sizePayloadTerm);
}
return dataCache;
}