int totalResultSetSize = 0;
List<Long> creativeWrapperIds = new ArrayList<Long>();
do {
// Get creative wrappers by statement.
CreativeWrapperPage page =
creativeWrapperService.getCreativeWrappersByStatement(statementBuilder.toStatement());
if (page.getResults() != null) {
totalResultSetSize = page.getTotalResultSetSize();
int i = page.getStartIndex();
for (CreativeWrapper creativeWrapper : page.getResults()) {
System.out.printf("%d) Creative wrapper with ID \"%d\" applying to label"
+ " \"%s\" will be deactivated.\n", i++, creativeWrapper.getId(),
creativeWrapper.getLabelId());
creativeWrapperIds.add(creativeWrapper.getId());
}