cond

Conditionally processes its content based on the number of model nodes that meet the given criterea


Tag Summary
 
required <cond nodes="value" card="value" />
 
full tag <cond nodes="value" card="value" />

Required Attributes
 
nodes Query expression describing the nodes to be counted
card A string containing some combination of "0" (zero), "1" (one) and "M". The cond tag will process its contents if no nodes match the query expression and this attribute value contains a "0", if exactly one node matches the query expression and this attribute value contains a "1" or if more than one model nodes match the query expression and this attriute value contains "M".

There are no optional attributes
 

Example
 
<cond
        nodes="department/member"
        card="0M" >
   content
</cond>

This cond tag will locate the node associated with variable name "department" and step to all of that's nodes children who are named "member". If that collection of child nodes is empty or if it has more than one node, then the cond tag will process its contents.


© Copyright IBM Corporation 2000, 2006. All Rights Reserved.