Пример #1
0
 @Override
 public int doEndTag() throws JspException {
   if (indexTagExport != null) {
     String name;
     if ((name = indexTagExport.getItemCount()) != null) {
       restoreAttribute(name, oldItemCount);
       oldItemCount = null;
     }
     if ((name = indexTagExport.getPageCount()) != null) {
       restoreAttribute(name, oldPageCount);
       oldPageCount = null;
     }
   }
   super.doEndTag();
   return EVAL_PAGE;
 }
Пример #2
0
 @Override
 public int doStartTag() throws JspException {
   super.doStartTag();
   if (indexTagExport != null) {
     String name;
     if ((name = indexTagExport.getItemCount()) != null) {
       oldItemCount = pageContext.getAttribute(name);
       pageContext.setAttribute(name, new Integer(pagerTag.getItemCount()));
     }
     if ((name = indexTagExport.getPageCount()) != null) {
       oldPageCount = pageContext.getAttribute(name);
       pageContext.setAttribute(name, new Integer(pagerTag.getPageCount()));
     }
   }
   return (pagerTag.isIndexNeeded() ? EVAL_BODY_INCLUDE : SKIP_BODY);
 }