<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib tagdir="/WEB-INF/tags" prefix="st"%>
<%@taglib uri="/sample" prefix="sample"%>
<st:page title="repeat example">
<ul>
<sample:repeat times="5">
<li>Repetition
<sample:repeat.currentNumber/>
</li>
</sample:repeat>
</ul>
<div class="info">
A simple custom tag which repeats its body 5 times. The number of the current
repetition is printed via an output tag. Output tags are normal tags from the JSP document
view point and methods on the java side. They are resolved to a normal method invocation
during template compilation.
<p>
Note how the japano javadoc tags are used to define the tag, its two attributes and
its single output tag. That's all you need to do to define a tag and implicitly a tag
library. Import the tag library via an import directive and you can use the tag in
your JSP document.
<ul>
<li><a href="org/japanosample/Repeat.java.html">Commented tag source code</a></li>
<li><a href="repeat.jsp.html">Commented JSP document source</a></li>
<li><a href="navigation.jspf.html">Sample site navigation include.</a></li>
</ul>
</div>
</st:page>