while (iterator.hasNext()) {
final PageSequence pageSequence = iterator.next();
try {
final PageCollection collection = areaTree.makePageCollection(
pageSequence);
layout.formatPageSequence(collection);
} catch (final AreaTreeException e) {
throw new FOrayException(e);
}
}
return areaTree;