From c8eef151767dfb45d64367df40b9d3afcf0a3244 Mon Sep 17 00:00:00 2001 From: Musachy Barroso Date: Thu, 27 Sep 2007 19:15:04 +0000 Subject: [PATCH] WW-2216 Improve/complete JavaDocs for IteratorStatus/ tag. git-svn-id: https://svn.apache.org/repos/asf/struts/struts2/trunk@580128 13f79535-47bb-0310-9956-ffa450edef68 --- .../struts2/views/jsp/IteratorStatus.java | 27 ++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/core/src/main/java/org/apache/struts2/views/jsp/IteratorStatus.java b/core/src/main/java/org/apache/struts2/views/jsp/IteratorStatus.java index 3b1dbe4bf..cb48d0ffc 100644 --- a/core/src/main/java/org/apache/struts2/views/jsp/IteratorStatus.java +++ b/core/src/main/java/org/apache/struts2/views/jsp/IteratorStatus.java @@ -23,9 +23,30 @@ package org.apache.struts2.views.jsp; /** * The iterator tag can export an IteratorStatus object so that - * one can get information about the status of the iteration, such as - * the size, current index, and whether any more items are available. - * + * one can get information about the status of the iteration, such as: + * + *

Example

+ *
+ *   <s:iterator status="status" value='%{0, 1}'>
+ *      Index: <s:property value="%{#status.index}" /> <br />
+ *      Count: <s:property value="%{#status.count}" /> <br />  
+ *   </s:iterator>
+ * 
+ * + *

will print

+ *
+ *      Index: 0
+ *      Count: 1
+ *      Index: 1
+ *      Count: 2
+ * 
*/ public class IteratorStatus { protected StatusState state;