You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "Palaniappan, Krishnasamy" <Pa...@diebold.com> on 2000/12/19 19:05:49 UTC

Replacement for a boolean !?

Hi,
I have a need to use something like a boolean. I tried several things but I am running out of ideas to handle something like this in XSLFO.I have several blocks of code in my FOP stylesheet. Basically, what I need to do is set a boolean variable to true if some condition is satisfied and act accordingly, SEVERAL BLOCKS down. So, something like this does not seem to be an option:
	<xsl:variable>
		<xsl:choose>
			<xsl:when test="...">
			</xsl:when>
			<xsl:otherwise>
			...
			</xsl:otherwise>
		</xsl:choose>
	</xsl:variable>

Could anyone please give me an example as to how I could use boolean variables. This is what I need.

1. Set boolean to false, initially.
2. Open FOR loop.
3. Check condition. If true, set boolean to true.
4. If boolean is true, do something.
5. set boolean to false.
6. close loop.
		
Please advise.
Thanks,
Krish