*/
if (totalPages == 0 || pageNum > totalPages || pageNum <= 0) {
return WorkflowInstancePage.blankPage();
}
WorkflowInstancePage retPage = new WorkflowInstancePage();
retPage.setPageNum(pageNum);
retPage.setPageSize(this.pageSize);
retPage.setTotalPages(totalPages);
List wInstIds = paginateWorkflows(pageNum, status);
if (wInstIds != null && wInstIds.size() > 0) {
List workflowInstances = new Vector(wInstIds.size());
for (Iterator i = wInstIds.iterator(); i.hasNext();) {
String workflowInstId = (String) i.next();
WorkflowInstance inst = getWorkflowInstanceById(workflowInstId);
workflowInstances.add(inst);
}
retPage.setPageWorkflows(workflowInstances);
}
return retPage;
}