private void accumulateProductAttributes(Pool stackedSubPool, Pool nextStackedPool) {
if (nextStackedPool.getDerivedProductId() == null) {
for (ProductPoolAttribute attr : nextStackedPool.getProductAttributes()) {
expectedAttrs.put(attr.getName(),
new ProductPoolAttribute(attr.getName(), attr.getValue(),
stackedSubPool.getProductId()));
}
}
else {
for (DerivedProductPoolAttribute attr :
nextStackedPool.getDerivedProductAttributes()) {
expectedAttrs.put(attr.getName(),
new ProductPoolAttribute(attr.getName(), attr.getValue(),
stackedSubPool.getProductId()));
}
}
}