Skip to Content.
Sympa Menu

xom-interest - Re: [XOM-interest] Preserve white space in text nodes

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: "Stevenson, Todd (GE Healthcare)" <Todd.T.Stevenson AT ge.com>
  • To: XOM API for Processing XML with Java <xom-interest AT lists.ibiblio.org>
  • Subject: Re: [XOM-interest] Preserve white space in text nodes
  • Date: Thu, 19 Jan 2012 15:24:09 +0000

Thanks all. Problem fixed.

-----Original Message-----
From: xom-interest-bounces AT lists.ibiblio.org
[mailto:xom-interest-bounces AT lists.ibiblio.org] On Behalf Of Michael Kay
Sent: Thursday, January 19, 2012 5:27 AM
To: xom-interest AT lists.ibiblio.org
Subject: Re: [XOM-interest] Preserve white space in text nodes


>This is your problem. When you use setIndent and/or setMaxLength you are
>telling the serializer to pretty print. I.e. you are telling it that it
>should modify the white space so you have a certain line length and
>indenting. If you want to preserve white space, don't do that. Absent
>instructions to the contrary, XOM will preserve white space in text nodes.

The message here seems to be that XOM indentation is more aggressive than
XSLT indentation, which only adds whitespace before or after start and end
tags.

Michael Kay
Saxonica

_______________________________________________
XOM-interest mailing list
XOM-interest AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/xom-interest




Archive powered by MHonArc 2.6.24.

Top of Page