|
|
|
|
stringTokens
Parses a string into tokens and iterates over its content for each token.
Tag Summary |
required |
<c:stringTokens string="value" name="value">
content to be repeated for each iteration
</c:stringTokens>
|
full tag |
<c:stringTokens string="value" name="value" delimitedBy="value" delimiter="value" reverse="value" tokenLength="value">
content to be repeated for each iteration
</c:stringTokens>
|
Required Attributes |
string |
The string to be parsed |
name |
The variable name to be associated with the temporary model nodes describing the tokens. Nested tags can use this variable name to refer to the temporary node. |
Optional Attributes |
delimitedBy |
The tokens that delimit the tokens in the string |
delimiter |
The string to write after every iteration except the last |
reverse |
A true/false value indicating whether the tokens should be iterated over first-to-last (false) or last-to-first (true) |
tokenLength |
Default description for attribute tokenLength |
Example |
|
<%-- break a,bc,cde into tokens, and iterate over them --%>
<c:stringTokens string="a,bc,cde" name="curStr" delimitedBy=",">
value: <c:get select="$curStr/@value"/>
index: <c:get select="$curStr/@index"/>
delimiter: <c:get select="$curStr/@delimiter"/>
first: <c:get select="$curStr/@first"/>
last: <c:get select="$curStr/@last"/>
</c:stringTokens>
|
|
|
|