Preserving the structure of the input XML file

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Oleg Dulin

    Preserving the structure of the input XML file

    Colleagues:

    Does anyone know if there are less-lossy XML parsers and serializers
    that can capture and reproduce the structure of the input XML file
    including tabulation,whit espace, etc. ? We would love to know about
    experiences with parse/serialization approaches that have a greater
    infoset than that provided by SAX and DOM, especially related to
    ignorable whitespace and attributes ordering/whitespace. We are editing
    XML and want to preserve the file as much as possible.

    Kind regards,
    Oleg Dulin
    Opence, Inc.

  • Andy Fish

    #2
    Re: Preserving the structure of the input XML file

    this makes a change, most people want to do exactly the opposite and think
    that parsers preserve too much whitespace

    I would have thought that as long as you set the "ignore whitespace" flag
    off, sax and DOM would give you all the whitespace in the file - that has
    been my experience (unless you're using MSXML which seems to swallow much
    more whitespace than other parsers)


    "Oleg Dulin" <oleg.dulin@ope nce_dot_net.net > wrote in message
    news:oPAhb.3113 0$pv6.3715@twis ter.nyc.rr.com. ..[color=blue]
    > Colleagues:
    >
    > Does anyone know if there are less-lossy XML parsers and serializers
    > that can capture and reproduce the structure of the input XML file
    > including tabulation,whit espace, etc. ? We would love to know about
    > experiences with parse/serialization approaches that have a greater
    > infoset than that provided by SAX and DOM, especially related to
    > ignorable whitespace and attributes ordering/whitespace. We are editing
    > XML and want to preserve the file as much as possible.
    >
    > Kind regards,
    > Oleg Dulin
    > Opence, Inc.
    >[/color]


    Comment

    Working...