Search in sources :

Example 1 with LoopIterator

use of jodd.util.LoopIterator in project jodd by oblac.

the class LoopingTagSupport method loopBody.

/**
	 * Loops body.
	 */
protected void loopBody() throws JspException {
    JspFragment body = getJspBody();
    if (body == null) {
        return;
    }
    LoopIterator loopIterator = new LoopIterator(start, end, step, modulus);
    if (status != null) {
        getJspContext().setAttribute(status, loopIterator);
    }
    while (loopIterator.next()) {
        TagUtil.invokeBody(body);
    }
    if (status != null) {
        getJspContext().removeAttribute(status);
    }
}
Also used : JspFragment(javax.servlet.jsp.tagext.JspFragment) LoopIterator(jodd.util.LoopIterator)

Aggregations

JspFragment (javax.servlet.jsp.tagext.JspFragment)1 LoopIterator (jodd.util.LoopIterator)1