Subject: Re: [xsl] RE: xslt and bitwise operations From: Francis Norton <francis@xxxxxxxxxxx> Date: Thu, 11 Jan 2001 14:37:35 +0000 |
"Clapham, Paul" wrote: > > Not directly, but it does support the arithmetic operations "div" and "mod" > that you can use to simulate bitwise calculations. For example, to extract > the low-order bit from x you could use "x mod 2", and to extract the bit to > the left of that you could use "floor(x div 2) mod 2" and like that. > > Extracting more than one bit at a time using a mask (e.g. "x and 17") is > Left As An Exercise For The Student. > And as an excellent use case for Jeni's proposal for "xsl:script: functions written in XSLT" Francis. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] RE: xslt and bitwise oper, Clapham, Paul | Thread | RE: [xsl] RE: xslt and bitwise oper, Kay Michael |
Re: [xsl] Testing by counting or po, Francis Norton | Date | Re: [xsl] Controlling white space, Bob DuCharme |
Month |