Artifact 3b283491363fa0c4c3185e05b2222e0720dc7f5f0423a3f66c4bd1edec374d08:

  • File doc/dom.xml — part of check-in [18be91e27b] at 2018-10-06 00:38:06 on branch trunk — Defined the return value of some featureinfo methods more precisely. For background see [38409e31938f]. (user: rolf size: 30256) [more...]

0000: 3c 6d 61 6e 70 61 67 65 20 69 64 3d 22 64 6f 6d  <manpage id="dom
0010: 22 20 63 61 74 3d 22 63 6d 64 22 20 74 69 74 6c  " cat="cmd" titl
0020: 65 3d 22 64 6f 6d 22 3e 0a 20 20 3c 6e 61 6d 65  e="dom">.  <name
0030: 73 65 63 74 69 6f 6e 3e 0a 20 20 20 20 3c 6e 61  section>.    <na
0040: 6d 65 3e 64 6f 6d 3c 2f 6e 61 6d 65 3e 0a 20 20  me>dom</name>.  
0050: 20 20 3c 64 65 73 63 3e 43 72 65 61 74 65 20 61    <desc>Create a
0060: 6e 20 69 6e 2d 6d 65 6d 6f 72 79 20 44 4f 4d 20  n in-memory DOM 
0070: 74 72 65 65 20 66 72 6f 6d 20 58 4d 4c 3c 2f 64  tree from XML</d
0080: 65 73 63 3e 0a 20 20 3c 2f 6e 61 6d 65 73 65 63  esc>.  </namesec
0090: 74 69 6f 6e 3e 0a 20 20 3c 21 2d 2d 0a 20 20 0a  tion>.  <!--.  .
00a0: 20 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20    Copyright (c) 
00b0: 31 39 39 39 20 4a 6f 63 68 65 6e 20 4c 6f 65 77  1999 Jochen Loew
00c0: 65 72 20 28 6c 6f 65 77 65 72 6a 40 68 6f 74 6d  er (loewerj@hotm
00d0: 61 69 6c 2e 63 6f 6d 29 0a 20 20 0a 20 20 53 65  ail.com).  .  Se
00e0: 65 20 74 68 65 20 66 69 6c 65 20 22 4c 49 43 45  e the file "LICE
00f0: 4e 53 45 22 20 66 6f 72 20 69 6e 66 6f 72 6d 61  NSE" for informa
0100: 74 69 6f 6e 20 6f 6e 20 75 73 61 67 65 20 61 6e  tion on usage an
0110: 64 20 72 65 64 69 73 74 72 69 62 75 74 69 6f 6e  d redistribution
0120: 0a 20 20 6f 66 20 74 68 69 73 20 66 69 6c 65 2c  .  of this file,
0130: 20 61 6e 64 20 66 6f 72 20 61 20 44 49 53 43 4c   and for a DISCL
0140: 41 49 4d 45 52 20 4f 46 20 41 4c 4c 20 57 41 52  AIMER OF ALL WAR
0150: 52 41 4e 54 49 45 53 2e 0a 20 20 0a 20 20 2d 2d  RANTIES..  .  --
0160: 3e 0a 20 20 3c 73 79 6e 6f 70 73 69 73 3e 0a 20  >.  <synopsis>. 
0170: 20 20 20 3c 73 79 6e 74 61 78 3e 70 61 63 6b 61     <syntax>packa
0180: 67 65 20 72 65 71 75 69 72 65 20 74 64 6f 6d 0a  ge require tdom.
0190: 0a 3c 63 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20  .<cmd>dom</cmd> 
01a0: 3c 6d 3e 6d 65 74 68 6f 64 3c 2f 6d 3e 20 3f 3c  <m>method</m> ?<
01b0: 6d 3e 61 72 67 20 61 72 67 20 2e 2e 2e 3c 2f 6d  m>arg arg ...</m
01c0: 3e 3f 3c 2f 73 79 6e 74 61 78 3e 0a 20 20 3c 2f  >?</syntax>.  </
01d0: 73 79 6e 6f 70 73 69 73 3e 0a 0a 20 20 3c 73 65  synopsis>..  <se
01e0: 63 74 69 6f 6e 3e 0a 20 20 20 20 3c 74 69 74 6c  ction>.    <titl
01f0: 65 3e 44 45 53 43 52 49 50 54 49 4f 4e 20 3c 2f  e>DESCRIPTION </
0200: 74 69 74 6c 65 3e 20 20 20 20 0a 0a 20 20 20 20  title>    ..    
0210: 3c 70 3e 54 68 69 73 20 63 6f 6d 6d 61 6e 64 20  <p>This command 
0220: 70 72 6f 76 69 64 65 73 20 74 68 65 20 63 72 65  provides the cre
0230: 61 74 69 6f 6e 20 6f 66 20 44 4f 4d 20 74 72 65  ation of DOM tre
0240: 65 73 20 69 6e 20 6d 65 6d 6f 72 79 2e 20 49 6e  es in memory. In
0250: 0a 74 68 65 20 75 73 75 61 6c 20 63 61 73 65 20  .the usual case 
0260: 61 20 73 74 72 69 6e 67 20 63 6f 6e 74 61 69 6e  a string contain
0270: 69 6e 67 20 61 20 58 4d 4c 20 69 6e 66 6f 72 6d  ing a XML inform
0280: 61 74 69 6f 6e 20 69 73 20 70 61 72 73 65 64 20  ation is parsed 
0290: 61 6e 64 20 63 6f 6e 76 65 72 74 65 64 0a 69 6e  and converted.in
02a0: 74 6f 20 61 20 44 4f 4d 20 74 72 65 65 2e 20 4f  to a DOM tree. O
02b0: 74 68 65 72 20 70 6f 73 73 69 62 6c 65 20 70 61  ther possible pa
02c0: 72 73 65 20 69 6e 70 75 74 20 6d 61 79 20 62 65  rse input may be
02d0: 20 48 54 4d 4c 20 6f 72 20 4a 53 4f 4e 2e 0a 54   HTML or JSON..T
02e0: 68 65 20 3c 6d 3e 6d 65 74 68 6f 64 3c 2f 6d 3e  he <m>method</m>
02f0: 20 69 6e 64 69 63 61 74 65 73 20 61 20 73 70 65   indicates a spe
0300: 63 69 66 69 63 20 73 75 62 63 6f 6d 6d 61 6e 64  cific subcommand
0310: 2e 20 3c 2f 70 3e 0a 0a 20 20 20 20 3c 70 3e 54  . </p>..    <p>T
0320: 68 65 20 76 61 6c 69 64 20 6d 65 74 68 6f 64 73  he valid methods
0330: 20 61 72 65 3a 3c 2f 70 3e 0a 0a 20 20 20 20 20   are:</p>..     
0340: 20 3c 63 6f 6d 6d 61 6e 64 6c 69 73 74 3e 0a 20   <commandlist>. 
0350: 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 64         <commandd
0360: 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 63  ef>.          <c
0370: 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d 3c  ommand><cmd>dom<
0380: 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 70 61  /cmd> <method>pa
0390: 72 73 65 3c 2f 6d 65 74 68 6f 64 3e 20 3f 3c 6d  rse</method> ?<m
03a0: 3e 6f 70 74 69 6f 6e 73 3c 2f 6d 3e 3f 20 3f 3c  >options</m>? ?<
03b0: 6d 3e 64 61 74 61 3c 2f 6d 3e 3f 3c 2f 63 6f 6d  m>data</m>?</com
03c0: 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20 20  mand>.          
03d0: 3c 64 65 73 63 3e 50 61 72 73 65 73 20 74 68 65  <desc>Parses the
03e0: 20 58 4d 4c 20 69 6e 66 6f 72 6d 61 74 69 6f 6e   XML information
03f0: 20 61 6e 64 20 62 75 69 6c 64 73 20 75 70 20 74   and builds up t
0400: 68 65 20 44 4f 4d 20 74 72 65 65 20 69 6e 20 6d  he DOM tree in m
0410: 65 6d 6f 72 79 0a 70 72 6f 76 69 64 69 6e 67 20  emory.providing 
0420: 61 20 54 63 6c 20 6f 62 6a 65 63 74 20 63 6f 6d  a Tcl object com
0430: 6d 61 6e 64 20 74 6f 20 74 68 69 73 20 44 4f 4d  mand to this DOM
0440: 20 64 6f 63 75 6d 65 6e 74 20 6f 62 6a 65 63 74   document object
0450: 2e 20 45 78 61 6d 70 6c 65 3a 0a 0a 20 20 20 20  . Example:..    
0460: 20 20 3c 65 78 61 6d 70 6c 65 3e 0a 64 6f 6d 20    <example>.dom 
0470: 70 61 72 73 65 20 24 78 6d 6c 20 64 6f 63 0a 24  parse $xml doc.$
0480: 64 6f 63 20 64 6f 63 75 6d 65 6e 74 45 6c 65 6d  doc documentElem
0490: 65 6e 74 20 72 6f 6f 74 3c 2f 65 78 61 6d 70 6c  ent root</exampl
04a0: 65 3e 0a 0a 20 20 20 20 20 20 3c 70 3e 70 61 72  e>..      <p>par
04b0: 73 65 73 20 74 68 65 20 58 4d 4c 20 69 6e 20 74  ses the XML in t
04c0: 68 65 20 76 61 72 69 61 62 6c 65 20 78 6d 6c 2c  he variable xml,
04d0: 20 63 72 65 61 74 65 73 20 74 68 65 20 44 4f 4d   creates the DOM
04e0: 20 74 72 65 65 20 69 6e 20 6d 65 6d 6f 72 79 2c   tree in memory,
04f0: 0a 6d 61 6b 65 20 61 20 72 65 66 65 72 65 6e 63  .make a referenc
0500: 65 20 74 6f 20 74 68 65 20 64 6f 63 75 6d 65 6e  e to the documen
0510: 74 20 6f 62 6a 65 63 74 2c 20 76 69 73 69 62 6c  t object, visibl
0520: 65 20 69 6e 20 54 63 6c 20 61 73 20 61 20 64 6f  e in Tcl as a do
0530: 63 75 6d 65 6e 74 20 6f 62 6a 65 63 74 0a 63 6f  cument object.co
0540: 6d 6d 61 6e 64 2c 20 61 6e 64 20 61 73 73 69 67  mmand, and assig
0550: 6e 73 20 74 68 69 73 20 6e 65 77 20 6f 62 6a 65  ns this new obje
0560: 63 74 20 6e 61 6d 65 20 74 6f 20 74 68 65 20 76  ct name to the v
0570: 61 72 69 61 62 6c 65 20 64 6f 63 2e 20 57 68 65  ariable doc. Whe
0580: 6e 20 64 6f 63 20 67 65 74 73 0a 66 72 65 65 64  n doc gets.freed
0590: 2c 20 74 68 65 20 44 4f 4d 20 74 72 65 65 20 61  , the DOM tree a
05a0: 6e 64 20 74 68 65 20 61 73 73 6f 63 69 61 74 65  nd the associate
05b0: 64 20 54 63 6c 20 63 6f 6d 6d 61 6e 64 20 6f 62  d Tcl command ob
05c0: 6a 65 63 74 20 28 64 6f 63 75 6d 65 6e 74 20 61  ject (document a
05d0: 6e 64 20 61 6c 6c 0a 6e 6f 64 65 20 6f 62 6a 65  nd all.node obje
05e0: 63 74 73 29 20 61 72 65 20 66 72 65 65 64 20 61  cts) are freed a
05f0: 75 74 6f 6d 61 74 69 63 61 6c 6c 79 2e 3c 2f 70  utomatically.</p
0600: 3e 0a 20 20 20 20 20 20 0a 20 20 20 20 20 20 3c  >.      .      <
0610: 65 78 61 6d 70 6c 65 3e 0a 73 65 74 20 64 6f 63  example>.set doc
0620: 75 6d 65 6e 74 20 5b 64 6f 6d 20 70 61 72 73 65  ument [dom parse
0630: 20 24 78 6d 6c 5d 0a 73 65 74 20 72 6f 6f 74 20   $xml].set root 
0640: 20 20 20 20 5b 24 64 6f 63 75 6d 65 6e 74 20 64      [$document d
0650: 6f 63 75 6d 65 6e 74 45 6c 65 6d 65 6e 74 5d 3c  ocumentElement]<
0660: 2f 65 78 61 6d 70 6c 65 3e 0a 0a 20 20 20 20 20  /example>..     
0670: 20 3c 70 3e 70 61 72 73 65 73 20 74 68 65 20 58   <p>parses the X
0680: 4d 4c 20 69 6e 20 74 68 65 20 76 61 72 69 61 62  ML in the variab
0690: 6c 65 20 78 6d 6c 2c 20 63 72 65 61 74 65 73 20  le xml, creates 
06a0: 74 68 65 20 44 4f 4d 20 74 72 65 65 20 69 6e 20  the DOM tree in 
06b0: 6d 65 6d 6f 72 79 2c 0a 6d 61 6b 65 20 61 20 72  memory,.make a r
06c0: 65 66 65 72 65 6e 63 65 20 74 6f 20 74 68 65 20  eference to the 
06d0: 64 6f 63 75 6d 65 6e 74 20 6f 62 6a 65 63 74 2c  document object,
06e0: 20 76 69 73 69 62 6c 65 20 69 6e 20 54 63 6c 20   visible in Tcl 
06f0: 61 73 20 61 20 64 6f 63 75 6d 65 6e 74 20 6f 62  as a document ob
0700: 6a 65 63 74 0a 63 6f 6d 6d 61 6e 64 2c 20 61 6e  ject.command, an
0710: 64 20 72 65 74 75 72 6e 73 20 74 68 69 73 20 6e  d returns this n
0720: 65 77 20 6f 62 6a 65 63 74 20 6e 61 6d 65 2c 20  ew object name, 
0730: 77 68 69 63 68 20 69 73 20 74 68 65 6e 20 73 74  which is then st
0740: 6f 72 65 64 20 69 6e 0a 3c 6d 3e 64 6f 63 75 6d  ored in.<m>docum
0750: 65 6e 74 3c 2f 6d 3e 2e 20 20 54 6f 20 66 72 65  ent</m>.  To fre
0760: 65 20 74 68 65 20 75 6e 64 65 72 6c 79 69 6e 67  e the underlying
0770: 20 44 4f 4d 20 74 72 65 65 20 61 6e 64 20 74 68   DOM tree and th
0780: 65 20 61 73 73 6f 63 69 61 74 69 76 65 20 54 63  e associative Tc
0790: 6c 0a 6f 62 6a 65 63 74 20 63 6f 6d 6d 61 6e 64  l.object command
07a0: 73 20 28 64 6f 63 75 6d 65 6e 74 20 2b 20 6e 6f  s (document + no
07b0: 64 65 73 20 2b 20 66 72 61 67 6d 65 6e 74 20 6e  des + fragment n
07c0: 6f 64 65 73 29 20 74 68 65 20 64 6f 63 75 6d 65  odes) the docume
07d0: 6e 74 20 6f 62 6a 65 63 74 20 63 6f 6d 6d 61 6e  nt object comman
07e0: 64 0a 68 61 73 20 74 6f 20 62 65 20 65 78 70 6c  d.has to be expl
07f0: 69 63 69 74 6c 79 20 64 65 6c 65 74 65 64 20 62  icitly deleted b
0800: 79 3a 3c 2f 70 3e 0a 0a 20 20 20 20 20 20 3c 65  y:</p>..      <e
0810: 78 61 6d 70 6c 65 3e 0a 24 64 6f 63 75 6d 65 6e  xample>.$documen
0820: 74 20 64 65 6c 65 74 65 0a 3c 2f 65 78 61 6d 70  t delete.</examp
0830: 6c 65 3e 6f 72 3c 65 78 61 6d 70 6c 65 3e 0a 72  le>or<example>.r
0840: 65 6e 61 6d 65 20 24 64 6f 63 75 6d 65 6e 74 20  ename $document 
0850: 22 22 3c 2f 65 78 61 6d 70 6c 65 3e 0a 0a 3c 70  ""</example>..<p
0860: 3e 54 68 65 20 76 61 6c 69 64 20 6f 70 74 69 6f  >The valid optio
0870: 6e 73 20 61 72 65 3a 3c 2f 70 3e 0a 3c 6f 70 74  ns are:</p>.<opt
0880: 6c 69 73 74 3e 0a 20 20 20 20 20 20 20 20 20 20  list>.          
0890: 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20      <optdef>.   
08a0: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70               <op
08b0: 74 6e 61 6d 65 3e 2d 73 69 6d 70 6c 65 3c 2f 6f  tname>-simple</o
08c0: 70 74 6e 61 6d 65 3e 20 0a 20 20 20 20 20 20 20  ptname> .       
08d0: 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 49           <desc>I
08e0: 66 20 3c 6d 3e 2d 73 69 6d 70 6c 65 3c 2f 6d 3e  f <m>-simple</m>
08f0: 20 69 73 0a 73 70 65 63 69 66 69 65 64 2c 20 61   is.specified, a
0900: 20 73 69 6d 70 6c 65 20 62 75 74 20 66 61 73 74   simple but fast
0910: 20 70 61 72 73 65 72 20 69 73 20 75 73 65 64 20   parser is used 
0920: 28 63 6f 6e 66 6f 72 6d 73 20 6e 6f 74 20 66 75  (conforms not fu
0930: 6c 6c 79 20 74 6f 20 58 4d 4c 0a 72 65 63 6f 6d  lly to XML.recom
0940: 6d 65 6e 64 61 74 69 6f 6e 29 2e 20 54 68 61 74  mendation). That
0950: 20 73 68 6f 75 6c 64 20 64 6f 75 62 6c 65 20 70   should double p
0960: 61 72 73 69 6e 67 20 61 6e 64 20 44 4f 4d 20 67  arsing and DOM g
0970: 65 6e 65 72 61 74 69 6f 6e 20 73 70 65 65 64 2e  eneration speed.
0980: 20 54 68 65 0a 65 6e 63 6f 64 69 6e 67 20 6f 66   The.encoding of
0990: 20 74 68 65 20 64 61 74 61 20 69 73 20 6e 6f 74   the data is not
09a0: 20 74 72 61 6e 73 66 6f 72 6d 65 64 20 69 6e 73   transformed ins
09b0: 69 64 65 20 74 68 65 20 70 61 72 73 65 72 2e 20  ide the parser. 
09c0: 54 68 65 20 73 69 6d 70 6c 65 20 70 61 72 73 65  The simple parse
09d0: 72 0a 64 6f 65 73 20 6e 6f 74 20 72 65 73 70 65  r.does not respe
09e0: 63 74 20 61 6e 79 20 65 6e 63 6f 64 69 6e 67 20  ct any encoding 
09f0: 69 6e 66 6f 72 6d 61 74 69 6f 6e 20 69 6e 20 74  information in t
0a00: 68 65 20 58 4d 4c 20 64 65 63 6c 61 72 61 74 69  he XML declarati
0a10: 6f 6e 2e 20 49 74 20 73 6b 69 70 73 20 6f 76 65  on. It skips ove
0a20: 72 0a 74 68 65 20 69 6e 74 65 72 6e 61 6c 20 44  r.the internal D
0a30: 54 44 20 73 75 62 73 65 74 20 61 6e 64 20 69 67  TD subset and ig
0a40: 6e 6f 72 65 73 20 61 6e 79 20 69 6e 66 6f 72 6d  nores any inform
0a50: 61 74 69 6f 6e 20 69 6e 20 69 74 2e 20 54 68 65  ation in it. The
0a60: 72 65 66 6f 72 65 20 69 74 20 64 6f 65 73 6e 27  refore it doesn'
0a70: 74 0a 69 6e 63 6c 75 64 65 20 64 65 66 61 75 6c  t.include defaul
0a80: 74 65 64 20 61 74 74 72 69 62 75 74 65 20 76 61  ted attribute va
0a90: 6c 75 65 73 20 69 6e 74 6f 20 74 68 65 20 74 72  lues into the tr
0aa0: 65 65 2c 20 65 76 65 6e 20 69 66 20 74 68 65 20  ee, even if the 
0ab0: 61 63 63 6f 72 64 69 6e 67 0a 61 74 74 72 69 62  according.attrib
0ac0: 75 74 65 20 64 65 63 6c 61 72 61 74 69 6f 6e 20  ute declaration 
0ad0: 69 73 20 69 6e 20 74 68 65 20 69 6e 74 65 72 6e  is in the intern
0ae0: 61 6c 20 73 75 62 73 65 74 2e 20 49 74 20 61 6c  al subset. It al
0af0: 73 6f 20 64 6f 65 73 6e 27 74 20 65 78 70 61 6e  so doesn't expan
0b00: 64 0a 69 6e 74 65 72 6e 61 6c 20 6f 72 20 65 78  d.internal or ex
0b10: 74 65 72 6e 61 6c 20 65 6e 74 69 74 79 20 72 65  ternal entity re
0b20: 66 65 72 65 6e 63 65 73 20 6f 74 68 65 72 20 74  ferences other t
0b30: 68 61 6e 20 74 68 65 20 70 72 65 64 65 66 69 6e  han the predefin
0b40: 65 64 20 65 6e 74 69 74 69 65 73 20 61 6e 64 0a  ed entities and.
0b50: 63 68 61 72 61 63 74 65 72 20 72 65 66 65 72 65  character refere
0b60: 6e 63 65 73 2e 3c 2f 64 65 73 63 3e 0a 20 20 20  nces.</desc>.   
0b70: 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74             </opt
0b80: 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 20 20  def>..          
0b90: 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20      <optdef>.   
0ba0: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70               <op
0bb0: 74 6e 61 6d 65 3e 2d 68 74 6d 6c 3c 2f 6f 70 74  tname>-html</opt
0bc0: 6e 61 6d 65 3e 0a 20 20 20 20 20 20 20 20 20 20  name>.          
0bd0: 20 20 20 20 20 20 3c 64 65 73 63 3e 49 66 20 3c        <desc>If <
0be0: 6d 3e 2d 68 74 6d 6c 3c 2f 6d 3e 20 69 73 20 73  m>-html</m> is s
0bf0: 70 65 63 69 66 69 65 64 2c 20 61 20 66 61 73 74  pecified, a fast
0c00: 20 48 54 4d 4c 20 70 61 72 73 65 72 20 69 73 20   HTML parser is 
0c10: 0a 75 73 65 64 2c 20 77 68 69 63 68 20 74 72 69  .used, which tri
0c20: 65 73 20 74 6f 20 65 76 65 6e 20 70 61 72 73 65  es to even parse
0c30: 20 62 61 64 6c 79 20 66 6f 72 6d 65 64 20 48 54   badly formed HT
0c40: 4d 4c 20 69 6e 74 6f 20 61 20 44 4f 4d 20 74 72  ML into a DOM tr
0c50: 65 65 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20  ee.</desc>.     
0c60: 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65           </optde
0c70: 66 3e 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20  f>..            
0c80: 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20    <optdef>.     
0c90: 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e             <optn
0ca0: 61 6d 65 3e 2d 68 74 6d 6c 35 3c 2f 6f 70 74 6e  ame>-html5</optn
0cb0: 61 6d 65 3e 0a 20 20 20 20 20 20 20 20 20 20 20  ame>.           
0cc0: 20 20 20 20 20 3c 64 65 73 63 3e 54 68 69 73 20       <desc>This 
0cd0: 6f 70 74 69 6f 6e 20 69 73 20 6f 6e 6c 79 20 61  option is only a
0ce0: 76 61 69 6c 61 62 6c 65 20 69 66 20 74 44 4f 4d  vailable if tDOM
0cf0: 20 77 61 73 20 62 75 69 6c 64 0a 20 20 20 20 20   was build.     
0d00: 20 20 20 20 20 20 20 20 20 20 20 77 69 74 68 20             with 
0d10: 2d 2d 65 6e 61 62 6c 65 2d 68 74 6d 6c 35 2e 20  --enable-html5. 
0d20: 54 72 79 20 74 68 65 20 3c 6d 3e 66 65 61 74 75  Try the <m>featu
0d30: 72 65 69 6e 66 6f 3c 2f 6d 3e 20 6d 65 74 68 6f  reinfo</m> metho
0d40: 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  d.              
0d50: 20 20 69 66 20 79 6f 75 20 6e 65 65 64 20 74 6f    if you need to
0d60: 20 6b 6e 6f 77 20 69 66 20 74 68 69 73 20 66 65   know if this fe
0d70: 61 74 75 72 65 20 69 73 20 62 75 69 6c 64 20 69  ature is build i
0d80: 6e 2e 20 49 66 0a 20 20 20 20 20 20 20 20 20 20  n. If.          
0d90: 20 20 20 20 20 20 3c 6d 3e 2d 68 74 6d 6c 35 3c        <m>-html5<
0da0: 2f 6d 3e 20 69 73 20 73 70 65 63 69 66 69 65 64  /m> is specified
0db0: 2c 20 74 68 65 20 67 75 6d 62 6f 20 6c 69 62 20  , the gumbo lib 
0dc0: 68 74 6d 6c 35 20 70 61 72 73 65 72 0a 20 20 20  html5 parser.   
0dd0: 20 20 20 20 20 20 20 20 20 20 20 20 20 28 68 74               (ht
0de0: 74 70 73 3a 2f 2f 67 69 74 68 75 62 2e 63 6f 6d  tps://github.com
0df0: 2f 67 6f 6f 67 6c 65 2f 67 75 6d 62 6f 2d 70 61  /google/gumbo-pa
0e00: 72 73 65 72 29 20 69 73 20 75 73 65 64 20 74 6f  rser) is used to
0e10: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
0e20: 20 62 75 69 6c 64 20 74 68 65 20 44 4f 4d 20 74   build the DOM t
0e30: 72 65 65 2e 20 54 68 69 73 20 69 73 2c 20 61 73  ree. This is, as
0e40: 20 66 61 72 20 61 73 20 69 74 20 67 6f 65 73 2c   far as it goes,
0e50: 20 58 4d 4c 0a 20 20 20 20 20 20 20 20 20 20 20   XML.           
0e60: 20 20 20 20 20 6e 61 6d 65 73 70 61 63 65 2d 61       namespace-a
0e70: 77 61 72 65 2e 20 53 69 6e 63 65 20 74 68 69 73  ware. Since this
0e80: 20 70 72 6f 62 61 62 6c 79 20 69 73 6e 27 74 20   probably isn't 
0e90: 77 61 6e 74 65 64 20 62 79 20 61 0a 20 20 20 20  wanted by a.    
0ea0: 20 20 20 20 20 20 20 20 20 20 20 20 6c 6f 74 20              lot 
0eb0: 6f 66 20 75 73 65 72 73 20 61 6e 64 20 61 64 64  of users and add
0ec0: 73 20 6f 6e 6c 79 20 62 75 72 64 65 6e 20 66 6f  s only burden fo
0ed0: 72 20 6e 6f 20 67 6f 6f 64 20 69 6e 20 61 20 6c  r no good in a l
0ee0: 6f 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  ot.             
0ef0: 20 20 20 6f 66 20 75 73 65 20 63 61 73 65 73 20     of use cases 
0f00: 3c 6d 3e 2d 68 74 6d 6c 35 3c 2f 6d 3e 20 63 61  <m>-html5</m> ca
0f10: 6e 20 62 65 20 63 6f 6d 62 69 6e 65 64 20 77 69  n be combined wi
0f20: 74 68 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  th.             
0f30: 20 20 20 3c 6d 3e 2d 69 67 6e 6f 72 65 78 6d 6c     <m>-ignorexml
0f40: 6e 73 3c 2f 6d 3e 2c 20 69 6e 20 77 68 69 63 68  ns</m>, in which
0f50: 20 63 61 73 65 20 61 6c 6c 20 6e 6f 64 65 73 20   case all nodes 
0f60: 61 6e 64 0a 20 20 20 20 20 20 20 20 20 20 20 20  and.            
0f70: 20 20 20 20 61 74 74 72 69 62 75 74 65 73 20 69      attributes i
0f80: 6e 20 74 68 65 20 44 4f 4d 20 74 72 65 65 20 61  n the DOM tree a
0f90: 72 65 20 6e 6f 74 20 69 6e 20 61 6e 20 58 4d 4c  re not in an XML
0fa0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
0fb0: 20 6e 61 6d 65 73 70 61 63 65 2e 20 41 6c 6c 20   namespace. All 
0fc0: 74 61 67 20 61 6e 64 20 61 74 74 72 69 62 75 74  tag and attribut
0fd0: 65 20 6e 61 6d 65 73 20 69 6e 20 74 68 65 20 44  e names in the D
0fe0: 4f 4d 20 74 72 65 65 0a 20 20 20 20 20 20 20 20  OM tree.        
0ff0: 20 20 20 20 20 20 20 20 77 69 6c 6c 20 62 65 20          will be 
1000: 6c 6f 77 65 72 20 63 61 73 65 2c 20 65 76 65 6e  lower case, even
1010: 20 66 6f 72 20 66 6f 72 65 69 67 6e 20 65 6c 65   for foreign ele
1020: 6d 65 6e 74 73 20 6e 6f 74 20 69 6e 0a 20 20 20  ments not in.   
1030: 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 65               the
1040: 20 78 68 74 6d 6c 2c 20 73 76 67 20 6f 72 20 6d   xhtml, svg or m
1050: 61 74 68 6d 6c 20 6e 61 6d 65 73 70 61 63 65 2e  athml namespace.
1060: 20 54 68 65 20 44 4f 4d 20 74 72 65 65 20 6d 61   The DOM tree ma
1070: 79 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  y.              
1080: 20 20 69 6e 63 6c 75 64 65 20 6e 6f 64 65 73 2c    include nodes,
1090: 20 74 68 61 74 20 74 68 65 20 70 61 72 73 65 72   that the parser
10a0: 20 69 6e 73 65 72 74 65 64 20 62 65 63 61 75 73   inserted becaus
10b0: 65 20 74 68 65 79 0a 20 20 20 20 20 20 20 20 20  e they.         
10c0: 20 20 20 20 20 20 20 61 72 65 20 69 6d 70 6c 69         are impli
10d0: 65 64 20 62 79 20 74 68 65 20 63 6f 6e 74 65 78  ed by the contex
10e0: 74 20 28 61 73 20 26 6c 74 3b 68 65 61 64 26 67  t (as &lt;head&g
10f0: 74 3b 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20  t;,.            
1100: 20 20 20 20 26 6c 74 3b 74 62 6f 64 79 26 67 74      &lt;tbody&gt
1110: 3b 2c 20 65 74 63 2e 29 2e 3c 2f 64 65 73 63 3e  ;, etc.).</desc>
1120: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c  .              <
1130: 2f 6f 70 74 64 65 66 3e 0a 0a 20 20 20 20 20 20  /optdef>..      
1140: 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e          <optdef>
1150: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
1160: 20 3c 6f 70 74 6e 61 6d 65 3e 2d 6a 73 6f 6e 3c   <optname>-json<
1170: 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20 20  /optname>.      
1180: 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e            <desc>
1190: 49 66 20 3c 6d 3e 2d 6a 73 6f 6e 3c 2f 6d 3e 20  If <m>-json</m> 
11a0: 69 73 20 73 70 65 63 69 66 69 65 64 2c 20 74 68  is specified, th
11b0: 65 20 3c 6d 3e 64 61 74 61 3c 2f 6d 3e 20 69 73  e <m>data</m> is
11c0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
11d0: 20 65 78 70 65 63 74 65 64 20 74 6f 20 62 65 20   expected to be 
11e0: 61 20 76 61 6c 69 64 20 4a 53 4f 4e 20 73 74 72  a valid JSON str
11f0: 69 6e 67 20 28 61 63 63 6f 72 64 69 6e 67 20 74  ing (according t
1200: 6f 20 52 46 43 0a 20 20 20 20 20 20 20 20 20 20  o RFC.          
1210: 20 20 20 20 20 20 37 31 35 39 29 2e 20 54 68 65        7159). The
1220: 20 63 6f 6d 6d 61 6e 64 20 72 65 74 75 72 6e 73   command returns
1230: 20 61 6e 20 6f 72 64 69 6e 61 72 79 20 44 4f 4d   an ordinary DOM
1240: 20 64 6f 63 75 6d 65 6e 74 0a 20 20 20 20 20 20   document.      
1250: 20 20 20 20 20 20 20 20 20 20 77 69 74 68 20 6e            with n
1260: 65 73 74 69 6e 67 20 74 6f 6b 65 6e 20 69 6e 73  esting token ins
1270: 69 64 65 20 74 68 65 20 4a 53 4f 4e 20 64 61 74  ide the JSON dat
1280: 61 20 74 72 61 6e 73 6c 61 74 65 64 0a 20 20 20  a translated.   
1290: 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74               int
12a0: 6f 20 74 72 65 65 20 68 69 65 72 61 72 63 68 79  o tree hierarchy
12b0: 2e 20 49 66 20 61 20 4a 53 4f 4e 20 61 72 72 61  . If a JSON arra
12c0: 79 20 76 61 6c 75 65 20 69 73 20 69 74 73 65 6c  y value is itsel
12d0: 66 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  f.              
12e0: 20 20 61 6e 20 6f 62 6a 65 63 74 20 6f 72 20 61    an object or a
12f0: 72 72 61 79 20 74 68 65 6e 20 63 6f 6e 74 61 69  rray then contai
1300: 6e 65 72 20 65 6c 65 6d 65 6e 74 20 6e 6f 64 65  ner element node
1310: 73 20 6e 61 6d 65 64 0a 20 20 20 20 20 20 20 20  s named.        
1320: 20 20 20 20 20 20 20 20 28 69 6e 20 61 20 64 65          (in a de
1330: 66 61 75 6c 74 20 62 75 69 6c 64 29 20 61 72 72  fault build) arr
1340: 61 79 63 6f 6e 74 61 69 6e 65 72 20 6f 72 0a 20  aycontainer or. 
1350: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6f                 o
1360: 62 6a 65 63 74 63 6f 6e 74 61 69 6e 65 72 2c 20  bjectcontainer, 
1370: 72 65 73 70 65 63 74 69 76 65 6c 79 2c 20 61 72  respectively, ar
1380: 65 20 69 6e 73 65 72 74 65 64 20 69 6e 74 6f 20  e inserted into 
1390: 74 68 65 0a 20 20 20 20 20 20 20 20 20 20 20 20  the.            
13a0: 20 20 20 20 74 72 65 65 2e 20 54 68 65 20 4a 53      tree. The JS
13b0: 4f 4e 20 73 65 72 69 61 6c 69 7a 61 74 69 6f 6e  ON serialization
13c0: 20 6f 66 20 74 68 69 73 20 64 6f 63 75 6d 65 6e   of this documen
13d0: 74 20 28 77 69 74 68 0a 20 20 20 20 20 20 20 20  t (with.        
13e0: 20 20 20 20 20 20 20 20 74 68 65 20 64 6f 6d 44          the domD
13f0: 6f 63 20 6d 65 74 68 6f 64 20 3c 6d 3e 61 73 4a  oc method <m>asJ
1400: 53 4f 4e 3c 2f 6d 3e 29 20 69 73 20 74 68 65 20  SON</m>) is the 
1410: 73 61 6d 65 20 4a 53 4f 4e 0a 20 20 20 20 20 20  same JSON.      
1420: 20 20 20 20 20 20 20 20 20 20 69 6e 66 6f 72 6d            inform
1430: 61 74 69 6f 6e 20 61 73 20 74 68 65 20 3c 6d 3e  ation as the <m>
1440: 64 61 74 61 3c 2f 6d 3e 2c 20 70 72 65 73 65 72  data</m>, preser
1450: 76 69 6e 67 20 4a 53 4f 4e 0a 20 20 20 20 20 20  ving JSON.      
1460: 20 20 20 20 20 20 20 20 20 20 64 61 74 61 74 79            dataty
1470: 70 65 73 2c 20 61 6c 6c 6f 77 69 6e 67 20 6e 6f  pes, allowing no
1480: 6e 2d 75 6e 69 71 75 65 20 6d 65 6d 62 65 72 20  n-unique member 
1490: 6e 61 6d 65 73 20 6f 66 20 6f 62 6a 65 63 74 73  names of objects
14a0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
14b0: 20 77 68 69 6c 65 20 70 72 65 73 65 72 76 69 6e   while preservin
14c0: 67 20 74 68 65 69 72 20 6f 72 64 65 72 20 61 6e  g their order an
14d0: 64 20 74 68 65 20 66 75 6c 6c 20 72 61 6e 67 65  d the full range
14e0: 20 6f 66 0a 20 20 20 20 20 20 20 20 20 20 20 20   of.            
14f0: 20 20 20 20 4a 53 4f 4e 20 73 74 72 69 6e 67 20      JSON string 
1500: 76 61 6c 75 65 73 2e 20 4a 53 4f 4e 20 64 61 74  values. JSON dat
1510: 61 74 79 70 65 20 68 61 6e 64 6c 69 6e 67 20 69  atype handling i
1520: 73 20 64 6f 6e 65 0a 20 20 20 20 20 20 20 20 20  s done.         
1530: 20 20 20 20 20 20 20 77 69 74 68 20 61 6e 20 61         with an a
1540: 64 64 69 74 69 6f 6e 61 6c 20 70 72 6f 70 65 72  dditional proper
1550: 74 79 20 22 73 74 69 63 6b 69 6e 67 22 20 61 74  ty "sticking" at
1560: 20 74 68 65 20 64 6f 63 20 61 6e 64 0a 20 20 20   the doc and.   
1570: 20 20 20 20 20 20 20 20 20 20 20 20 20 74 72 65               tre
1580: 65 20 6e 6f 64 65 73 2e 20 54 68 69 73 20 70 72  e nodes. This pr
1590: 6f 70 65 72 74 79 20 69 73 6e 27 74 20 63 6f 6e  operty isn't con
15a0: 74 61 69 6e 65 64 20 69 6e 20 61 6e 20 58 4d 4c  tained in an XML
15b0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
15c0: 20 73 65 72 69 61 6c 69 7a 61 74 69 6f 6e 20 6f   serialization o
15d0: 66 20 74 68 65 20 64 6f 63 75 6d 65 6e 74 2e 20  f the document. 
15e0: 49 66 20 79 6f 75 20 6e 65 65 64 20 74 6f 20 73  If you need to s
15f0: 74 6f 72 65 0a 20 20 20 20 20 20 20 20 20 20 20  tore.           
1600: 20 20 20 20 20 74 68 65 20 4a 53 4f 4e 20 64 61       the JSON da
1610: 74 61 20 72 65 70 72 65 73 65 6e 74 65 64 20 62  ta represented b
1620: 79 20 61 20 64 6f 63 75 6d 65 6e 74 2c 20 73 74  y a document, st
1630: 6f 72 65 20 74 68 65 0a 20 20 20 20 20 20 20 20  ore the.        
1640: 20 20 20 20 20 20 20 20 4a 53 4f 4e 20 73 65 72          JSON ser
1650: 69 61 6c 69 7a 61 74 69 6f 6e 20 61 6e 64 20 70  ialization and p
1660: 61 72 73 65 20 69 74 20 62 61 63 6b 20 66 72 6f  arse it back fro
1670: 6d 20 74 68 65 72 65 2e 20 41 70 61 72 74 0a 20  m there. Apart. 
1680: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66                 f
1690: 72 6f 6d 20 74 68 69 73 20 4a 53 4f 4e 20 74 79  rom this JSON ty
16a0: 70 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 20 74  pe information t
16b0: 68 65 20 72 65 74 75 72 6e 65 64 20 64 6f 63 0a  he returned doc.
16c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
16d0: 63 6f 6d 6d 61 6e 64 20 6f 72 20 68 61 6e 64 6c  command or handl
16e0: 65 20 69 73 20 61 6e 20 6f 72 64 69 6e 61 72 79  e is an ordinary
16f0: 20 44 4f 4d 20 64 6f 63 2c 20 77 68 69 63 68 20   DOM doc, which 
1700: 6d 61 79 20 62 65 0a 20 20 20 20 20 20 20 20 20  may be.         
1710: 20 20 20 20 20 20 20 69 6e 76 65 73 74 69 67 61         investiga
1720: 74 65 64 20 6f 72 20 6d 6f 64 69 66 69 65 64 20  ted or modified 
1730: 77 69 74 68 20 74 68 65 20 66 75 6c 6c 20 72 61  with the full ra
1740: 6e 67 65 20 6f 66 20 74 68 65 0a 20 20 20 20 20  nge of the.     
1750: 20 20 20 20 20 20 20 20 20 20 20 64 6f 63 20 61             doc a
1760: 6e 64 20 6e 6f 64 65 20 6d 65 74 68 6f 64 73 2e  nd node methods.
1770: 20 50 6c 65 61 73 65 20 6e 6f 74 65 20 74 68 61   Please note tha
1780: 74 20 74 68 65 20 65 6c 65 6d 65 6e 74 0a 20 20  t the element.  
1790: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6e 6f                no
17a0: 64 65 20 6e 61 6d 65 73 20 61 6e 64 20 74 68 65  de names and the
17b0: 20 74 65 78 74 20 6e 6f 64 65 20 76 61 6c 75 65   text node value
17c0: 73 20 77 69 74 68 69 6e 20 74 68 65 20 74 72 65  s within the tre
17d0: 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  e.              
17e0: 20 20 6d 61 79 20 62 65 20 6f 75 74 73 69 64 65    may be outside
17f0: 20 6f 66 20 77 68 61 74 20 74 68 65 20 61 70 70   of what the app
1800: 72 6f 70 72 69 61 74 65 20 58 4d 4c 20 70 72 6f  ropriate XML pro
1810: 64 75 63 74 69 6f 6e 73 0a 20 20 20 20 20 20 20  ductions.       
1820: 20 20 20 20 20 20 20 20 20 61 6c 6c 6f 77 2e 3c           allow.<
1830: 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20 20  /desc>.         
1840: 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e 0a 0a       </optdef>..
1850: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f                <o
1860: 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20  ptdef>.         
1870: 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e         <optname>
1880: 2d 6a 73 6f 6e 6d 61 78 6e 65 73 74 69 6e 67 3c  -jsonmaxnesting<
1890: 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20 20  /optname>.      
18a0: 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 61 72            <optar
18b0: 67 3e 69 6e 74 65 67 65 72 3c 2f 6f 70 74 61 72  g>integer</optar
18c0: 67 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  g>.             
18d0: 20 20 20 3c 64 65 73 63 3e 54 68 69 73 20 6f 70     <desc>This op
18e0: 74 69 6f 6e 20 6f 6e 6c 79 20 68 61 73 20 65 66  tion only has ef
18f0: 66 65 63 74 20 69 66 20 75 73 65 64 20 74 6f 67  fect if used tog
1900: 65 74 68 65 72 0a 20 20 20 20 20 20 20 20 20 20  ether.          
1910: 20 20 20 20 20 20 77 69 74 68 20 74 68 65 20 3c        with the <
1920: 6d 3e 2d 6a 73 6f 6e 3c 2f 6d 3e 20 6f 70 74 69  m>-json</m> opti
1930: 6f 6e 2e 20 54 68 65 20 63 75 72 72 65 6e 74 20  on. The current 
1940: 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 75  implementation u
1950: 73 65 73 20 72 65 63 75 72 73 69 76 65 20 64 65  ses recursive de
1960: 73 63 65 6e 74 20 4a 53 4f 4e 20 70 61 72 73 65  scent JSON parse
1970: 72 2e 20 49 6e 20 6f 72 64 65 72 20 74 6f 20 61  r. In order to a
1980: 76 6f 69 64 20 75 73 69 6e 67 20 65 78 63 65 73  void using exces
1990: 73 20 73 74 61 63 6b 20 73 70 61 63 65 2c 20 61  s stack space, a
19a0: 6e 79 20 4a 53 4f 4e 20 69 6e 70 75 74 20 74 68  ny JSON input th
19b0: 61 74 20 68 61 73 20 6d 6f 72 65 20 74 68 61 6e  at has more than
19c0: 20 61 20 63 65 72 74 61 69 6e 20 6c 65 76 65 6c   a certain level
19d0: 73 20 6f 66 20 6e 65 73 74 69 6e 67 20 69 73 20  s of nesting is 
19e0: 63 6f 6e 73 69 64 65 72 65 64 20 69 6e 76 61 6c  considered inval
19f0: 69 64 2e 20 54 68 65 20 64 65 66 61 75 6c 74 20  id. The default 
1a00: 6d 61 78 69 6d 75 6d 20 6e 65 73 74 69 6e 67 20  maximum nesting 
1a10: 69 73 20 32 30 30 30 2e 20 54 68 65 20 6f 70 74  is 2000. The opt
1a20: 69 6f 6e 20 2d 6a 73 6f 6e 6d 61 78 6e 65 73 74  ion -jsonmaxnest
1a30: 69 6e 67 20 61 6c 6c 6f 77 73 20 74 68 65 20 75  ing allows the u
1a40: 73 65 72 20 74 6f 20 61 64 6a 75 73 74 20 74 68  ser to adjust th
1a50: 61 74 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20  at.</desc>.     
1a60: 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65           </optde
1a70: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  f>.             
1a80: 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20   .              
1a90: 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20  <optdef>.       
1aa0: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d           <optnam
1ab0: 65 3e 2d 2d 3c 2f 6f 70 74 6e 61 6d 65 3e 20 0a  e>--</optname> .
1ac0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
1ad0: 3c 64 65 73 63 3e 54 68 65 20 6f 70 74 69 6f 6e  <desc>The option
1ae0: 20 3c 6d 3e 2d 2d 3c 2f 6d 3e 20 6d 61 72 6b 73   <m>--</m> marks
1af0: 20 74 68 65 20 65 6e 64 20 6f 66 20 6f 70 74 69   the end of opti
1b00: 6f 6e 73 2e 0a 20 20 20 20 20 20 20 20 20 20 20  ons..           
1b10: 20 20 20 20 20 57 68 69 6c 65 20 72 65 73 70 65       While respe
1b20: 63 74 65 64 20 69 6e 20 67 65 6e 65 72 61 6c 20  cted in general 
1b30: 74 68 69 73 20 6f 70 74 69 6f 6e 20 69 73 20 6f  this option is o
1b40: 6e 6c 79 20 6e 65 65 64 65 64 0a 20 20 20 20 20  nly needed.     
1b50: 20 20 20 20 20 20 20 20 20 20 20 69 6e 20 63 61             in ca
1b60: 73 65 20 6f 66 20 70 61 72 73 69 6e 67 20 4a 53  se of parsing JS
1b70: 4f 4e 20 64 61 74 61 2c 20 77 68 69 63 68 20 6d  ON data, which m
1b80: 61 79 20 73 74 61 72 74 20 77 69 74 68 20 61 0a  ay start with a.
1b90: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
1ba0: 22 2d 22 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20  "-".</desc>.    
1bb0: 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74 64            </optd
1bc0: 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 20 20 20  ef>..           
1bd0: 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20     <optdef>.    
1be0: 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74              <opt
1bf0: 6e 61 6d 65 3e 2d 6b 65 65 70 45 6d 70 74 69 65  name>-keepEmptie
1c00: 73 3c 2f 6f 70 74 6e 61 6d 65 3e 20 0a 20 20 20  s</optname> .   
1c10: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 65               <de
1c20: 73 63 3e 49 66 20 3c 6d 3e 2d 6b 65 65 70 45 6d  sc>If <m>-keepEm
1c30: 70 74 69 65 73 3c 2f 6d 3e 20 69 73 0a 73 70 65  pties</m> is.spe
1c40: 63 69 66 69 65 64 20 74 68 65 6e 20 74 65 78 74  cified then text
1c50: 20 6e 6f 64 65 73 20 77 68 69 63 68 20 63 6f 6e   nodes which con
1c60: 74 61 69 6e 20 6f 6e 6c 79 20 77 68 69 74 65 73  tain only whites
1c70: 70 61 63 65 73 20 77 69 6c 6c 20 62 65 20 70 61  paces will be pa
1c80: 72 74 20 6f 66 20 74 68 65 0a 72 65 73 75 6c 74  rt of the.result
1c90: 69 6e 67 20 44 4f 4d 20 74 72 65 65 2e 20 49 6e  ing DOM tree. In
1ca0: 20 64 65 66 61 75 6c 74 20 63 61 73 65 20 28 3c   default case (<
1cb0: 6d 3e 2d 6b 65 65 70 45 6d 70 74 69 65 73 3c 2f  m>-keepEmpties</
1cc0: 6d 3e 20 6e 6f 74 20 67 69 76 65 6e 29 20 74 68  m> not given) th
1cd0: 6f 73 65 20 65 6d 70 74 79 0a 74 65 78 74 20 6e  ose empty.text n
1ce0: 6f 64 65 73 20 61 72 65 20 72 65 6d 6f 76 65 64  odes are removed
1cf0: 20 61 74 20 70 61 72 73 69 6e 67 20 74 69 6d 65   at parsing time
1d00: 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20  .</desc>.       
1d10: 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e         </optdef>
1d20: 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  ..              
1d30: 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20  <optdef>.       
1d40: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d           <optnam
1d50: 65 3e 2d 6b 65 65 70 43 44 41 54 41 3c 2f 6f 70  e>-keepCDATA</op
1d60: 74 6e 61 6d 65 3e 20 0a 20 20 20 20 20 20 20 20  tname> .        
1d70: 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 49 66          <desc>If
1d80: 20 3c 6d 3e 2d 6b 65 65 70 43 44 41 54 41 3c 2f   <m>-keepCDATA</
1d90: 6d 3e 20 69 73 0a 73 70 65 63 69 66 69 65 64 20  m> is.specified 
1da0: 74 68 65 6e 20 43 44 41 54 41 20 73 65 63 74 69  then CDATA secti
1db0: 6f 6e 73 20 61 72 65 6e 27 74 20 61 64 64 65 64  ons aren't added
1dc0: 20 74 6f 20 74 68 65 20 74 72 65 65 20 61 73 20   to the tree as 
1dd0: 74 65 78 74 20 6e 6f 64 65 73 0a 28 61 6e 64 2c  text nodes.(and,
1de0: 20 69 66 20 6e 65 63 65 73 73 61 72 79 2c 20 63   if necessary, c
1df0: 6f 6d 62 69 6e 65 64 20 77 69 74 68 20 73 69 62  ombined with sib
1e00: 6c 69 6e 67 20 74 65 78 74 20 6e 6f 64 65 73 20  ling text nodes 
1e10: 69 6e 74 6f 20 6f 6e 65 20 74 65 78 74 0a 6e 6f  into one text.no
1e20: 64 65 29 20 61 73 20 77 69 74 68 6f 75 74 20 74  de) as without t
1e30: 68 69 73 20 6f 70 74 69 6f 6e 20 62 75 74 20 61  his option but a
1e40: 72 65 20 61 64 64 65 64 20 61 73 20 43 44 41 54  re added as CDAT
1e50: 41 5f 53 45 43 54 49 4f 4e 5f 4e 4f 44 45 73 20  A_SECTION_NODEs 
1e60: 74 6f 0a 74 68 65 20 74 72 65 65 2e 20 50 6c 65  to.the tree. Ple
1e70: 61 73 65 20 6e 6f 74 65 20 74 68 61 74 20 74 68  ase note that th
1e80: 65 20 72 65 73 75 6c 74 69 6e 67 20 74 72 65 65  e resulting tree
1e90: 20 69 73 6e 27 74 20 70 72 65 70 61 72 65 64 20   isn't prepared 
1ea0: 66 6f 72 20 58 50 61 74 68 0a 73 65 6c 65 63 74  for XPath.select
1eb0: 73 20 6f 72 20 74 6f 20 62 65 20 74 68 65 20 73  s or to be the s
1ec0: 6f 75 72 63 65 20 6f 72 20 74 68 65 20 73 74 79  ource or the sty
1ed0: 6c 65 73 68 65 65 74 20 6f 66 20 61 6e 20 58 53  lesheet of an XS
1ee0: 4c 54 0a 74 72 61 6e 73 66 6f 72 6d 61 74 69 6f  LT.transformatio
1ef0: 6e 2e 20 49 66 20 6e 6f 74 20 63 6f 6d 62 69 6e  n. If not combin
1f00: 65 64 20 77 69 74 68 20 3c 6d 3e 2d 6b 65 65 70  ed with <m>-keep
1f10: 45 6d 70 74 69 65 73 3c 2f 6d 3e 20 6f 6e 6c 79  Empties</m> only
1f20: 20 6e 6f 74 0a 77 68 69 74 65 73 70 61 63 65 20   not.whitespace 
1f30: 6f 6e 6c 79 20 43 44 41 54 41 20 73 65 63 74 69  only CDATA secti
1f40: 6f 6e 73 20 77 69 6c 6c 20 62 65 20 61 64 64 65  ons will be adde
1f50: 64 20 74 6f 20 74 68 65 20 72 65 73 75 6c 74 69  d to the resulti
1f60: 6e 67 20 44 4f 4d 0a 20 20 20 20 20 20 20 20 20  ng DOM.         
1f70: 20 20 20 20 20 20 20 74 72 65 65 2e 3c 2f 64 65         tree.</de
1f80: 73 63 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20  sc>.            
1f90: 20 20 3c 2f 6f 70 74 64 65 66 3e 0a 20 20 20 20    </optdef>.    
1fa0: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20            .     
1fb0: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66           <optdef
1fc0: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
1fd0: 20 20 3c 6f 70 74 6e 61 6d 65 3e 2d 63 68 61 6e    <optname>-chan
1fe0: 6e 65 6c 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20  nel</optname>.  
1ff0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f                <o
2000: 70 74 61 72 67 3e 26 6c 74 3b 63 68 61 6e 6e 65  ptarg>&lt;channe
2010: 6c 2d 49 44 26 67 74 3b 3c 2f 6f 70 74 61 72 67  l-ID&gt;</optarg
2020: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
2030: 20 20 3c 64 65 73 63 3e 49 66 20 3c 6d 3e 2d 63    <desc>If <m>-c
2040: 68 61 6e 6e 65 6c 20 26 6c 74 3b 63 68 61 6e 6e  hannel &lt;chann
2050: 65 6c 2d 49 44 26 67 74 3b 3c 2f 6d 3e 20 69 73  el-ID&gt;</m> is
2060: 20 73 70 65 63 69 66 69 65 64 2c 20 74 68 65 0a   specified, the.
2070: 69 6e 70 75 74 20 74 6f 20 62 65 20 70 61 72 73  input to be pars
2080: 65 64 20 69 73 20 72 65 61 64 20 66 72 6f 6d 20  ed is read from 
2090: 74 68 65 20 73 70 65 63 69 66 69 65 64 20 63 68  the specified ch
20a0: 61 6e 6e 65 6c 2e 20 54 68 65 20 65 6e 63 6f 64  annel. The encod
20b0: 69 6e 67 20 73 65 74 74 69 6e 67 20 6f 66 0a 74  ing setting of.t
20c0: 68 65 20 63 68 61 6e 6e 65 6c 20 28 76 69 61 20  he channel (via 
20d0: 66 63 6f 6e 66 69 67 75 72 65 20 2d 65 6e 63 6f  fconfigure -enco
20e0: 64 69 6e 67 29 20 69 73 20 72 65 73 70 65 63 74  ding) is respect
20f0: 65 64 2c 20 69 65 20 74 68 65 20 64 61 74 61 20  ed, ie the data 
2100: 72 65 61 64 20 66 72 6f 6d 20 74 68 65 0a 63 68  read from the.ch
2110: 61 6e 6e 65 6c 20 61 72 65 20 63 6f 6e 76 65 72  annel are conver
2120: 74 65 64 20 74 6f 20 55 54 46 2d 38 20 61 63 63  ted to UTF-8 acc
2130: 6f 72 64 69 6e 67 20 74 6f 20 74 68 65 20 65 6e  ording to the en
2140: 63 6f 64 69 6e 67 20 73 65 74 74 69 6e 67 73 20  coding settings 
2150: 62 65 66 6f 72 65 20 74 68 65 0a 64 61 74 61 20  before the.data 
2160: 69 73 20 70 61 72 73 65 64 2e 3c 2f 64 65 73 63  is parsed.</desc
2170: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
2180: 3c 2f 6f 70 74 64 65 66 3e 0a 0a 20 20 20 20 20  </optdef>..     
2190: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66           <optdef
21a0: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
21b0: 20 20 3c 6f 70 74 6e 61 6d 65 3e 2d 62 61 73 65    <optname>-base
21c0: 75 72 6c 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20  url</optname>.  
21d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f                <o
21e0: 70 74 61 72 67 3e 26 6c 74 3b 62 61 73 65 55 52  ptarg>&lt;baseUR
21f0: 49 26 67 74 3b 3c 2f 6f 70 74 61 72 67 3e 0a 20  I&gt;</optarg>. 
2200: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
2210: 64 65 73 63 3e 49 66 20 3c 6d 3e 2d 62 61 73 65  desc>If <m>-base
2220: 75 72 6c 20 26 6c 74 3b 62 61 73 65 55 52 49 26  url &lt;baseURI&
2230: 67 74 3b 3c 2f 6d 3e 20 69 73 20 73 70 65 63 69  gt;</m> is speci
2240: 66 69 65 64 2c 0a 20 20 20 20 20 20 20 20 20 20  fied,.          
2250: 20 20 20 20 20 20 74 68 65 20 62 61 73 65 55 52        the baseUR
2260: 49 20 69 73 20 75 73 65 64 20 61 73 20 74 68 65  I is used as the
2270: 20 62 61 73 65 20 55 52 49 20 6f 66 20 74 68 65   base URI of the
2280: 20 64 6f 63 75 6d 65 6e 74 2e 0a 20 20 20 20 20   document..     
2290: 20 20 20 20 20 20 20 20 20 20 20 45 78 74 65 72             Exter
22a0: 6e 61 6c 20 65 6e 74 69 74 69 65 73 20 72 65 66  nal entities ref
22b0: 65 72 65 6e 63 65 73 20 69 6e 20 74 68 65 20 64  erences in the d
22c0: 6f 63 75 6d 65 6e 74 20 61 72 65 0a 20 20 20 20  ocument are.    
22d0: 20 20 20 20 20 20 20 20 20 20 20 20 72 65 73 6f              reso
22e0: 6c 76 65 64 20 72 65 6c 61 74 69 76 65 20 74 6f  lved relative to
22f0: 20 74 68 69 73 20 62 61 73 65 20 55 52 49 2e 20   this base URI. 
2300: 54 68 69 73 20 62 61 73 65 20 55 52 49 20 69 73  This base URI is
2310: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
2320: 20 61 6c 73 6f 20 73 74 6f 72 65 64 20 77 69 74   also stored wit
2330: 68 69 6e 20 74 68 65 20 44 4f 4d 20 74 72 65 65  hin the DOM tree
2340: 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20  .</desc>.       
2350: 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e         </optdef>
2360: 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  ..              
2370: 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20  <optdef>.       
2380: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d           <optnam
2390: 65 3e 2d 66 65 65 64 62 61 63 6b 41 66 74 65 72  e>-feedbackAfter
23a0: 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20  </optname>.     
23b0: 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 61             <opta
23c0: 72 67 3e 26 6c 74 3b 23 62 79 74 65 73 26 67 74  rg>&lt;#bytes&gt
23d0: 3b 3c 2f 6f 70 74 61 72 67 3e 0a 20 20 20 20 20  ;</optarg>.     
23e0: 20 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63             <desc
23f0: 3e 49 66 20 3c 6d 3e 2d 66 65 65 64 62 61 63 6b  >If <m>-feedback
2400: 41 66 74 65 72 20 26 6c 74 3b 23 62 79 74 65 73  After &lt;#bytes
2410: 26 67 74 3b 3c 2f 6d 3e 20 69 73 0a 20 20 20 20  &gt;</m> is.    
2420: 20 20 20 20 20 20 20 20 20 20 20 20 73 70 65 63              spec
2430: 69 66 69 65 64 2c 20 74 68 65 20 74 63 6c 20 63  ified, the tcl c
2440: 6f 6d 6d 61 6e 64 20 67 69 76 65 6e 20 62 79 0a  ommand given by.
2450: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
2460: 3c 6d 3e 2d 66 65 65 64 62 61 63 6b 63 6d 64 3c  <m>-feedbackcmd<
2470: 2f 6d 3e 20 69 73 20 65 76 61 6c 75 61 74 65 64  /m> is evaluated
2480: 20 61 74 20 74 68 65 20 66 69 72 73 74 20 65 6c   at the first el
2490: 65 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 20 20  ement.          
24a0: 20 20 20 20 20 20 73 74 61 72 74 20 77 69 74 68        start with
24b0: 69 6e 20 74 68 65 20 64 6f 63 75 6d 65 6e 74 20  in the document 
24c0: 28 6f 72 20 61 6e 20 65 78 74 65 72 6e 61 6c 20  (or an external 
24d0: 65 6e 74 69 74 79 29 0a 20 20 20 20 20 20 20 20  entity).        
24e0: 20 20 20 20 20 20 20 20 61 66 74 65 72 20 74 68          after th
24f0: 65 20 73 74 61 72 74 20 6f 66 20 74 68 65 20 64  e start of the d
2500: 6f 63 75 6d 65 6e 74 20 6f 72 20 65 78 74 65 72  ocument or exter
2510: 6e 61 6c 20 65 6e 74 69 74 79 20 6f 72 0a 20 20  nal entity or.  
2520: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68                th
2530: 65 20 6c 61 73 74 20 73 75 63 68 20 63 61 6c 6c  e last such call
2540: 20 61 66 74 65 72 20 23 62 79 74 65 73 2e 20 46   after #bytes. F
2550: 6f 72 20 62 61 63 6b 77 61 72 64 0a 20 20 20 20  or backward.    
2560: 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6d 70              comp
2570: 61 74 69 62 69 6c 69 74 79 20 69 66 20 6e 6f 20  atibility if no 
2580: 2d 66 65 65 64 62 61 63 6b 63 6d 64 20 69 73 20  -feedbackcmd is 
2590: 67 69 76 65 6e 20 62 75 74 20 74 68 65 72 65 20  given but there 
25a0: 69 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  is.             
25b0: 20 20 20 61 20 74 63 6c 20 70 72 6f 63 20 6e 61     a tcl proc na
25c0: 6d 65 64 20 3a 3a 64 6f 6d 3a 3a 64 6f 6d 50 61  med ::dom::domPa
25d0: 72 73 65 46 65 65 64 62 61 63 6b 20 74 68 69 73  rseFeedback this
25e0: 20 70 72 6f 63 20 69 73 0a 20 20 20 20 20 20 20   proc is.       
25f0: 20 20 20 20 20 20 20 20 20 75 73 65 64 20 61 73           used as
2600: 20 2d 66 65 65 64 62 61 63 6b 63 6d 64 2e 20 49   -feedbackcmd. I
2610: 66 20 74 68 65 72 65 20 69 73 6e 27 74 20 73 75  f there isn't su
2620: 63 68 20 61 20 70 72 6f 63 20 61 6e 64 0a 20 20  ch a proc and.  
2630: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 66                -f
2640: 65 65 64 62 61 63 6b 41 66 74 65 72 20 69 73 20  eedbackAfter is 
2650: 75 73 65 64 20 69 74 20 69 73 20 61 6e 20 65 72  used it is an er
2660: 72 6f 72 20 74 6f 20 6e 6f 74 20 61 6c 73 6f 20  ror to not also 
2670: 75 73 65 0a 20 20 20 20 20 20 20 20 20 20 20 20  use.            
2680: 20 20 20 20 2d 66 65 65 64 62 61 63 6b 63 6d 64      -feedbackcmd
2690: 2e 20 49 66 20 74 68 65 20 63 61 6c 6c 65 64 20  . If the called 
26a0: 73 63 72 69 70 74 20 72 61 69 73 65 73 20 65 72  script raises er
26b0: 72 6f 72 2c 20 74 68 65 6e 0a 20 20 20 20 20 20  ror, then.      
26c0: 20 20 20 20 20 20 20 20 20 20 70 61 72 73 69 6e            parsin
26d0: 67 20 77 69 6c 6c 20 62 65 20 61 62 6f 72 74 65  g will be aborte
26e0: 64 2c 20 74 68 65 20 3c 6d 3e 64 6f 6d 20 70 61  d, the <m>dom pa
26f0: 72 73 65 3c 2f 6d 3e 20 63 61 6c 6c 0a 20 20 20  rse</m> call.   
2700: 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74               ret
2710: 75 72 6e 73 20 65 72 72 6f 72 2c 20 77 69 74 68  urns error, with
2720: 20 74 68 65 20 73 63 72 69 70 74 20 65 72 72 6f   the script erro
2730: 72 20 6d 73 67 20 61 73 20 65 72 72 6f 72 20 6d  r msg as error m
2740: 73 67 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20  sg..            
2750: 20 20 20 20 49 66 20 74 68 65 20 63 61 6c 6c 65      If the calle
2760: 64 20 73 63 72 69 70 74 20 3c 6d 3e 72 65 74 75  d script <m>retu
2770: 72 6e 20 2d 63 6f 64 65 20 62 72 65 61 6b 3c 2f  rn -code break</
2780: 6d 3e 2c 20 74 68 65 0a 20 20 20 20 20 20 20 20  m>, the.        
2790: 20 20 20 20 20 20 20 20 70 61 72 73 69 6e 67 20          parsing 
27a0: 77 69 6c 6c 20 61 62 6f 72 74 20 61 6e 64 20 74  will abort and t
27b0: 68 65 20 3c 6d 3e 64 6f 6d 20 70 61 72 73 65 3c  he <m>dom parse<
27c0: 2f 6d 3e 20 63 61 6c 6c 20 77 69 6c 6c 0a 20 20  /m> call will.  
27d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65                re
27e0: 74 75 72 6e 20 74 68 65 20 65 6d 70 74 79 20 73  turn the empty s
27f0: 74 72 69 6e 67 2e 3c 2f 64 65 73 63 3e 0a 20 20  tring.</desc>.  
2800: 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70              </op
2810: 74 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 20  tdef>..         
2820: 20 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20       <optdef>.  
2830: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f                <o
2840: 70 74 6e 61 6d 65 3e 2d 66 65 65 64 62 61 63 6b  ptname>-feedback
2850: 63 6d 64 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20  cmd</optname>.  
2860: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f                <o
2870: 70 74 61 72 67 3e 26 6c 74 3b 73 63 72 69 70 74  ptarg>&lt;script
2880: 26 67 74 3b 3c 2f 6f 70 74 61 72 67 3e 0a 20 20  &gt;</optarg>.  
2890: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64                <d
28a0: 65 73 63 3e 49 66 20 3c 6d 3e 2d 66 65 65 64 62  esc>If <m>-feedb
28b0: 61 63 6b 63 6d 64 20 26 6c 74 3b 73 63 72 69 70  ackcmd &lt;scrip
28c0: 74 26 67 74 3b 3c 2f 6d 3e 20 69 73 20 73 70 65  t&gt;</m> is spe
28d0: 63 69 66 69 65 64 2c 20 74 68 65 0a 73 63 72 69  cified, the.scri
28e0: 70 74 20 3c 6d 3e 73 63 72 69 70 74 3c 2f 6d 3e  pt <m>script</m>
28f0: 20 69 73 20 65 76 61 6c 75 61 74 65 64 20 61 74   is evaluated at
2900: 20 74 68 65 20 66 69 72 73 74 0a 65 6c 65 6d 65   the first.eleme
2910: 6e 74 20 73 74 61 72 74 20 77 69 74 68 69 6e 20  nt start within 
2920: 74 68 65 20 64 6f 63 75 6d 65 6e 74 20 28 6f 72  the document (or
2930: 20 61 6e 20 65 78 74 65 72 6e 61 6c 20 65 6e 74   an external ent
2940: 69 74 79 29 20 61 66 74 65 72 20 74 68 65 0a 73  ity) after the.s
2950: 74 61 72 74 20 6f 66 20 74 68 65 20 64 6f 63 75  tart of the docu
2960: 6d 65 6e 74 20 6f 72 20 65 78 74 65 72 6e 61 6c  ment or external
2970: 20 65 6e 74 69 74 79 20 6f 72 20 74 68 65 20 6c   entity or the l
2980: 61 73 74 20 73 75 63 68 20 63 61 6c 6c 20 61 66  ast such call af
2990: 74 65 72 0a 23 62 79 74 65 73 20 76 61 6c 75 65  ter.#bytes value
29a0: 20 67 69 76 65 6e 20 62 79 20 74 68 65 20 3c 6d   given by the <m
29b0: 3e 2d 66 65 65 64 62 61 63 6b 41 66 74 65 72 3c  >-feedbackAfter<
29c0: 2f 6d 3e 20 6f 70 74 69 6f 6e 2e 20 49 66 0a 3c  /m> option. If.<
29d0: 6d 3e 2d 66 65 65 64 62 61 63 6b 41 66 74 65 72  m>-feedbackAfter
29e0: 3c 2f 6d 3e 20 69 73 6e 27 74 20 67 69 76 65 6e  </m> isn't given
29f0: 2c 20 75 73 69 6e 67 20 74 68 69 73 20 6f 70 74  , using this opt
2a00: 69 6f 6e 0a 64 6f 65 73 6e 27 74 20 68 61 73 20  ion.doesn't has 
2a10: 61 6e 79 20 65 66 66 65 63 74 2e 20 49 66 20 74  any effect. If t
2a20: 68 65 20 63 61 6c 6c 65 64 0a 73 63 72 69 70 74  he called.script
2a30: 20 72 61 69 73 65 73 20 65 72 72 6f 72 2c 20 74   raises error, t
2a40: 68 65 6e 20 70 61 72 73 69 6e 67 20 77 69 6c 6c  hen parsing will
2a50: 20 62 65 20 61 62 6f 72 74 65 64 2c 20 74 68 65   be aborted, the
2a60: 0a 3c 6d 3e 64 6f 6d 20 70 61 72 73 65 3c 2f 6d  .<m>dom parse</m
2a70: 3e 20 63 61 6c 6c 20 72 65 74 75 72 6e 73 20 65  > call returns e
2a80: 72 72 6f 72 2c 20 77 69 74 68 20 74 68 65 20 73  rror, with the s
2a90: 63 72 69 70 74 0a 65 72 72 6f 72 20 6d 73 67 20  cript.error msg 
2aa0: 61 73 20 65 72 72 6f 72 20 6d 73 67 2e 20 49 66  as error msg. If
2ab0: 20 74 68 65 20 63 61 6c 6c 65 64 20 73 63 72 69   the called scri
2ac0: 70 74 20 3c 6d 3e 72 65 74 75 72 6e 0a 2d 63 6f  pt <m>return.-co
2ad0: 64 65 20 62 72 65 61 6b 3c 2f 6d 3e 2c 20 74 68  de break</m>, th
2ae0: 65 20 70 61 72 73 69 6e 67 20 77 69 6c 6c 20 61  e parsing will a
2af0: 62 6f 72 74 20 61 6e 64 20 74 68 65 20 3c 6d 3e  bort and the <m>
2b00: 64 6f 6d 0a 70 61 72 73 65 3c 2f 6d 3e 20 63 61  dom.parse</m> ca
2b10: 6c 6c 20 77 69 6c 6c 20 72 65 74 75 72 6e 20 74  ll will return t
2b20: 68 65 20 65 6d 70 74 79 20 73 74 72 69 6e 67 2e  he empty string.
2b30: 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20  </desc>.        
2b40: 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e 0a        </optdef>.
2b50: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c  .              <
2b60: 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20  optdef>.        
2b70: 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65          <optname
2b80: 3e 2d 65 78 74 65 72 6e 61 6c 65 6e 74 69 74 79  >-externalentity
2b90: 63 6f 6d 6d 61 6e 64 3c 2f 6f 70 74 6e 61 6d 65  command</optname
2ba0: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
2bb0: 20 20 3c 6f 70 74 61 72 67 3e 26 6c 74 3b 73 63    <optarg>&lt;sc
2bc0: 72 69 70 74 26 67 74 3b 3c 2f 6f 70 74 61 72 67  ript&gt;</optarg
2bd0: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
2be0: 20 20 3c 64 65 73 63 3e 49 66 20 3c 6d 3e 2d 65    <desc>If <m>-e
2bf0: 78 74 65 72 6e 61 6c 65 6e 74 69 74 79 63 6f 6d  xternalentitycom
2c00: 6d 61 6e 64 20 26 6c 74 3b 73 63 72 69 70 74 26  mand &lt;script&
2c10: 67 74 3b 3c 2f 6d 3e 20 69 73 0a 73 70 65 63 69  gt;</m> is.speci
2c20: 66 69 65 64 2c 20 74 68 65 20 73 70 65 63 69 66  fied, the specif
2c30: 69 65 64 20 74 63 6c 20 73 63 72 69 70 74 20 69  ied tcl script i
2c40: 73 20 63 61 6c 6c 65 64 20 74 6f 20 72 65 73 6f  s called to reso
2c50: 6c 76 65 20 61 6e 79 20 65 78 74 65 72 6e 61 6c  lve any external
2c60: 20 65 6e 74 69 74 69 65 73 0a 6f 66 20 74 68 65   entities.of the
2c70: 20 64 6f 63 75 6d 65 6e 74 2e 20 54 68 65 20 61   document. The a
2c80: 63 74 75 61 6c 20 65 76 61 6c 75 61 74 65 64 20  ctual evaluated 
2c90: 63 6f 6d 6d 61 6e 64 20 63 6f 6e 73 69 73 74 73  command consists
2ca0: 20 6f 66 20 74 68 69 73 20 6f 70 74 69 6f 6e 20   of this option 
2cb0: 66 6f 6c 6c 6f 77 65 64 0a 62 79 20 74 68 72 65  followed.by thre
2cc0: 65 20 61 72 67 75 6d 65 6e 74 73 3a 20 74 68 65  e arguments: the
2cd0: 20 62 61 73 65 20 75 72 69 2c 20 74 68 65 20 73   base uri, the s
2ce0: 79 73 74 65 6d 20 69 64 65 6e 74 69 66 69 65 72  ystem identifier
2cf0: 20 6f 66 20 74 68 65 20 65 6e 74 69 74 79 20 61   of the entity a
2d00: 6e 64 20 74 68 65 0a 70 75 62 6c 69 63 20 69 64  nd the.public id
2d10: 65 6e 74 69 66 69 65 72 20 6f 66 20 74 68 65 20  entifier of the 
2d20: 65 6e 74 69 74 79 2e 20 54 68 65 20 62 61 73 65  entity. The base
2d30: 20 75 72 69 20 61 6e 64 20 74 68 65 20 70 75 62   uri and the pub
2d40: 6c 69 63 20 69 64 65 6e 74 69 66 69 65 72 20 6d  lic identifier m
2d50: 61 79 20 62 65 0a 74 68 65 20 65 6d 70 74 79 20  ay be.the empty 
2d60: 6c 69 73 74 2e 20 54 68 65 20 73 63 72 69 70 74  list. The script
2d70: 20 68 61 73 20 74 6f 20 72 65 74 75 72 6e 20 61   has to return a
2d80: 20 74 63 6c 20 6c 69 73 74 20 63 6f 6e 73 69 73   tcl list consis
2d90: 74 69 6e 67 20 6f 66 20 74 68 72 65 65 0a 65 6c  ting of three.el
2da0: 65 6d 65 6e 74 73 2e 20 54 68 65 20 66 69 72 73  ements. The firs
2db0: 74 20 65 6c 65 6d 65 6e 74 20 6f 66 20 74 68 69  t element of thi
2dc0: 73 20 6c 69 73 74 20 73 69 67 6e 61 6c 73 20 68  s list signals h
2dd0: 6f 77 20 74 68 65 20 65 78 74 65 72 6e 61 6c 20  ow the external 
2de0: 65 6e 74 69 74 79 20 69 73 0a 72 65 74 75 72 6e  entity is.return
2df0: 65 64 20 74 6f 20 74 68 65 20 70 72 6f 63 65 73  ed to the proces
2e00: 73 6f 72 2e 20 43 75 72 72 65 6e 74 6c 79 20 74  sor. Currently t
2e10: 68 65 20 74 77 6f 20 61 6c 6c 6f 77 65 64 20 74  he two allowed t
2e20: 79 70 65 73 20 61 72 65 20 22 73 74 72 69 6e 67  ypes are "string
2e30: 22 0a 61 6e 64 20 22 63 68 61 6e 6e 65 6c 22 2e  ".and "channel".
2e40: 20 54 68 65 20 73 65 63 6f 6e 64 20 65 6c 65 6d   The second elem
2e50: 65 6e 74 20 6f 66 20 74 68 65 20 6c 69 73 74 20  ent of the list 
2e60: 68 61 73 20 74 6f 20 62 65 20 74 68 65 20 28 61  has to be the (a
2e70: 62 73 6f 6c 75 74 65 29 20 62 61 73 65 20 55 52  bsolute) base UR
2e80: 49 0a 6f 66 20 74 68 65 20 65 78 74 65 72 6e 61  I.of the externa
2e90: 6c 20 65 6e 74 69 74 79 20 74 6f 20 62 65 20 70  l entity to be p
2ea0: 61 72 73 65 64 2e 20 20 54 68 65 20 74 68 69 72  arsed.  The thir
2eb0: 64 20 65 6c 65 6d 65 6e 74 20 6f 66 20 74 68 65  d element of the
2ec0: 20 6c 69 73 74 20 61 72 65 20 64 61 74 61 2c 0a   list are data,.
2ed0: 65 69 74 68 65 72 20 74 68 65 20 61 6c 72 65 61  either the alrea
2ee0: 64 79 20 72 65 61 64 20 64 61 74 61 20 6f 75 74  dy read data out
2ef0: 20 6f 66 20 74 68 65 20 65 78 74 65 72 6e 61 6c   of the external
2f00: 20 65 6e 74 69 74 79 20 61 73 20 73 74 72 69 6e   entity as strin
2f10: 67 20 69 6e 20 74 68 65 20 63 61 73 65 0a 6f 66  g in the case.of
2f20: 20 74 79 70 65 20 22 73 74 72 69 6e 67 22 2c 20   type "string", 
2f30: 6f 72 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 61  or the name of a
2f40: 20 74 63 6c 20 63 68 61 6e 6e 65 6c 2c 20 69 6e   tcl channel, in
2f50: 20 74 68 65 20 63 61 73 65 20 6f 66 20 74 79 70   the case of typ
2f60: 65 0a 22 63 68 61 6e 6e 65 6c 22 2e 20 4e 6f 74  e."channel". Not
2f70: 65 20 74 68 61 74 20 69 66 20 74 68 65 20 73 63  e that if the sc
2f80: 72 69 70 74 20 72 65 74 75 72 6e 73 20 61 20 74  ript returns a t
2f90: 63 6c 20 63 68 61 6e 6e 65 6c 2c 20 69 74 20 77  cl channel, it w
2fa0: 69 6c 6c 20 6e 6f 74 20 62 65 20 63 6c 6f 73 65  ill not be close
2fb0: 64 0a 62 79 20 74 68 65 20 70 72 6f 63 65 73 73  d.by the process
2fc0: 6f 72 2e 20 20 49 74 20 6d 75 73 74 20 62 65 20  or.  It must be 
2fd0: 63 6c 6f 73 65 64 20 73 65 70 61 72 61 74 65 6c  closed separatel
2fe0: 79 20 69 66 20 69 74 20 69 73 20 6e 6f 20 6c 6f  y if it is no lo
2ff0: 6e 67 65 72 0a 6e 65 65 64 65 64 2e 3c 2f 64 65  nger.needed.</de
3000: 73 63 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20  sc>.            
3010: 20 20 3c 2f 6f 70 74 64 65 66 3e 0a 0a 20 20 20    </optdef>..   
3020: 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 64             <optd
3030: 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20  ef>.            
3040: 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 2d 75 73      <optname>-us
3050: 65 46 6f 72 65 69 67 6e 44 54 44 3c 2f 6f 70 74  eForeignDTD</opt
3060: 6e 61 6d 65 3e 0a 20 20 20 20 20 20 20 20 20 20  name>.          
3070: 20 20 20 20 20 20 3c 6f 70 74 61 72 67 3e 26 6c        <optarg>&l
3080: 74 3b 62 6f 6f 6c 65 61 6e 26 67 74 3b 3c 2f 6f  t;boolean&gt;</o
3090: 70 74 61 72 67 3e 0a 20 20 20 20 20 20 20 20 20  ptarg>.         
30a0: 20 20 20 20 20 20 20 3c 64 65 73 63 3e 49 66 20         <desc>If 
30b0: 26 6c 74 3b 62 6f 6f 6c 65 61 6e 26 67 74 3b 20  &lt;boolean&gt; 
30c0: 69 73 20 74 72 75 65 20 61 6e 64 20 74 68 65 20  is true and the 
30d0: 64 6f 63 75 6d 65 6e 74 20 64 6f 65 73 20 6e 6f  document does no
30e0: 74 20 68 61 76 65 0a 61 6e 20 65 78 74 65 72 6e  t have.an extern
30f0: 61 6c 20 73 75 62 73 65 74 2c 20 74 68 65 20 70  al subset, the p
3100: 61 72 73 65 72 20 77 69 6c 6c 20 63 61 6c 6c 20  arser will call 
3110: 74 68 65 20 2d 65 78 74 65 72 6e 61 6c 65 6e 74  the -externalent
3120: 69 74 79 63 6f 6d 6d 61 6e 64 20 73 63 72 69 70  itycommand scrip
3130: 74 20 77 69 74 68 0a 65 6d 70 74 79 20 76 61 6c  t with.empty val
3140: 75 65 73 20 66 6f 72 20 74 68 65 20 73 79 73 74  ues for the syst
3150: 65 6d 49 64 20 61 6e 64 20 70 75 62 6c 69 63 49  emId and publicI
3160: 44 20 61 72 67 75 6d 65 6e 74 73 2e 20 50 6c 65  D arguments. Ple
3170: 61 73 65 20 6e 6f 74 65 20 74 68 61 74 20 69 66  ase note that if
3180: 0a 74 68 65 20 64 6f 63 75 6d 65 6e 74 20 61 6c  .the document al
3190: 73 6f 20 64 6f 65 73 6e 27 74 20 68 61 76 65 20  so doesn't have 
31a0: 61 6e 20 69 6e 74 65 72 6e 61 6c 20 73 75 62 73  an internal subs
31b0: 65 74 2c 20 74 68 65 0a 2d 73 74 61 72 74 64 6f  et, the.-startdo
31c0: 63 74 79 70 65 64 65 63 6c 63 6f 6d 6d 61 6e 64  ctypedeclcommand
31d0: 20 61 6e 64 20 2d 65 6e 64 64 6f 63 74 79 70 65   and -enddoctype
31e0: 64 65 63 6c 63 6f 6d 6d 61 6e 64 20 73 63 72 69  declcommand scri
31f0: 70 74 73 2c 20 69 66 20 73 65 74 2c 20 61 72 65  pts, if set, are
3200: 20 6e 6f 74 0a 63 61 6c 6c 65 64 2e 20 54 68 65   not.called. The
3210: 20 3c 6d 3e 2d 75 73 65 46 6f 72 65 69 67 6e 44   <m>-useForeignD
3220: 54 44 3c 2f 6d 3e 20 72 65 73 70 65 63 74 73 20  TD</m> respects 
3230: 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20  </desc>.        
3240: 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e 0a        </optdef>.
3250: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c  .              <
3260: 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20  optdef>.        
3270: 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65          <optname
3280: 3e 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61 72  >-paramentitypar
3290: 73 69 6e 67 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20  sing</optname>. 
32a0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
32b0: 6f 70 74 61 72 67 3e 26 6c 74 3b 61 6c 77 61 79  optarg>&lt;alway
32c0: 73 7c 6e 65 76 65 72 7c 6e 6f 74 73 74 61 6e 64  s|never|notstand
32d0: 61 6c 6f 6e 65 26 67 74 3b 3c 2f 6f 70 74 61 72  alone&gt;</optar
32e0: 67 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  g>.             
32f0: 20 20 20 3c 64 65 73 63 3e 54 68 65 20 3c 6d 3e     <desc>The <m>
3300: 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61 72 73  -paramentitypars
3310: 69 6e 67 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 63  ing</m> option c
3320: 6f 6e 74 72 6f 6c 73 2c 0a 20 20 20 20 20 20 20  ontrols,.       
3330: 20 20 20 20 20 20 20 20 20 69 66 20 74 68 65 20           if the 
3340: 70 61 72 73 65 72 20 74 72 69 65 73 20 74 6f 20  parser tries to 
3350: 72 65 73 6f 6c 76 65 20 74 68 65 20 65 78 74 65  resolve the exte
3360: 72 6e 61 6c 20 65 6e 74 69 74 69 65 73 0a 20 20  rnal entities.  
3370: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 69                (i
3380: 6e 63 6c 75 64 69 6e 67 20 74 68 65 20 65 78 74  ncluding the ext
3390: 65 72 6e 61 6c 20 44 54 44 20 73 75 62 73 65 74  ernal DTD subset
33a0: 29 20 6f 66 20 74 68 65 20 64 6f 63 75 6d 65 6e  ) of the documen
33b0: 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  t.              
33c0: 20 20 77 68 69 6c 65 20 62 75 69 6c 64 69 6e 67    while building
33d0: 20 74 68 65 20 44 4f 4d 20 74 72 65 65 2e 0a 20   the DOM tree.. 
33e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
33f0: 6d 3e 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61  m>-paramentitypa
3400: 72 73 69 6e 67 3c 2f 6d 3e 20 72 65 71 75 69 72  rsing</m> requir
3410: 65 73 20 61 6e 20 61 72 67 75 6d 65 6e 74 2c 20  es an argument, 
3420: 77 68 69 63 68 0a 20 20 20 20 20 20 20 20 20 20  which.          
3430: 20 20 20 20 20 20 6d 75 73 74 20 62 65 20 65 69        must be ei
3440: 74 68 65 72 20 22 61 6c 77 61 79 73 22 2c 20 22  ther "always", "
3450: 6e 65 76 65 72 22 2c 20 6f 72 20 22 6e 6f 74 73  never", or "nots
3460: 74 61 6e 64 61 6c 6f 6e 65 22 2e 0a 20 20 20 20  tandalone"..    
3470: 20 20 20 20 20 20 20 20 20 20 20 20 54 68 65 20              The 
3480: 76 61 6c 75 65 20 22 61 6c 77 61 79 73 22 20 6d  value "always" m
3490: 65 61 6e 73 20 74 68 61 74 20 74 68 65 20 70 61  eans that the pa
34a0: 72 73 65 72 20 74 72 69 65 73 20 74 6f 0a 20 20  rser tries to.  
34b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65                re
34c0: 73 6f 6c 76 65 73 20 28 72 65 63 75 72 73 69 76  solves (recursiv
34d0: 65 6c 79 29 20 61 6c 6c 20 65 78 74 65 72 6e 61  ely) all externa
34e0: 6c 20 65 6e 74 69 74 69 65 73 20 6f 66 20 74 68  l entities of th
34f0: 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  e.              
3500: 20 20 58 4d 4c 20 73 6f 75 72 63 65 2e 20 54 68    XML source. Th
3510: 69 73 20 69 73 20 74 68 65 20 64 65 66 61 75 6c  is is the defaul
3520: 74 20 69 6e 20 63 61 73 65 0a 20 20 20 20 20 20  t in case.      
3530: 20 20 20 20 20 20 20 20 20 20 3c 6d 3e 2d 70 61            <m>-pa
3540: 72 61 6d 65 6e 74 69 74 79 70 61 72 73 69 6e 67  ramentityparsing
3550: 3c 2f 6d 3e 20 69 73 20 6f 6d 69 74 74 65 64 2e  </m> is omitted.
3560: 20 54 68 65 20 76 61 6c 75 65 0a 20 20 20 20 20   The value.     
3570: 20 20 20 20 20 20 20 20 20 20 20 22 6e 65 76 65             "neve
3580: 72 22 20 6d 65 61 6e 73 20 74 68 61 74 20 6f 6e  r" means that on
3590: 6c 79 20 74 68 65 20 67 69 76 65 6e 20 58 4d 4c  ly the given XML
35a0: 20 73 6f 75 72 63 65 20 69 73 0a 20 20 20 20 20   source is.     
35b0: 20 20 20 20 20 20 20 20 20 20 20 70 61 72 73 65             parse
35c0: 64 20 61 6e 64 20 6e 6f 20 65 78 74 65 72 6e 61  d and no externa
35d0: 6c 20 65 6e 74 69 74 79 20 28 69 6e 63 6c 75 64  l entity (includ
35e0: 69 6e 67 20 74 68 65 20 65 78 74 65 72 6e 61 6c  ing the external
35f0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
3600: 20 73 75 62 73 65 74 29 20 77 69 6c 6c 20 62 65   subset) will be
3610: 20 72 65 73 6f 6c 76 65 64 20 61 6e 64 20 70 61   resolved and pa
3620: 72 73 65 64 2e 20 54 68 65 20 76 61 6c 75 65 0a  rsed. The value.
3630: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
3640: 22 6e 6f 74 73 74 61 6e 64 61 6c 6f 6e 65 22 20  "notstandalone" 
3650: 6d 65 61 6e 73 2c 20 74 68 61 74 20 61 6c 6c 20  means, that all 
3660: 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 69 65  external entitie
3670: 73 20 77 69 6c 6c 0a 20 20 20 20 20 20 20 20 20  s will.         
3680: 20 20 20 20 20 20 20 62 65 20 72 65 73 6f 6c 76         be resolv
3690: 65 64 20 61 6e 64 20 70 61 72 73 65 64 2c 20 77  ed and parsed, w
36a0: 69 74 68 20 74 68 65 20 65 78 63 65 70 74 69 6f  ith the exceptio
36b0: 6e 20 6f 66 0a 20 20 20 20 20 20 20 20 20 20 20  n of.           
36c0: 20 20 20 20 20 64 6f 63 75 6d 65 6e 74 73 2c 20       documents, 
36d0: 77 68 69 63 68 20 65 78 70 6c 69 63 69 74 6c 79  which explicitly
36e0: 20 73 74 61 74 65 73 20 73 74 61 6e 64 61 6c 6f   states standalo
36f0: 6e 65 3d 22 79 65 73 22 20 69 6e 0a 20 20 20 20  ne="yes" in.    
3700: 20 20 20 20 20 20 20 20 20 20 20 20 74 68 65 69              thei
3710: 72 20 58 4d 4c 20 64 65 63 6c 61 72 61 74 69 6f  r XML declaratio
3720: 6e 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20  n.</desc>.      
3730: 20 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66          </optdef
3740: 3e 0a 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20  >...            
3750: 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20    <optdef>.     
3760: 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e             <optn
3770: 61 6d 65 3e 2d 69 67 6e 6f 72 65 78 6d 6c 6e 73  ame>-ignorexmlns
3780: 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20  </optname>.     
3790: 20 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63             <desc
37a0: 3e 49 74 20 69 73 20 72 65 63 6f 6d 6d 65 6e 64  >It is recommend
37b0: 65 64 2c 20 74 68 61 74 20 79 6f 75 20 6f 6e 6c  ed, that you onl
37c0: 79 20 75 73 65 20 74 68 69 73 20 6f 70 74 69 6f  y use this optio
37d0: 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  n.              
37e0: 20 20 77 69 74 68 20 74 68 65 20 3c 6d 3e 2d 68    with the <m>-h
37f0: 74 6d 6c 35 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 2e  tml5</m> option.
3800: 20 49 66 20 74 68 69 73 20 6f 70 74 69 6f 6e 20   If this option 
3810: 69 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  is.             
3820: 20 20 20 67 69 76 65 6e 2c 20 6e 6f 20 6e 6f 64     given, no nod
3830: 65 20 77 69 74 68 69 6e 20 74 68 65 20 63 72 65  e within the cre
3840: 61 74 65 64 20 44 4f 4d 20 74 72 65 65 20 77 69  ated DOM tree wi
3850: 6c 6c 20 62 65 0a 20 20 20 20 20 20 20 20 20 20  ll be.          
3860: 20 20 20 20 20 20 69 6e 74 65 72 6e 61 6c 6c 79        internally
3870: 20 6d 61 72 6b 65 64 20 61 73 20 70 6c 61 63 65   marked as place
3880: 64 20 69 6e 74 6f 20 61 6e 20 58 4d 4c 20 4e 61  d into an XML Na
3890: 6d 65 73 70 61 63 65 2c 0a 20 20 20 20 20 20 20  mespace,.       
38a0: 20 20 20 20 20 20 20 20 20 65 76 65 6e 20 69 66           even if
38b0: 20 74 68 65 72 65 20 69 73 20 61 20 64 65 66 61   there is a defa
38c0: 75 6c 74 20 6e 61 6d 65 73 70 61 63 65 20 69 6e  ult namespace in
38d0: 20 73 63 6f 70 65 20 66 6f 72 0a 20 20 20 20 20   scope for.     
38e0: 20 20 20 20 20 20 20 20 20 20 20 75 6e 2d 70 72             un-pr
38f0: 65 66 69 78 65 64 20 65 6c 65 6d 65 6e 74 73 20  efixed elements 
3900: 6f 72 20 65 76 65 6e 20 69 66 20 74 68 65 20 65  or even if the e
3910: 6c 65 6d 65 6e 74 20 68 61 73 20 61 0a 20 20 20  lement has a.   
3920: 20 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66               def
3930: 69 6e 65 64 20 6e 61 6d 65 73 70 61 63 65 20 70  ined namespace p
3940: 72 65 66 69 78 2e 20 4f 6e 65 20 63 6f 6e 73 65  refix. One conse
3950: 71 75 65 6e 63 65 20 69 73 20 74 68 61 74 0a 20  quence is that. 
3960: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 58                 X
3970: 50 61 74 68 20 6e 6f 64 65 20 65 78 70 72 65 73  Path node expres
3980: 73 69 6f 6e 73 20 6f 6e 20 73 75 63 68 20 61 20  sions on such a 
3990: 44 4f 4d 20 74 72 65 65 20 64 6f 65 73 6e 27 74  DOM tree doesn't
39a0: 20 77 6f 72 6b 0a 20 20 20 20 20 20 20 20 20 20   work.          
39b0: 20 20 20 20 20 20 61 73 20 65 78 70 65 63 74 65        as expecte
39c0: 64 2e 20 50 72 65 66 69 78 65 64 20 65 6c 65 6d  d. Prefixed elem
39d0: 65 6e 74 20 6e 6f 64 65 73 20 63 61 6e 27 74 20  ent nodes can't 
39e0: 62 65 20 73 65 6c 65 63 74 65 64 0a 20 20 20 20  be selected.    
39f0: 20 20 20 20 20 20 20 20 20 20 20 20 61 6e 64 20              and 
3a00: 65 6c 65 6d 65 6e 74 20 6e 6f 64 65 73 20 77 69  element nodes wi
3a10: 74 68 6f 75 74 20 70 72 65 66 69 78 20 77 69 6c  thout prefix wil
3a20: 6c 20 62 65 20 73 65 65 6e 20 62 79 20 58 50 61  l be seen by XPa
3a30: 74 68 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  th.             
3a40: 20 20 20 65 78 70 72 65 73 73 69 6f 6e 73 20 61     expressions a
3a50: 73 20 69 66 20 74 68 65 79 20 61 72 65 20 6e 6f  s if they are no
3a60: 74 20 69 6e 20 61 6e 79 20 6e 61 6d 65 73 70 61  t in any namespa
3a70: 63 65 20 28 6e 6f 0a 20 20 20 20 20 20 20 20 20  ce (no.         
3a80: 20 20 20 20 20 20 20 6d 61 74 74 65 72 20 69 66         matter if
3a90: 20 74 68 65 79 20 61 72 65 20 69 6e 20 66 61 63   they are in fac
3aa0: 74 20 73 68 6f 75 6c 64 20 62 65 20 69 6e 20 61  t should be in a
3ab0: 20 64 65 66 61 75 6c 74 0a 20 20 20 20 20 20 20   default.       
3ac0: 20 20 20 20 20 20 20 20 20 6e 61 6d 65 73 70 61           namespa
3ad0: 63 65 29 2e 0a 20 20 20 20 20 20 20 20 20 20 20  ce)..           
3ae0: 20 20 20 20 20 3c 2f 64 65 73 63 3e 0a 20 20 20       </desc>.   
3af0: 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74             </opt
3b00: 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 20 20  def>..          
3b10: 20 20 3c 2f 6f 70 74 6c 69 73 74 3e 0a 3c 70 2f    </optlist>.<p/
3b20: 3e 0a 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20  >.</desc>.      
3b30: 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a    </commanddef>.
3b40: 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e  .        <comman
3b50: 64 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20  ddef>.          
3b60: 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f  <command><cmd>do
3b70: 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e  m</cmd> <method>
3b80: 63 72 65 61 74 65 44 6f 63 75 6d 65 6e 74 3c 2f  createDocument</
3b90: 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 64 6f 63 45 6c  method>.<m>docEl
3ba0: 65 6d 4e 61 6d 65 3c 2f 6d 3e 20 3f 3c 6d 3e 6f  emName</m> ?<m>o
3bb0: 62 6a 56 61 72 3c 2f 6d 3e 3f 3c 2f 63 6f 6d 6d  bjVar</m>?</comm
3bc0: 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20 20 3c  and>.          <
3bd0: 64 65 73 63 3e 43 72 65 61 74 65 73 20 61 20 6e  desc>Creates a n
3be0: 65 77 20 44 4f 4d 20 64 6f 63 75 6d 65 6e 74 20  ew DOM document 
3bf0: 6f 62 6a 65 63 74 20 77 69 74 68 20 6f 6e 65 20  object with one 
3c00: 65 6c 65 6d 65 6e 74 20 6e 6f 64 65 20 77 69 74  element node wit
3c10: 68 0a 6e 6f 64 65 20 6e 61 6d 65 20 3c 6d 3e 64  h.node name <m>d
3c20: 6f 63 45 6c 65 6d 4e 61 6d 65 3c 2f 6d 3e 2e 20  ocElemName</m>. 
3c30: 54 68 65 20 3c 6d 3e 6f 62 6a 56 61 72 3c 2f 6d  The <m>objVar</m
3c40: 3e 20 63 6f 6e 74 72 6f 6c 73 20 74 68 65 0a 6d  > controls the.m
3c50: 65 6d 6f 72 79 20 68 61 6e 64 6c 69 6e 67 20 61  emory handling a
3c60: 73 20 65 78 70 6c 61 69 6e 65 64 20 61 62 6f 76  s explained abov
3c70: 65 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20  e.</desc>.      
3c80: 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a    </commanddef>.
3c90: 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e  .        <comman
3ca0: 64 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20  ddef>.          
3cb0: 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f  <command><cmd>do
3cc0: 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e  m</cmd> <method>
3cd0: 63 72 65 61 74 65 44 6f 63 75 6d 65 6e 74 4e 53  createDocumentNS
3ce0: 3c 2f 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 75 72 69  </method>.<m>uri
3cf0: 3c 2f 6d 3e 20 3c 6d 3e 64 6f 63 45 6c 65 6d 4e  </m> <m>docElemN
3d00: 61 6d 65 3c 2f 6d 3e 20 3f 3c 6d 3e 6f 62 6a 56  ame</m> ?<m>objV
3d10: 61 72 3c 2f 6d 3e 3f 3c 2f 63 6f 6d 6d 61 6e 64  ar</m>?</command
3d20: 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 65 73  >.          <des
3d30: 63 3e 43 72 65 61 74 65 73 20 61 20 6e 65 77 20  c>Creates a new 
3d40: 44 4f 4d 20 64 6f 63 75 6d 65 6e 74 20 6f 62 6a  DOM document obj
3d50: 65 63 74 20 77 69 74 68 20 6f 6e 65 20 65 6c 65  ect with one ele
3d60: 6d 65 6e 74 20 6e 6f 64 65 20 77 69 74 68 0a 6e  ment node with.n
3d70: 6f 64 65 20 6e 61 6d 65 20 3c 6d 3e 64 6f 63 45  ode name <m>docE
3d80: 6c 65 6d 4e 61 6d 65 3c 2f 6d 3e 2e 20 3c 6d 3e  lemName</m>. <m>
3d90: 55 72 69 3c 2f 6d 3e 20 67 69 76 65 73 20 74 68  Uri</m> gives th
3da0: 65 20 6e 61 6d 65 73 70 61 63 65 20 6f 66 20 74  e namespace of t
3db0: 68 65 0a 64 6f 63 75 6d 65 6e 74 20 65 6c 65 6d  he.document elem
3dc0: 65 6e 74 20 74 6f 20 63 72 65 61 74 65 2e 20 54  ent to create. T
3dd0: 68 65 20 3c 6d 3e 6f 62 6a 56 61 72 3c 2f 6d 3e  he <m>objVar</m>
3de0: 20 63 6f 6e 74 72 6f 6c 73 20 74 68 65 0a 6d 65   controls the.me
3df0: 6d 6f 72 79 20 68 61 6e 64 6c 69 6e 67 20 61 73  mory handling as
3e00: 20 65 78 70 6c 61 69 6e 65 64 20 61 62 6f 76 65   explained above
3e10: 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20  .</desc>.       
3e20: 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 0a   </commanddef>..
3e30: 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64          <command
3e40: 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 3c  def>.          <
3e50: 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d  command><cmd>dom
3e60: 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 63  </cmd> <method>c
3e70: 72 65 61 74 65 44 6f 63 75 6d 65 6e 74 4e 6f 64  reateDocumentNod
3e80: 65 3c 2f 6d 65 74 68 6f 64 3e 0a 3f 3c 6d 3e 6f  e</method>.?<m>o
3e90: 62 6a 56 61 72 3c 2f 6d 3e 3f 3c 2f 63 6f 6d 6d  bjVar</m>?</comm
3ea0: 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20 20 3c  and>.          <
3eb0: 64 65 73 63 3e 43 72 65 61 74 65 73 20 61 20 6e  desc>Creates a n
3ec0: 65 77 20 27 65 6d 70 74 79 27 20 44 4f 4d 20 64  ew 'empty' DOM d
3ed0: 6f 63 75 6d 65 6e 74 20 6f 62 6a 65 63 74 20 77  ocument object w
3ee0: 69 74 68 6f 75 74 20 61 6e 79 20 65 6c 65 6d 65  ithout any eleme
3ef0: 6e 74 0a 6e 6f 64 65 2e 20 3c 6d 3e 6f 62 6a 56  nt.node. <m>objV
3f00: 61 72 3c 2f 6d 3e 20 63 6f 6e 74 72 6f 6c 73 20  ar</m> controls 
3f10: 74 68 65 20 6d 65 6d 6f 72 79 20 68 61 6e 64 6c  the memory handl
3f20: 69 6e 67 20 61 73 20 65 78 70 6c 61 69 6e 65 64  ing as explained
3f30: 20 61 62 6f 76 65 2e 3c 2f 64 65 73 63 3e 0a 20   above.</desc>. 
3f40: 20 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64         </command
3f50: 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63  def>..        <c
3f60: 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20  ommanddef>.     
3f70: 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63       <command><c
3f80: 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65  md>dom</cmd> <me
3f90: 74 68 6f 64 3e 63 72 65 61 74 65 4e 6f 64 65 43  thod>createNodeC
3fa0: 6d 64 3c 2f 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 3f  md</method>.<m>?
3fb0: 2d 72 65 74 75 72 6e 4e 6f 64 65 43 6d 64 3f 3c  -returnNodeCmd?<
3fc0: 2f 6d 3e 20 3c 6d 3e 3f 2d 74 61 67 4e 61 6d 65  /m> <m>?-tagName
3fd0: 20 6e 61 6d 65 3f 3c 2f 6d 3e 20 3c 6d 3e 3f 2d   name?</m> <m>?-
3fe0: 6a 73 6f 6e 54 79 70 65 20 6a 73 6f 6e 54 79 70  jsonType jsonTyp
3ff0: 65 3f 3c 2f 6d 3e 20 3c 6d 3e 3f 2d 6e 61 6d 65  e?</m> <m>?-name
4000: 73 70 61 63 65 20 55 52 49 3f 3c 2f 6d 3e 20 3c  space URI?</m> <
4010: 6d 3e 28 65 6c 65 6d 65 6e 74 7c 63 6f 6d 6d 65  m>(element|comme
4020: 6e 74 7c 74 65 78 74 7c 63 64 61 74 61 7c 70 69  nt|text|cdata|pi
4030: 29 4e 6f 64 65 3c 2f 6d 3e 20 3c 6d 3e 63 6f 6d  )Node</m> <m>com
4040: 6d 61 6e 64 4e 61 6d 65 3c 2f 6d 3e 3c 2f 63 6f  mandName</m></co
4050: 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20  mmand>.         
4060: 20 3c 64 65 73 63 3e 54 68 69 73 20 6d 65 74 68   <desc>This meth
4070: 6f 64 20 63 72 65 61 74 65 73 20 54 63 6c 20 63  od creates Tcl c
4080: 6f 6d 6d 61 6e 64 73 2c 20 77 68 69 63 68 20 69  ommands, which i
4090: 6e 20 74 75 72 6e 20 63 72 65 61 74 65 0a 20 20  n turn create.  
40a0: 20 20 20 20 20 20 20 20 74 44 4f 4d 20 6e 6f 64          tDOM nod
40b0: 65 73 2e 20 54 63 6c 20 63 6f 6d 6d 61 6e 64 73  es. Tcl commands
40c0: 20 63 72 65 61 74 65 64 20 62 79 20 74 68 69 73   created by this
40d0: 20 63 6f 6d 6d 61 6e 64 20 61 72 65 20 6f 6e 6c   command are onl
40e0: 79 0a 20 20 20 20 20 20 20 20 20 20 61 76 61 69  y.          avai
40f0: 6c 61 62 6c 65 20 69 6e 73 69 64 65 20 61 20 73  lable inside a s
4100: 63 72 69 70 74 20 67 69 76 65 6e 20 74 6f 20 74  cript given to t
4110: 68 65 20 64 6f 6d 4e 6f 64 65 20 6d 65 74 68 6f  he domNode metho
4120: 64 73 0a 20 20 20 20 20 20 20 20 20 20 3c 6d 3e  ds.          <m>
4130: 61 70 70 65 6e 64 46 72 6f 6d 53 63 72 69 70 74  appendFromScript
4140: 3c 2f 6d 3e 20 6f 72 20 3c 6d 3e 69 6e 73 65 72  </m> or <m>inser
4150: 74 42 65 66 6f 72 65 46 72 6f 6d 53 63 72 69 70  tBeforeFromScrip
4160: 74 3c 2f 6d 3e 2e 20 49 66 0a 20 20 20 20 20 20  t</m>. If.      
4170: 20 20 20 20 61 20 63 6f 6d 6d 61 6e 64 20 63 72      a command cr
4180: 65 61 74 65 64 20 77 69 74 68 20 3c 6d 3e 63 72  eated with <m>cr
4190: 65 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 6d 3e 20  eateNodeCmd</m> 
41a0: 69 73 20 69 6e 76 6f 6b 65 64 20 69 6e 0a 20 20  is invoked in.  
41b0: 20 20 20 20 20 20 20 20 61 6e 79 20 6f 74 68 65          any othe
41c0: 72 20 63 6f 6e 74 65 78 74 2c 20 69 74 20 77 69  r context, it wi
41d0: 6c 6c 20 72 65 74 75 72 6e 20 65 72 72 6f 72 2e  ll return error.
41e0: 20 54 68 65 20 63 72 65 61 74 65 64 20 63 6f 6d   The created com
41f0: 6d 61 6e 64 0a 20 20 20 20 20 20 20 20 20 20 3c  mand.          <
4200: 6d 3e 63 6f 6d 6d 61 6e 64 4e 61 6d 65 3c 2f 6d  m>commandName</m
4210: 3e 20 72 65 70 6c 61 63 65 73 20 61 6e 79 20 65  > replaces any e
4220: 78 69 73 74 69 6e 67 20 63 6f 6d 6d 61 6e 64 20  xisting command 
4230: 6f 72 0a 20 20 20 20 20 20 20 20 20 20 70 72 6f  or.          pro
4240: 63 65 64 75 72 65 20 77 69 74 68 20 74 68 61 74  cedure with that
4250: 20 6e 61 6d 65 2e 20 49 66 20 74 68 65 20 3c 6d   name. If the <m
4260: 3e 63 6f 6d 6d 61 6e 64 4e 61 6d 65 3c 2f 6d 3e  >commandName</m>
4270: 20 69 6e 63 6c 75 64 65 73 0a 20 20 20 20 20 20   includes.      
4280: 20 20 20 20 61 6e 79 20 6e 61 6d 65 73 70 61 63      any namespac
4290: 65 20 71 75 61 6c 69 66 69 65 72 73 2c 20 69 74  e qualifiers, it
42a0: 20 69 73 20 63 72 65 61 74 65 64 20 69 6e 20 74   is created in t
42b0: 68 65 20 73 70 65 63 69 66 69 65 64 0a 20 20 20  he specified.   
42c0: 20 20 20 20 20 20 20 6e 61 6d 65 73 70 61 63 65         namespace
42d0: 2e 20 54 68 65 20 3c 6d 3e 2d 74 61 67 4e 61 6d  . The <m>-tagNam
42e0: 65 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 69 73 20  e</m> option is 
42f0: 6f 6e 6c 79 20 61 6c 6c 6f 77 65 64 20 66 6f 72  only allowed for
4300: 0a 20 20 20 20 20 20 20 20 20 20 74 68 65 20 65  .          the e
4310: 6c 65 6d 65 6e 74 4e 6f 64 65 20 74 79 70 65 2e  lementNode type.
4320: 20 54 68 65 20 3c 6d 3e 2d 6a 73 6f 6e 54 79 70   The <m>-jsonTyp
4330: 65 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 69 73 20  e</m> option is 
4340: 6f 6e 6c 79 0a 20 20 20 20 20 20 20 20 20 20 61  only.          a
4350: 6c 6c 6f 77 65 64 20 66 6f 72 20 65 6c 65 6d 65  llowed for eleme
4360: 6e 74 4e 6f 64 65 20 61 6e 64 20 74 65 78 74 4e  ntNode and textN
4370: 6f 64 65 20 74 79 70 65 73 2e 0a 0a 3c 70 3e 49  ode types...<p>I
4380: 66 20 73 75 63 68 20 63 6f 6d 6d 61 6e 64 20 69  f such command i
4390: 73 20 69 6e 76 6f 6b 65 64 20 69 6e 73 69 64 65  s invoked inside
43a0: 20 61 20 73 63 72 69 70 74 20 67 69 76 65 6e 20   a script given 
43b0: 61 73 20 61 72 67 75 6d 65 6e 74 20 74 6f 20 74  as argument to t
43c0: 68 65 0a 64 6f 6d 4e 6f 64 65 20 6d 65 74 68 6f  he.domNode metho
43d0: 64 20 3c 6d 3e 61 70 70 65 6e 64 46 72 6f 6d 53  d <m>appendFromS
43e0: 63 72 69 70 74 3c 2f 6d 3e 20 6f 72 0a 3c 6d 3e  cript</m> or.<m>
43f0: 69 6e 73 65 72 74 42 65 66 6f 72 65 46 72 6f 6d  insertBeforeFrom
4400: 53 63 72 69 70 74 3c 2f 6d 3e 20 69 74 20 63 72  Script</m> it cr
4410: 65 61 74 65 73 20 61 20 6e 65 77 20 6e 6f 64 65  eates a new node
4420: 20 61 6e 64 20 61 70 70 65 6e 64 73 20 74 68 69   and appends thi
4430: 73 0a 6e 6f 64 65 20 61 74 20 74 68 65 20 65 6e  s.node at the en
4440: 64 20 6f 66 20 74 68 65 20 63 68 69 6c 64 20 6c  d of the child l
4450: 69 73 74 20 6f 66 20 74 68 65 20 69 6e 76 6f 6b  ist of the invok
4460: 69 6e 67 20 65 6c 65 6d 65 6e 74 20 6e 6f 64 65  ing element node
4470: 2e 20 49 66 20 74 68 65 0a 6f 70 74 69 6f 6e 20  . If the.option 
4480: 3c 6d 3e 2d 72 65 74 75 72 6e 4e 6f 64 65 43 6d  <m>-returnNodeCm
4490: 64 3c 2f 6d 3e 20 77 61 73 20 67 69 76 65 6e 2c  d</m> was given,
44a0: 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 72 65 74   the command ret
44b0: 75 72 6e 73 20 74 68 65 0a 63 72 65 61 74 65 64  urns the.created
44c0: 20 6e 6f 64 65 20 61 73 20 54 63 6c 20 63 6f 6d   node as Tcl com
44d0: 6d 61 6e 64 2e 20 49 66 20 74 68 69 73 20 6f 70  mand. If this op
44e0: 74 69 6f 6e 20 77 61 73 20 6f 6d 69 74 74 65 64  tion was omitted
44f0: 2c 20 74 68 65 20 63 6f 6d 6d 61 6e 64 0a 72 65  , the command.re
4500: 74 75 72 6e 73 20 6e 6f 74 68 69 6e 67 2e 20 45  turns nothing. E
4510: 61 63 68 20 63 6f 6d 6d 61 6e 64 20 63 72 65 61  ach command crea
4520: 74 65 73 20 61 6c 77 61 79 73 20 74 68 65 20 73  tes always the s
4530: 61 6d 65 20 74 79 70 65 20 6f 66 20 6e 6f 64 65  ame type of node
4540: 2e 0a 57 68 69 63 68 20 74 79 70 65 20 6f 66 20  ..Which type of 
4550: 6e 6f 64 65 20 69 73 20 63 72 65 61 74 65 64 20  node is created 
4560: 62 79 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 69  by the command i
4570: 73 20 64 65 74 65 72 6d 69 6e 65 64 20 62 79 20  s determined by 
4580: 74 68 65 0a 66 69 72 73 74 20 61 72 67 75 6d 65  the.first argume
4590: 6e 74 20 74 6f 20 74 68 65 20 3c 6d 3e 63 72 65  nt to the <m>cre
45a0: 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 6d 3e 2e 20  ateNodeCmd</m>. 
45b0: 54 68 65 20 73 79 6e 74 61 78 20 6f 66 20 74 68  The syntax of th
45c0: 65 20 63 72 65 61 74 65 64 0a 63 6f 6d 6d 61 6e  e created.comman
45d0: 64 20 64 65 70 65 6e 64 73 20 6f 6e 20 74 68 65  d depends on the
45e0: 20 74 79 70 65 20 6f 66 20 74 68 65 20 6e 6f 64   type of the nod
45f0: 65 20 69 74 20 63 72 65 61 74 65 73 2e 3c 2f 70  e it creates.</p
4600: 3e 0a 0a 3c 70 3e 49 66 20 74 68 65 20 63 6f 6d  >..<p>If the com
4610: 6d 61 6e 64 20 74 79 70 65 20 74 6f 20 63 72 65  mand type to cre
4620: 61 74 65 20 69 73 20 3c 6d 3e 65 6c 65 6d 65 6e  ate is <m>elemen
4630: 74 4e 6f 64 65 3c 2f 6d 3e 2c 20 74 68 65 20 63  tNode</m>, the c
4640: 72 65 61 74 65 64 0a 63 6f 6d 6d 61 6e 64 20 77  reated.command w
4650: 69 6c 6c 20 63 72 65 61 74 65 20 61 6e 20 65 6c  ill create an el
4660: 65 6d 65 6e 74 20 6e 6f 64 65 2c 20 69 66 20 63  ement node, if c
4670: 61 6c 6c 65 64 2e 20 57 69 74 68 6f 75 74 20 74  alled. Without t
4680: 68 65 0a 3c 6d 3e 2d 74 61 67 4e 61 6d 65 3c 2f  he.<m>-tagName</
4690: 6d 3e 20 6f 70 74 69 6f 6e 20 74 68 65 20 74 61  m> option the ta
46a0: 67 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 72  g name of the cr
46b0: 65 61 74 65 64 20 6e 6f 64 65 20 69 73 0a 3c 6d  eated node is.<m
46c0: 3e 63 6f 6d 6d 61 6e 64 4e 61 6d 65 3c 2f 6d 3e  >commandName</m>
46d0: 20 77 69 74 68 6f 75 74 20 6e 61 6d 65 73 70 61   without namespa
46e0: 63 65 20 71 75 61 6c 69 66 69 65 72 73 2e 20 49  ce qualifiers. I
46f0: 66 20 74 68 65 0a 3c 6d 3e 2d 74 61 67 4e 61 6d  f the.<m>-tagNam
4700: 65 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 77 61 73  e</m> option was
4710: 20 67 69 76 65 6e 20 74 68 65 6e 20 74 68 65 20   given then the 
4720: 63 72 65 61 74 65 64 20 63 6f 6d 6d 61 6e 64 20  created command 
4730: 74 68 65 20 63 72 65 61 74 65 64 0a 65 6c 65 6d  the created.elem
4740: 65 6e 74 73 20 77 69 6c 6c 20 68 61 76 65 20 74  ents will have t
4750: 68 69 73 20 74 61 67 20 6e 61 6d 65 2e 20 49 66  his tag name. If
4760: 20 74 68 65 20 3c 6d 3e 2d 6a 73 6f 6e 54 79 70   the <m>-jsonTyp
4770: 65 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 77 61 73  e</m> option was
4780: 0a 67 69 76 65 6e 20 74 68 65 6e 20 74 68 65 20  .given then the 
4790: 63 72 65 61 74 65 64 20 6e 6f 64 65 20 65 6c 65  created node ele
47a0: 6d 65 6e 74 73 20 77 69 6c 6c 20 68 61 76 65 20  ments will have 
47b0: 74 68 65 20 67 69 76 65 6e 20 4a 53 4f 4e 20 74  the given JSON t
47c0: 79 70 65 2e 20 49 66 0a 74 68 65 20 3c 6d 3e 2d  ype. If.the <m>-
47d0: 6e 61 6d 65 73 70 61 63 65 3c 2f 6d 3e 20 6f 70  namespace</m> op
47e0: 74 69 6f 6e 20 69 73 20 67 69 76 65 6e 20 74 68  tion is given th
47f0: 65 20 63 72 65 61 74 65 64 20 65 6c 65 6d 65 6e  e created elemen
4800: 74 20 6e 6f 64 65 20 77 69 6c 6c 20 62 65 0a 58  t node will be.X
4810: 4d 4c 20 6e 61 6d 65 73 70 61 63 65 64 20 61 6e  ML namespaced an
4820: 64 20 69 6e 20 74 68 65 20 6e 61 6d 65 73 70 61  d in the namespa
4830: 63 65 20 67 69 76 65 6e 20 62 79 20 74 68 65 20  ce given by the 
4840: 6f 70 74 69 6f 6e 2e 20 54 68 65 20 65 6c 65 6d  option. The elem
4850: 65 6e 74 0a 6e 61 6d 65 20 77 69 6c 6c 20 62 65  ent.name will be
4860: 20 6c 69 74 65 72 61 6c 20 61 73 20 67 69 76 65   literal as give
4870: 6e 20 65 69 74 68 65 72 20 62 79 20 74 68 65 20  n either by the 
4880: 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 6f 72 20  command name or 
4890: 74 68 65 0a 3c 6d 3e 2d 74 61 67 6e 61 6d 65 3c  the.<m>-tagname<
48a0: 2f 6d 3e 20 6f 70 74 69 6f 6e 2c 20 69 66 20 74  /m> option, if t
48b0: 68 61 74 20 77 61 73 20 67 69 76 65 6e 2e 20 41  hat was given. A
48c0: 6e 20 61 70 70 72 6f 70 72 69 61 74 65 20 58 4d  n appropriate XM
48d0: 4c 0a 6e 61 6d 65 73 70 61 63 65 20 64 65 63 6c  L.namespace decl
48e0: 61 72 61 74 69 6f 6e 20 77 69 6c 6c 20 62 65 20  aration will be 
48f0: 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 20 61 64  automatically ad
4900: 64 65 64 2c 20 74 6f 20 62 69 6e 64 20 74 68 65  ded, to bind the
4910: 20 70 72 65 66 69 78 0a 28 69 66 20 74 68 65 20   prefix.(if the 
4920: 65 6c 65 6d 65 6e 74 20 6e 61 6d 65 20 68 61 73  element name has
4930: 20 6f 6e 65 29 20 6f 72 20 74 68 65 20 64 65 66   one) or the def
4940: 61 75 6c 74 20 6e 61 6d 65 73 70 61 63 65 20 28  ault namespace (
4950: 69 66 20 74 68 65 20 65 6c 65 6d 65 6e 74 0a 6e  if the element.n
4960: 61 6d 65 20 68 61 73 6e 27 74 20 61 20 70 72 65  ame hasn't a pre
4970: 66 69 78 29 20 74 6f 20 74 68 65 20 6e 61 6d 65  fix) to the name
4980: 73 70 61 63 65 20 69 66 20 73 75 63 68 20 61 20  space if such a 
4990: 62 69 6e 64 69 6e 67 20 69 73 6e 27 74 20 69 6e  binding isn't in
49a0: 0a 73 63 6f 70 65 2e 3c 2f 70 3e 0a 0a 3c 70 3e  .scope.</p>..<p>
49b0: 54 68 65 20 73 79 6e 74 61 78 20 6f 66 20 74 68  The syntax of th
49c0: 65 20 63 72 65 61 74 65 64 20 63 6f 6d 6d 61 6e  e created comman
49d0: 64 20 69 73 3a 3c 2f 70 3e 0a 0a 3c 73 79 6e 74  d is:</p>..<synt
49e0: 61 78 3e 0a 3c 63 6d 64 3e 65 6c 65 6d 65 6e 74  ax>.<cmd>element
49f0: 4e 6f 64 65 43 6d 64 3c 2f 63 6d 64 3e 20 3c 6d  NodeCmd</cmd> <m
4a00: 3e 3f 61 74 74 72 69 62 75 74 65 4e 61 6d 65 20  >?attributeName 
4a10: 61 74 74 72 69 62 75 74 65 56 61 6c 75 65 20 2e  attributeValue .
4a20: 2e 2e 3f 20 3f 73 63 72 69 70 74 3f 3c 2f 6d 3e  ..? ?script?</m>
4a30: 0a 3c 63 6d 64 3e 65 6c 65 6d 65 6e 74 4e 6f 64  .<cmd>elementNod
4a40: 65 43 6d 64 3c 2f 63 6d 64 3e 20 3c 6d 3e 3f 2d  eCmd</cmd> <m>?-
4a50: 61 74 74 72 69 62 75 74 65 4e 61 6d 65 20 61 74  attributeName at
4a60: 74 72 69 62 75 74 65 56 61 6c 75 65 20 2e 2e 2e  tributeValue ...
4a70: 3f 20 3f 73 63 72 69 70 74 3f 3c 2f 6d 3e 0a 3c  ? ?script?</m>.<
4a80: 63 6d 64 3e 65 6c 65 6d 65 6e 74 4e 6f 64 65 43  cmd>elementNodeC
4a90: 6d 64 3c 2f 63 6d 64 3e 20 3c 6d 3e 6e 61 6d 65  md</cmd> <m>name
4aa0: 5f 76 61 6c 75 65 5f 6c 69 73 74 20 73 63 72 69  _value_list scri
4ab0: 70 74 3c 2f 6d 3e 0a 3c 2f 73 79 6e 74 61 78 3e  pt</m>.</syntax>
4ac0: 0a 0a 3c 70 3e 54 68 65 20 63 6f 6d 6d 61 6e 64  ..<p>The command
4ad0: 20 73 79 6e 74 61 78 20 61 6c 6c 6f 77 73 20 74   syntax allows t
4ae0: 68 72 65 65 20 64 69 66 66 65 72 65 6e 74 20 77  hree different w
4af0: 61 79 73 20 74 6f 20 73 70 65 63 69 66 79 20 74  ays to specify t
4b00: 68 65 20 61 74 74 72 69 62 75 74 65 73 20 6f 66  he attributes of
4b10: 0a 74 68 65 20 72 65 73 75 6c 74 69 6e 67 20 65  .the resulting e
4b20: 6c 65 6d 65 6e 74 2e 20 54 68 65 73 65 20 63 6f  lement. These co
4b30: 75 6c 64 20 62 65 20 73 70 65 63 69 66 69 65 64  uld be specified
4b40: 20 77 69 74 68 20 3c 6d 3e 61 74 74 72 69 62 75   with <m>attribu
4b50: 74 65 4e 61 6d 65 0a 61 74 74 72 69 62 75 74 65  teName.attribute
4b60: 56 61 6c 75 65 3c 2f 6d 3e 20 61 72 67 75 6d 65  Value</m> argume
4b70: 6e 74 20 70 61 69 72 73 2c 20 69 6e 20 61 6e 20  nt pairs, in an 
4b80: 22 6f 70 74 69 6f 6e 20 73 74 79 6c 65 22 20 77  "option style" w
4b90: 61 79 20 77 69 74 68 0a 3c 6d 3e 2d 61 74 74 72  ay with.<m>-attr
4ba0: 69 75 62 74 65 4e 61 6d 65 20 61 74 74 72 69 62  iubteName attrib
4bb0: 75 74 65 56 61 6c 75 65 3c 2f 6d 3e 20 61 72 67  uteValue</m> arg
4bc0: 75 6d 65 6e 74 20 70 61 69 72 73 20 28 74 68 65  ument pairs (the
4bd0: 20 27 2d 27 20 63 68 61 72 61 63 74 65 72 20 69   '-' character i
4be0: 73 20 6f 6e 6c 79 0a 73 79 6e 74 61 63 74 69 63  s only.syntactic
4bf0: 61 6c 20 73 75 67 61 72 20 61 6e 64 20 77 69 6c  al sugar and wil
4c00: 6c 20 62 65 20 73 74 72 69 70 70 65 64 20 6f 66  l be stripped of
4c10: 66 29 20 6f 72 20 61 73 20 61 20 54 63 6c 20 6c  f) or as a Tcl l
4c20: 69 73 74 20 77 69 74 68 20 65 6c 65 6d 65 6e 74  ist with element
4c30: 73 0a 69 6e 74 65 72 70 72 65 74 65 64 20 61 73  s.interpreted as
4c40: 20 61 74 74 72 69 62 75 74 65 20 6e 61 6d 65 20   attribute name 
4c50: 61 6e 64 20 74 68 65 20 63 6f 72 72 65 73 70 6f  and the correspo
4c60: 6e 64 69 6e 67 20 61 74 74 72 69 62 75 74 65 20  nding attribute 
4c70: 76 61 6c 75 65 2e 0a 54 68 65 20 61 74 74 72 69  value..The attri
4c80: 62 75 74 65 20 6e 61 6d 65 20 65 6c 65 6d 65 6e  bute name elemen
4c90: 74 73 20 69 6e 20 74 68 65 20 6c 69 73 74 20 6d  ts in the list m
4ca0: 61 79 20 68 61 76 65 20 61 20 6c 65 61 64 69 6e  ay have a leadin
4cb0: 67 20 27 2d 27 20 63 68 61 72 61 63 74 65 72 2c  g '-' character,
4cc0: 20 77 68 69 63 68 0a 77 69 6c 6c 20 62 65 20 73   which.will be s
4cd0: 74 72 69 70 70 65 64 20 6f 66 66 2e 3c 2f 70 3e  tripped off.</p>
4ce0: 0a 0a 3c 70 3e 45 76 65 72 79 20 3c 6d 3e 65 6c  ..<p>Every <m>el
4cf0: 65 6d 65 6e 74 4e 6f 64 65 43 6d 64 3c 2f 6d 3e  ementNodeCmd</m>
4d00: 20 61 63 63 65 70 74 73 20 61 6e 20 6f 70 74 69   accepts an opti
4d10: 6f 6e 61 6c 20 54 63 6c 20 73 63 72 69 70 74 20  onal Tcl script 
4d20: 61 73 20 6c 61 73 74 0a 61 72 67 75 6d 65 6e 74  as last.argument
4d30: 2e 20 54 68 69 73 20 73 63 72 69 70 74 20 69 73  . This script is
4d40: 20 65 76 61 6c 75 61 74 65 64 20 61 73 20 72 65   evaluated as re
4d50: 63 75 72 73 69 76 65 20 3c 6d 3e 61 70 70 65 6e  cursive <m>appen
4d60: 64 46 72 6f 6d 53 63 72 69 70 74 3c 2f 6d 3e 20  dFromScript</m> 
4d70: 73 63 72 69 70 74 0a 77 69 74 68 20 74 68 65 20  script.with the 
4d80: 6e 6f 64 65 20 63 72 65 61 74 65 64 20 62 79 20  node created by 
4d90: 74 68 65 20 3c 6d 3e 65 6c 65 6d 65 6e 74 4e 6f  the <m>elementNo
4da0: 64 65 43 6d 64 3c 2f 6d 3e 20 61 73 20 70 61 72  deCmd</m> as par
4db0: 65 6e 74 20 6f 66 20 61 6c 6c 20 6e 6f 64 65 73  ent of all nodes
4dc0: 0a 63 72 65 61 74 65 64 20 62 79 20 74 68 65 20  .created by the 
4dd0: 73 63 72 69 70 74 2e 3c 2f 70 3e 0a 0a 3c 70 3e  script.</p>..<p>
4de0: 49 66 20 74 68 65 20 66 69 72 73 74 20 61 72 67  If the first arg
4df0: 75 6d 65 6e 74 20 6f 66 20 74 68 65 20 6d 65 74  ument of the met
4e00: 68 6f 64 20 69 73 20 3c 6d 3e 74 65 78 74 4e 6f  hod is <m>textNo
4e10: 64 65 3c 2f 6d 3e 2c 20 74 68 65 20 63 6f 6d 6d  de</m>, the comm
4e20: 61 6e 64 0a 77 69 6c 6c 20 63 72 65 61 74 65 20  and.will create 
4e30: 61 20 74 65 78 74 20 6e 6f 64 65 2e 20 49 66 20  a text node. If 
4e40: 74 68 65 20 3c 6d 3e 2d 6a 73 6f 6e 54 79 70 65  the <m>-jsonType
4e50: 3c 2f 6d 3e 20 6f 70 74 69 6f 6e 20 77 61 73 20  </m> option was 
4e60: 67 69 76 65 6e 20 74 68 65 6e 0a 74 68 65 20 63  given then.the c
4e70: 72 65 61 74 65 64 20 74 65 78 74 20 6e 6f 64 65  reated text node
4e80: 20 77 69 6c 6c 20 68 61 76 65 20 74 68 61 74 20   will have that 
4e90: 4a 53 4f 4e 20 74 79 70 65 2e 20 54 68 65 20 73  JSON type. The s
4ea0: 79 6e 74 61 78 20 6f 66 20 74 68 65 0a 63 72 65  yntax of the.cre
4eb0: 61 74 65 64 20 63 6f 6d 6d 61 6e 64 20 69 73 3a  ated command is:
4ec0: 3c 2f 70 3e 0a 0a 3c 73 79 6e 74 61 78 3e 0a 3c  </p>..<syntax>.<
4ed0: 63 6d 64 3e 74 65 78 74 4e 6f 64 65 43 6d 64 3c  cmd>textNodeCmd<
4ee0: 2f 63 6d 64 3e 20 3f 2d 64 69 73 61 62 6c 65 4f  /cmd> ?-disableO
4ef0: 75 74 70 75 74 45 73 63 61 70 69 6e 67 3f 20 3c  utputEscaping? <
4f00: 6d 3e 64 61 74 61 3c 2f 6d 3e 0a 3c 2f 73 79 6e  m>data</m>.</syn
4f10: 74 61 78 3e 0a 0a 3c 70 3e 49 66 20 74 68 65 20  tax>..<p>If the 
4f20: 6f 70 74 69 6f 6e 61 6c 20 66 6c 61 67 20 3c 6d  optional flag <m
4f30: 3e 2d 64 69 73 61 62 6c 65 4f 75 74 70 75 74 45  >-disableOutputE
4f40: 73 63 61 70 69 6e 67 3c 2f 6d 3e 20 69 73 20 67  scaping</m> is g
4f50: 69 76 65 6e 2c 20 74 68 65 0a 65 73 63 61 70 69  iven, the.escapi
4f60: 6e 67 20 6f 66 20 74 68 65 20 61 6d 70 65 72 73  ng of the ampers
4f70: 61 6e 64 20 63 68 61 72 61 63 74 65 72 20 28 26  and character (&
4f80: 61 6d 70 3b 29 20 61 6e 64 20 74 68 65 20 6c 65  amp;) and the le
4f90: 66 74 20 61 6e 67 6c 65 20 62 72 61 63 6b 65 74  ft angle bracket
4fa0: 20 28 26 6c 74 3b 29 0a 69 6e 73 69 64 65 20 74   (&lt;).inside t
4fb0: 68 65 20 64 61 74 61 20 69 73 20 64 69 73 61 62  he data is disab
4fc0: 6c 65 64 2e 20 59 6f 75 20 73 68 6f 75 6c 64 20  led. You should 
4fd0: 75 73 65 20 74 68 69 73 20 66 6c 61 67 20 63 61  use this flag ca
4fe0: 72 65 66 75 6c 6c 79 2e 3c 2f 70 3e 0a 0a 3c 70  refully.</p>..<p
4ff0: 3e 49 66 20 74 68 65 20 66 69 72 73 74 20 61 72  >If the first ar
5000: 67 75 6d 65 6e 74 20 6f 66 20 74 68 65 20 6d 65  gument of the me
5010: 74 68 6f 64 20 69 73 20 3c 6d 3e 63 6f 6d 6d 65  thod is <m>comme
5020: 6e 74 4e 6f 64 65 3c 2f 6d 3e 20 6f 72 20 0a 3c  ntNode</m> or .<
5030: 6d 3e 63 64 61 74 61 4e 6f 64 65 3c 2f 6d 3e 20  m>cdataNode</m> 
5040: 74 68 65 20 63 6f 6d 6d 61 6e 64 20 77 69 6c 6c  the command will
5050: 20 63 72 65 61 74 65 20 61 6e 20 63 6f 6d 6d 65   create an comme
5060: 6e 74 20 6e 6f 64 65 20 6f 72 20 43 44 41 54 41  nt node or CDATA
5070: 20 73 65 63 74 69 6f 6e 20 0a 6e 6f 64 65 2e 20   section .node. 
5080: 54 68 65 20 73 79 6e 74 61 78 20 6f 66 20 74 68  The syntax of th
5090: 65 20 63 72 65 61 74 65 64 20 63 6f 6d 6d 61 6e  e created comman
50a0: 64 20 69 73 3a 3c 2f 70 3e 0a 0a 3c 73 79 6e 74  d is:</p>..<synt
50b0: 61 78 3e 0a 3c 63 6d 64 3e 6e 6f 64 65 43 6d 64  ax>.<cmd>nodeCmd
50c0: 3c 2f 63 6d 64 3e 20 3c 6d 3e 64 61 74 61 3c 2f  </cmd> <m>data</
50d0: 6d 3e 0a 3c 2f 73 79 6e 74 61 78 3e 0a 0a 3c 70  m>.</syntax>..<p
50e0: 3e 49 66 20 74 68 65 20 66 69 72 73 74 20 61 72  >If the first ar
50f0: 67 75 6d 65 6e 74 20 6f 66 20 74 68 65 20 6d 65  gument of the me
5100: 74 68 6f 64 20 69 73 20 3c 6d 3e 70 69 4e 6f 64  thod is <m>piNod
5110: 65 3c 2f 6d 3e 2c 20 74 68 65 20 63 6f 6d 6d 61  e</m>, the comma
5120: 6e 64 20 77 69 6c 6c 0a 63 72 65 61 74 65 20 61  nd will.create a
5130: 20 70 72 6f 63 65 73 73 69 6e 67 20 69 6e 73 74   processing inst
5140: 72 75 63 74 69 6f 6e 20 6e 6f 64 65 2e 20 54 68  ruction node. Th
5150: 65 20 73 79 6e 74 61 78 20 6f 66 20 74 68 65 20  e syntax of the 
5160: 63 72 65 61 74 65 64 0a 63 6f 6d 6d 61 6e 64 20  created.command 
5170: 69 73 3a 3c 2f 70 3e 0a 0a 3c 73 79 6e 74 61 78  is:</p>..<syntax
5180: 3e 0a 3c 63 6d 64 3e 70 69 4e 6f 64 65 43 6d 64  >.<cmd>piNodeCmd
5190: 3c 2f 63 6d 64 3e 20 3c 6d 3e 74 61 72 67 65 74  </cmd> <m>target
51a0: 20 64 61 74 61 3c 2f 6d 3e 0a 3c 2f 73 79 6e 74   data</m>.</synt
51b0: 61 78 3e 0a 0a 3c 2f 64 65 73 63 3e 0a 20 20 20  ax>..</desc>.   
51c0: 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65       </commandde
51d0: 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d  f>..        <com
51e0: 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20 20 20  manddef>.       
51f0: 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64     <command><cmd
5200: 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68  >dom</cmd> <meth
5210: 6f 64 3e 73 65 74 53 74 6f 72 65 4c 69 6e 65 43  od>setStoreLineC
5220: 6f 6c 75 6d 6e 3c 2f 6d 65 74 68 6f 64 3e 20 3c  olumn</method> <
5230: 6d 3e 3f 62 6f 6f 6c 65 61 6e 3c 2f 6d 3e 3f 3c  m>?boolean</m>?<
5240: 2f 63 6f 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20  /command>.      
5250: 20 20 20 20 3c 64 65 73 63 3e 49 66 20 73 77 69      <desc>If swi
5260: 74 63 68 65 64 20 6f 6e 2c 20 74 68 65 20 44 4f  tched on, the DO
5270: 4d 20 6e 6f 64 65 73 20 77 69 6c 6c 20 63 6f 6e  M nodes will con
5280: 74 61 69 6e 20 6c 69 6e 65 20 61 6e 64 20 63 6f  tain line and co
5290: 6c 75 6d 6e 0a 70 6f 73 69 74 69 6f 6e 20 69 6e  lumn.position in
52a0: 66 6f 72 6d 61 74 69 6f 6e 20 66 6f 72 20 74 68  formation for th
52b0: 65 20 6f 72 69 67 69 6e 61 6c 20 58 4d 4c 20 64  e original XML d
52c0: 6f 63 75 6d 65 6e 74 20 61 66 74 65 72 20 70 61  ocument after pa
52d0: 72 73 69 6e 67 2e 20 54 68 65 20 64 65 66 61 75  rsing. The defau
52e0: 6c 74 0a 69 73 20 6e 6f 74 20 74 6f 20 73 74 6f  lt.is not to sto
52f0: 72 65 20 6c 69 6e 65 20 61 6e 64 20 63 6f 6c 75  re line and colu
5300: 6d 6e 20 70 6f 73 69 74 69 6f 6e 20 69 6e 66 6f  mn position info
5310: 72 6d 61 74 69 6f 6e 2e 3c 2f 64 65 73 63 3e 0a  rmation.</desc>.
5320: 20 20 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e          </comman
5330: 64 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c  ddef>..        <
5340: 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20  commanddef>.    
5350: 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c        <command><
5360: 63 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d  cmd>dom</cmd> <m
5370: 65 74 68 6f 64 3e 73 65 74 4e 61 6d 65 43 68 65  ethod>setNameChe
5380: 63 6b 3c 2f 6d 65 74 68 6f 64 3e 20 3c 6d 3e 3f  ck</method> <m>?
5390: 62 6f 6f 6c 65 61 6e 3c 2f 6d 3e 3f 3c 2f 63 6f  boolean</m>?</co
53a0: 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20  mmand>.         
53b0: 20 3c 64 65 73 63 3e 49 66 20 4e 61 6d 65 43 68   <desc>If NameCh
53c0: 65 63 6b 20 69 73 20 74 72 75 65 2c 20 65 76 65  eck is true, eve
53d0: 72 79 20 6d 65 74 68 6f 64 20 77 68 69 63 68 20  ry method which 
53e0: 65 78 70 65 63 74 73 20 61 6e 20 58 4d 4c 20 4e  expects an XML N
53f0: 61 6d 65 2c 0a 61 20 66 75 6c 6c 20 71 75 61 6c  ame,.a full qual
5400: 69 66 69 65 64 20 6e 61 6d 65 20 6f 72 20 61 20  ified name or a 
5410: 70 72 6f 63 65 73 73 69 6e 67 20 69 6e 73 74 72  processing instr
5420: 75 63 74 69 6e 67 20 74 61 72 67 65 74 20 77 69  ucting target wi
5430: 6c 6c 20 63 68 65 63 6b 2c 20 69 66 20 74 68 65  ll check, if the
5440: 0a 67 69 76 65 6e 20 73 74 72 69 6e 67 20 69 73  .given string is
5450: 20 76 61 6c 69 64 20 61 63 63 6f 72 64 69 6e 67   valid according
5460: 20 74 6f 20 69 74 73 20 70 72 6f 64 75 63 74 69   to its producti
5470: 6f 6e 20 72 75 6c 65 2e 20 46 6f 72 20 63 6f 6d  on rule. For com
5480: 6d 61 6e 64 73 20 63 72 65 61 74 65 64 0a 77 69  mands created.wi
5490: 74 68 20 74 68 65 20 3c 6d 3e 63 72 65 61 74 65  th the <m>create
54a0: 4e 6f 64 65 43 6d 64 3c 2f 6d 3e 20 6d 65 74 68  NodeCmd</m> meth
54b0: 6f 64 20 74 6f 20 62 65 20 75 73 65 64 20 69 6e  od to be used in
54c0: 20 74 68 65 20 63 6f 6e 74 65 78 74 20 6f 66 0a   the context of.
54d0: 3c 6d 3e 61 70 70 65 6e 64 46 72 6f 6d 53 63 72  <m>appendFromScr
54e0: 69 70 74 3c 2f 6d 3e 20 74 68 65 20 73 74 61 74  ipt</m> the stat
54f0: 75 73 20 6f 66 20 74 68 65 20 66 6c 61 67 20 61  us of the flag a
5500: 74 20 63 72 65 61 74 69 6f 6e 20 74 69 6d 65 0a  t creation time.
5510: 64 65 63 69 64 65 73 2e 20 49 66 20 4e 61 6d 65  decides. If Name
5520: 43 68 65 63 6b 20 69 73 20 74 72 75 65 20 61 74  Check is true at
5530: 20 63 72 65 61 74 69 6f 6e 20 74 69 6d 65 2c 20   creation time, 
5540: 74 68 65 20 63 6f 6d 6d 61 6e 64 20 77 69 6c 6c  the command will
5550: 0a 63 68 65 63 6b 20 69 74 73 20 61 72 67 75 6d  .check its argum
5560: 65 6e 74 73 2c 20 6f 74 68 65 72 77 69 73 65 20  ents, otherwise 
5570: 6e 6f 74 2e 20 54 68 65 20 3c 6d 3e 73 65 74 4e  not. The <m>setN
5580: 61 6d 65 43 68 65 63 6b 3c 2f 6d 3e 0a 73 65 74  ameCheck</m>.set
5590: 20 74 68 69 73 20 66 6c 61 67 2e 20 49 74 20 72   this flag. It r
55a0: 65 74 75 72 6e 73 20 74 68 65 20 63 75 72 72 65  eturns the curre
55b0: 6e 74 20 4e 61 6d 65 43 68 65 63 6b 20 66 6c 61  nt NameCheck fla
55c0: 67 20 73 74 61 74 65 2e 20 54 68 65 0a 64 65 66  g state. The.def
55d0: 61 75 6c 74 20 73 74 61 74 65 20 66 6f 72 20 4e  ault state for N
55e0: 61 6d 65 43 68 65 63 6b 20 69 73 20 74 72 75 65  ameCheck is true
55f0: 2e 20 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20  . </desc>.      
5600: 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a    </commanddef>.
5610: 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e  .        <comman
5620: 64 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20  ddef>.          
5630: 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f  <command><cmd>do
5640: 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e  m</cmd> <method>
5650: 73 65 74 54 65 78 74 43 68 65 63 6b 3c 2f 6d 65  setTextCheck</me
5660: 74 68 6f 64 3e 20 3c 6d 3e 3f 62 6f 6f 6c 65 61  thod> <m>?boolea
5670: 6e 3c 2f 6d 3e 3f 3c 2f 63 6f 6d 6d 61 6e 64 3e  n</m>?</command>
5680: 0a 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63  .          <desc
5690: 3e 49 66 20 54 65 78 74 43 68 65 63 6b 20 69 73  >If TextCheck is
56a0: 20 74 72 75 65 2c 20 65 76 65 72 79 20 63 6f 6d   true, every com
56b0: 6d 61 6e 64 20 77 68 69 63 68 20 65 78 70 65 63  mand which expec
56c0: 74 73 20 58 4d 4c 20 43 68 61 72 73 2c 0a 61 20  ts XML Chars,.a 
56d0: 63 6f 6d 6d 65 6e 74 2c 20 61 20 43 44 41 54 41  comment, a CDATA
56e0: 20 73 65 63 74 69 6f 6e 20 76 61 6c 75 65 20 6f   section value o
56f0: 72 20 61 20 70 72 6f 63 65 73 73 69 6e 67 20 69  r a processing i
5700: 6e 73 74 72 75 63 74 69 6e 67 20 76 61 6c 75 65  nstructing value
5710: 20 77 69 6c 6c 20 63 68 65 63 6b 2c 0a 69 66 20   will check,.if 
5720: 74 68 65 20 67 69 76 65 6e 20 73 74 72 69 6e 67  the given string
5730: 20 69 73 20 76 61 6c 69 64 20 61 63 63 6f 72 64   is valid accord
5740: 69 6e 67 20 74 6f 20 69 74 73 20 70 72 6f 64 75  ing to its produ
5750: 63 74 69 6f 6e 20 72 75 6c 65 2e 20 46 6f 72 20  ction rule. For 
5760: 63 6f 6d 6d 61 6e 64 73 0a 63 72 65 61 74 65 64  commands.created
5770: 20 77 69 74 68 20 74 68 65 20 3c 6d 3e 63 72 65   with the <m>cre
5780: 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 6d 3e 20 6d  ateNodeCmd</m> m
5790: 65 74 68 6f 64 20 74 6f 20 62 65 20 75 73 65 64  ethod to be used
57a0: 20 69 6e 20 74 68 65 0a 63 6f 6e 74 65 78 74 20   in the.context 
57b0: 6f 66 20 3c 6d 3e 61 70 70 65 6e 64 46 72 6f 6d  of <m>appendFrom
57c0: 53 63 72 69 70 74 3c 2f 6d 3e 20 74 68 65 20 73  Script</m> the s
57d0: 74 61 74 75 73 20 6f 66 20 74 68 65 20 66 6c 61  tatus of the fla
57e0: 67 20 61 74 0a 63 72 65 61 74 69 6f 6e 20 74 69  g at.creation ti
57f0: 6d 65 20 64 65 63 69 64 65 73 2e 20 49 66 20 54  me decides. If T
5800: 65 78 74 43 68 65 63 6b 20 69 73 20 74 72 75 65  extCheck is true
5810: 20 61 74 20 63 72 65 61 74 69 6f 6e 20 74 69 6d   at creation tim
5820: 65 2c 20 74 68 65 0a 63 6f 6d 6d 61 6e 64 20 77  e, the.command w
5830: 69 6c 6c 20 63 68 65 63 6b 20 69 74 73 20 61 72  ill check its ar
5840: 67 75 6d 65 6e 74 73 2c 20 6f 74 68 65 72 77 69  guments, otherwi
5850: 73 65 20 6e 6f 74 2e 54 68 65 0a 3c 6d 3e 73 65  se not.The.<m>se
5860: 74 54 65 78 74 43 68 65 63 6b 3c 2f 6d 3e 20 6d  tTextCheck</m> m
5870: 65 74 68 6f 64 20 73 65 74 73 20 74 68 69 73 20  ethod sets this 
5880: 66 6c 61 67 2e 20 49 74 20 72 65 74 75 72 6e 73  flag. It returns
5890: 20 74 68 65 20 63 75 72 72 65 6e 74 0a 54 65 78   the current.Tex
58a0: 74 43 68 65 63 6b 20 66 6c 61 67 20 73 74 61 74  tCheck flag stat
58b0: 65 2e 20 54 68 65 20 64 65 66 61 75 6c 74 20 73  e. The default s
58c0: 74 61 74 65 20 66 6f 72 20 54 65 78 74 43 68 65  tate for TextChe
58d0: 63 6b 20 69 73 20 74 72 75 65 2e 3c 2f 64 65 73  ck is true.</des
58e0: 63 3e 0a 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61  c>.      </comma
58f0: 6e 64 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20  nddef>..        
5900: 3c 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20  <commanddef>.   
5910: 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e         <command>
5920: 3c 63 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c  <cmd>dom</cmd> <
5930: 6d 65 74 68 6f 64 3e 73 65 74 4f 62 6a 65 63 74  method>setObject
5940: 43 6f 6d 6d 61 6e 64 73 3c 2f 6d 65 74 68 6f 64  Commands</method
5950: 3e 20 3f 3c 6d 3e 28 61 75 74 6f 6d 61 74 69 63  > ?<m>(automatic
5960: 7c 74 6f 6b 65 6e 7c 63 6f 6d 6d 61 6e 64 29 3c  |token|command)<
5970: 2f 6d 3e 3f 3c 2f 63 6f 6d 6d 61 6e 64 3e 0a 20  /m>?</command>. 
5980: 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 43           <desc>C
5990: 6f 6e 74 72 6f 6c 73 20 69 66 20 64 6f 63 75 6d  ontrols if docum
59a0: 65 6e 74 73 20 61 6e 64 20 6e 6f 64 65 73 20 61  ents and nodes a
59b0: 72 65 20 63 72 65 61 74 65 64 20 61 73 20 74 63  re created as tc
59c0: 6c 20 63 6f 6d 6d 61 6e 64 73 20 6f 72 0a 61 73  l commands or.as
59d0: 20 74 6f 6b 65 6e 20 74 6f 20 62 65 0a 75 73 65   token to be.use
59e0: 64 20 77 69 74 68 20 74 68 65 20 64 6f 6d 4e 6f  d with the domNo
59f0: 64 65 20 61 6e 64 20 64 6f 6d 44 6f 63 20 63 6f  de and domDoc co
5a00: 6d 6d 61 6e 64 73 2e 20 49 66 20 74 68 65 20 6d  mmands. If the m
5a10: 6f 64 65 20 69 73 0a 27 61 75 74 6f 6d 61 74 69  ode is.'automati
5a20: 63 27 2c 20 74 68 65 6e 20 6d 65 74 68 6f 64 73  c', then methods
5a30: 20 75 73 65 64 20 61 74 20 74 63 6c 20 63 6f 6d   used at tcl com
5a40: 6d 61 6e 64 73 20 77 69 6c 6c 20 63 72 65 61 74  mands will creat
5a50: 65 20 74 63 6c 0a 63 6f 6d 6d 61 6e 64 73 20 61  e tcl.commands a
5a60: 6e 64 20 6d 65 74 68 6f 64 73 20 75 73 65 64 20  nd methods used 
5a70: 61 74 20 64 6f 63 20 6f 72 20 6e 6f 64 65 20 74  at doc or node t
5a80: 6f 6b 65 73 20 77 69 6c 6c 20 63 72 65 61 74 65  okes will create
5a90: 20 74 6f 6b 65 6e 73 2e 20 49 66 0a 74 68 65 20   tokens. If.the 
5aa0: 6d 6f 64 65 20 69 73 20 27 63 6f 6d 6d 61 6e 64  mode is 'command
5ab0: 27 20 74 68 65 6e 20 61 6c 77 61 79 73 20 74 63  ' then always tc
5ac0: 6c 20 63 6f 6d 6d 61 6e 64 73 20 77 69 6c 6c 20  l commands will 
5ad0: 62 65 20 63 72 65 61 74 65 64 2e 20 49 66 0a 74  be created. If.t
5ae0: 68 65 20 6d 6f 64 65 20 69 73 20 27 74 6f 6b 65  he mode is 'toke
5af0: 6e 27 2c 20 74 68 65 6e 20 61 6c 77 61 79 73 20  n', then always 
5b00: 74 6f 6b 65 6e 20 77 69 6c 6c 20 62 65 20 63 72  token will be cr
5b10: 65 61 74 65 64 2e 20 54 68 65 20 6d 65 74 68 6f  eated. The metho
5b20: 64 0a 72 65 74 75 72 6e 73 20 74 68 65 20 63 75  d.returns the cu
5b30: 72 72 65 6e 74 20 6d 6f 64 65 2e 20 54 68 69 73  rrent mode. This
5b40: 20 6d 65 74 68 6f 64 20 69 73 20 61 6e 20 65 78   method is an ex
5b50: 70 65 72 69 6d 65 6e 74 61 6c 20 69 6e 74 65 72  perimental inter
5b60: 66 61 63 65 2e 3c 2f 64 65 73 63 3e 0a 20 20 20  face.</desc>.   
5b70: 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e     </commanddef>
5b80: 0a 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61  ..        <comma
5b90: 6e 64 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20  nddef>.         
5ba0: 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64   <command><cmd>d
5bb0: 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64  om</cmd> <method
5bc0: 3e 69 73 4e 61 6d 65 3c 2f 6d 65 74 68 6f 64 3e  >isName</method>
5bd0: 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d 3e 3c 2f 63 6f   <m>name</m></co
5be0: 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20  mmand>.         
5bf0: 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73 20 31   <desc>Returns 1
5c00: 20 69 66 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d 3e 20   if <m>name</m> 
5c10: 69 73 20 61 20 76 61 6c 69 64 20 58 4d 4c 20 4e  is a valid XML N
5c20: 61 6d 65 20 61 63 63 6f 72 64 69 6e 67 20 74 6f  ame according to
5c30: 0a 70 72 6f 64 75 63 74 69 6f 6e 20 35 20 6f 66  .production 5 of
5c40: 20 74 68 65 20 3c 72 65 66 0a 20 20 20 20 20 20   the <ref.      
5c50: 20 20 20 20 20 20 68 72 65 66 3d 22 68 74 74 70        href="http
5c60: 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52  ://www.w3.org/TR
5c70: 2f 32 30 30 34 2f 52 45 43 2d 78 6d 6c 2d 32 30  /2004/REC-xml-20
5c80: 30 34 30 32 30 34 2f 23 4e 54 2d 4e 61 6d 65 43  040204/#NT-NameC
5c90: 68 61 72 22 3e 58 4d 4c 0a 20 20 20 20 20 20 20  har">XML.       
5ca0: 20 20 20 20 20 31 2e 30 3c 2f 72 65 66 3e 20 72       1.0</ref> r
5cb0: 65 63 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e 20 54  ecommendation. T
5cc0: 68 69 73 20 6d 65 61 6e 73 20 74 68 61 74 20 3c  his means that <
5cd0: 6d 3e 6e 61 6d 65 3c 2f 6d 3e 20 69 73 20 61 20  m>name</m> is a 
5ce0: 76 61 6c 69 64 0a 20 20 20 20 20 20 20 20 20 20  valid.          
5cf0: 58 4d 4c 20 65 6c 65 6d 65 6e 74 20 6f 72 20 61  XML element or a
5d00: 74 74 72 69 62 75 74 65 20 6e 61 6d 65 2e 20 4f  ttribute name. O
5d10: 74 68 65 72 77 69 73 65 20 69 74 20 72 65 74 75  therwise it retu
5d20: 72 6e 73 20 30 2e 3c 2f 64 65 73 63 3e 0a 20 20  rns 0.</desc>.  
5d30: 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64        </commandd
5d40: 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63 6f  ef>..        <co
5d50: 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20 20  mmanddef>.      
5d60: 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d      <command><cm
5d70: 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74  d>dom</cmd> <met
5d80: 68 6f 64 3e 69 73 50 49 4e 61 6d 65 3c 2f 6d 65  hod>isPIName</me
5d90: 74 68 6f 64 3e 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d  thod> <m>name</m
5da0: 3e 3c 2f 63 6f 6d 6d 61 6e 64 3e 0a 20 20 20 20  ></command>.    
5db0: 20 20 20 20 20 20 3c 64 65 73 63 3e 52 65 74 75        <desc>Retu
5dc0: 72 6e 73 20 31 20 69 66 20 3c 6d 3e 6e 61 6d 65  rns 1 if <m>name
5dd0: 3c 2f 6d 3e 20 69 73 20 61 20 76 61 6c 69 64 20  </m> is a valid 
5de0: 58 4d 4c 20 70 72 6f 63 65 73 73 69 6e 67 20 69  XML processing i
5df0: 6e 73 74 72 75 63 74 69 6f 6e 0a 20 20 20 20 20  nstruction.     
5e00: 20 20 20 20 20 74 61 72 67 65 74 20 61 63 63 6f       target acco
5e10: 72 64 69 6e 67 20 74 6f 0a 70 72 6f 64 75 63 74  rding to.product
5e20: 69 6f 6e 20 31 37 20 6f 66 20 74 68 65 20 3c 72  ion 17 of the <r
5e30: 65 66 20 68 72 65 66 3d 22 68 74 74 70 3a 2f 2f  ef href="http://
5e40: 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52 2f 32 30  www.w3.org/TR/20
5e50: 30 30 2f 52 45 43 2d 78 6d 6c 2d 32 30 30 30 31  00/REC-xml-20001
5e60: 30 30 36 2e 68 74 6d 6c 22 3e 58 4d 4c 20 31 2e  006.html">XML 1.
5e70: 30 3c 2f 72 65 66 3e 20 72 65 63 6f 6d 6d 65 6e  0</ref> recommen
5e80: 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77 69 73  dation. Otherwis
5e90: 65 20 69 74 20 72 65 74 75 72 6e 73 20 30 2e 3c  e it returns 0.<
5ea0: 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20 3c  /desc>.        <
5eb0: 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 0a 20 20  /commanddef>..  
5ec0: 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 64 65        <commandde
5ed0: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 63 6f  f>.          <co
5ee0: 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d 3c 2f  mmand><cmd>dom</
5ef0: 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 69 73 4e  cmd> <method>isN
5f00: 43 4e 61 6d 65 3c 2f 6d 65 74 68 6f 64 3e 20 3c  CName</method> <
5f10: 6d 3e 6e 61 6d 65 3c 2f 6d 3e 3c 2f 63 6f 6d 6d  m>name</m></comm
5f20: 61 6e 64 3e 0a 20 20 20 20 20 20 20 20 20 20 3c  and>.          <
5f30: 64 65 73 63 3e 52 65 74 75 72 6e 73 20 31 20 69  desc>Returns 1 i
5f40: 66 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d 3e 20 69 73  f <m>name</m> is
5f50: 20 61 20 76 61 6c 69 64 20 4e 43 4e 61 6d 65 20   a valid NCName 
5f60: 61 63 63 6f 72 64 69 6e 67 0a 74 6f 20 70 72 6f  according.to pro
5f70: 64 75 63 74 69 6f 6e 20 34 20 6f 66 20 74 68 65  duction 4 of the
5f80: 20 6f 66 20 74 68 65 20 3c 72 65 66 20 68 72 65   of the <ref hre
5f90: 66 3d 22 68 74 74 70 3a 2f 2f 77 77 77 2e 77 33  f="http://www.w3
5fa0: 2e 6f 72 67 2f 54 52 2f 31 39 39 39 2f 52 45 43  .org/TR/1999/REC
5fb0: 2d 78 6d 6c 2d 6e 61 6d 65 73 2d 31 39 39 39 30  -xml-names-19990
5fc0: 31 31 34 22 3e 4e 61 6d 65 73 70 61 63 65 73 20  114">Namespaces 
5fd0: 69 6e 20 58 4d 4c 3c 2f 72 65 66 3e 20 72 65 63  in XML</ref> rec
5fe0: 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68  ommendation. Oth
5ff0: 65 72 77 69 73 65 20 69 74 20 72 65 74 75 72 6e  erwise it return
6000: 73 0a 30 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20  s.0.</desc>.    
6010: 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66      </commanddef
6020: 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d  >..        <comm
6030: 61 6e 64 64 65 66 3e 0a 20 20 20 20 20 20 20 20  anddef>.        
6040: 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e    <command><cmd>
6050: 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f  dom</cmd> <metho
6060: 64 3e 69 73 51 4e 61 6d 65 3c 2f 6d 65 74 68 6f  d>isQName</metho
6070: 64 3e 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d 3e 3c 2f  d> <m>name</m></
6080: 63 6f 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20  command>.       
6090: 20 20 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73     <desc>Returns
60a0: 20 31 20 69 66 20 3c 6d 3e 6e 61 6d 65 3c 2f 6d   1 if <m>name</m
60b0: 3e 20 69 73 20 61 20 76 61 6c 69 64 20 51 4e 61  > is a valid QNa
60c0: 6d 65 20 61 63 63 6f 72 64 69 6e 67 0a 74 6f 20  me according.to 
60d0: 70 72 6f 64 75 63 74 69 6f 6e 20 36 20 6f 66 20  production 6 of 
60e0: 74 68 65 20 6f 66 20 74 68 65 20 3c 72 65 66 20  the of the <ref 
60f0: 68 72 65 66 3d 22 68 74 74 70 3a 2f 2f 77 77 77  href="http://www
6100: 2e 77 33 2e 6f 72 67 2f 54 52 2f 31 39 39 39 2f  .w3.org/TR/1999/
6110: 52 45 43 2d 78 6d 6c 2d 6e 61 6d 65 73 2d 31 39  REC-xml-names-19
6120: 39 39 30 31 31 34 22 3e 4e 61 6d 65 73 70 61 63  990114">Namespac
6130: 65 73 20 69 6e 20 58 4d 4c 3c 2f 72 65 66 3e 20  es in XML</ref> 
6140: 72 65 63 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e 20  recommendation. 
6150: 4f 74 68 65 72 77 69 73 65 20 69 74 20 72 65 74  Otherwise it ret
6160: 75 72 6e 73 0a 30 2e 3c 2f 64 65 73 63 3e 0a 20  urns.0.</desc>. 
6170: 20 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64         </command
6180: 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63  def>..        <c
6190: 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20  ommanddef>.     
61a0: 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63       <command><c
61b0: 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65  md>dom</cmd> <me
61c0: 74 68 6f 64 3e 69 73 43 68 61 72 44 61 74 61 3c  thod>isCharData<
61d0: 2f 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 73 74 72 69  /method>.<m>stri
61e0: 6e 67 3c 2f 6d 3e 3c 2f 63 6f 6d 6d 61 6e 64 3e  ng</m></command>
61f0: 0a 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63  .          <desc
6200: 3e 52 65 74 75 72 6e 73 20 31 20 69 66 20 65 76  >Returns 1 if ev
6210: 65 72 79 20 63 68 61 72 61 63 74 65 72 20 69 6e  ery character in
6220: 20 3c 6d 3e 73 74 72 69 6e 67 3c 2f 6d 3e 20 69   <m>string</m> i
6230: 73 0a 61 20 76 61 6c 69 64 20 58 4d 4c 20 43 68  s.a valid XML Ch
6240: 61 72 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20  ar according to 
6250: 70 72 6f 64 75 63 74 69 6f 6e 20 32 20 6f 66 20  production 2 of 
6260: 74 68 65 20 3c 72 65 66 20 68 72 65 66 3d 22 68  the <ref href="h
6270: 74 74 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67  ttp://www.w3.org
6280: 2f 54 52 2f 32 30 30 30 2f 52 45 43 2d 78 6d 6c  /TR/2000/REC-xml
6290: 2d 32 30 30 30 31 30 30 36 2e 68 74 6d 6c 22 3e  -20001006.html">
62a0: 58 4d 4c 20 31 2e 30 3c 2f 72 65 66 3e 0a 72 65  XML 1.0</ref>.re
62b0: 63 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e 20 4f 74  commendation. Ot
62c0: 68 65 72 77 69 73 65 20 69 74 20 72 65 74 75 72  herwise it retur
62d0: 6e 73 20 30 2e 3c 2f 64 65 73 63 3e 0a 20 20 20  ns 0.</desc>.   
62e0: 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65       </commandde
62f0: 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63 6f 6d  f>..        <com
6300: 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20 20 20  manddef>.       
6310: 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64     <command><cmd
6320: 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68  >dom</cmd> <meth
6330: 6f 64 3e 69 73 42 4d 50 43 68 61 72 44 61 74 61  od>isBMPCharData
6340: 3c 2f 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 73 74 72  </method>.<m>str
6350: 69 6e 67 3c 2f 6d 3e 3c 2f 63 6f 6d 6d 61 6e 64  ing</m></command
6360: 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 65 73  >.          <des
6370: 63 3e 52 65 74 75 72 6e 73 20 31 20 69 66 20 65  c>Returns 1 if e
6380: 76 65 72 79 20 63 68 61 72 61 63 74 65 72 20 69  very character i
6390: 6e 20 3c 6d 3e 73 74 72 69 6e 67 3c 2f 6d 3e 20  n <m>string</m> 
63a0: 69 73 0a 61 20 76 61 6c 69 64 20 58 4d 4c 20 43  is.a valid XML C
63b0: 68 61 72 20 77 69 74 68 20 61 20 55 6e 69 63 6f  har with a Unico
63c0: 64 65 20 63 6f 64 65 20 70 6f 69 6e 74 20 77 69  de code point wi
63d0: 74 68 69 6e 20 74 68 65 20 42 61 73 69 63 0a 4d  thin the Basic.M
63e0: 75 6c 74 69 6c 69 6e 67 75 61 6c 20 50 6c 61 6e  ultilingual Plan
63f0: 65 20 28 74 68 61 74 20 6d 65 61 6e 73 2c 20 74  e (that means, t
6400: 68 61 74 20 65 76 65 72 79 20 63 68 61 72 61 63  hat every charac
6410: 74 65 72 20 77 69 74 68 69 6e 20 74 68 65 20 73  ter within the s
6420: 74 72 69 6e 67 0a 69 73 20 61 74 20 6d 6f 73 74  tring.is at most
6430: 20 33 20 62 79 74 65 73 20 6c 6f 6e 67 29 2e 20   3 bytes long). 
6440: 4f 74 68 65 72 77 69 73 65 20 69 74 20 72 65 74  Otherwise it ret
6450: 75 72 6e 73 20 30 2e 3c 2f 64 65 73 63 3e 0a 20  urns 0.</desc>. 
6460: 20 20 20 20 20 20 20 3c 2f 63 6f 6d 6d 61 6e 64         </command
6470: 64 65 66 3e 0a 0a 20 20 20 20 20 20 20 20 3c 63  def>..        <c
6480: 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20 20 20 20  ommanddef>.     
6490: 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 3e 3c 63       <command><c
64a0: 6d 64 3e 64 6f 6d 3c 2f 63 6d 64 3e 20 3c 6d 65  md>dom</cmd> <me
64b0: 74 68 6f 64 3e 69 73 43 6f 6d 6d 65 6e 74 3c 2f  thod>isComment</
64c0: 6d 65 74 68 6f 64 3e 0a 3c 6d 3e 73 74 72 69 6e  method>.<m>strin
64d0: 67 3c 2f 6d 3e 3c 2f 63 6f 6d 6d 61 6e 64 3e 0a  g</m></command>.
64e0: 20 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e            <desc>
64f0: 52 65 74 75 72 6e 73 20 31 20 69 66 20 3c 6d 3e  Returns 1 if <m>
6500: 73 74 72 69 6e 67 3c 2f 6d 3e 20 69 73 0a 61 20  string</m> is.a 
6510: 76 61 6c 69 64 20 63 6f 6d 6d 65 6e 74 20 61 63  valid comment ac
6520: 63 6f 72 64 69 6e 67 20 74 6f 20 70 72 6f 64 75  cording to produ
6530: 63 74 69 6f 6e 20 31 35 20 6f 66 20 74 68 65 20  ction 15 of the 
6540: 3c 72 65 66 20 68 72 65 66 3d 22 68 74 74 70 3a  <ref href="http:
6550: 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52 2f  //www.w3.org/TR/
6560: 32 30 30 30 2f 52 45 43 2d 78 6d 6c 2d 32 30 30  2000/REC-xml-200
6570: 30 31 30 30 36 2e 68 74 6d 6c 22 3e 58 4d 4c 20  01006.html">XML 
6580: 31 2e 30 3c 2f 72 65 66 3e 0a 72 65 63 6f 6d 6d  1.0</ref>.recomm
6590: 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77  endation. Otherw
65a0: 69 73 65 20 69 74 20 72 65 74 75 72 6e 73 20 30  ise it returns 0
65b0: 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20  .</desc>.       
65c0: 20 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 0a   </commanddef>..
65d0: 20 20 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64          <command
65e0: 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 3c  def>.          <
65f0: 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d  command><cmd>dom
6600: 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 69  </cmd> <method>i
6610: 73 43 44 41 54 41 3c 2f 6d 65 74 68 6f 64 3e 0a  sCDATA</method>.
6620: 3c 6d 3e 73 74 72 69 6e 67 3c 2f 6d 3e 3c 2f 63  <m>string</m></c
6630: 6f 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20  ommand>.        
6640: 20 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73 20    <desc>Returns 
6650: 31 20 69 66 20 3c 6d 3e 73 74 72 69 6e 67 3c 2f  1 if <m>string</
6660: 6d 3e 20 69 73 0a 76 61 6c 69 64 20 61 63 63 6f  m> is.valid acco
6670: 72 64 69 6e 67 20 74 6f 20 70 72 6f 64 75 63 74  rding to product
6680: 69 6f 6e 20 32 30 20 6f 66 20 74 68 65 20 3c 72  ion 20 of the <r
6690: 65 66 20 68 72 65 66 3d 22 68 74 74 70 3a 2f 2f  ef href="http://
66a0: 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52 2f 32 30  www.w3.org/TR/20
66b0: 30 30 2f 52 45 43 2d 78 6d 6c 2d 32 30 30 30 31  00/REC-xml-20001
66c0: 30 30 36 2e 68 74 6d 6c 22 3e 58 4d 4c 20 31 2e  006.html">XML 1.
66d0: 30 3c 2f 72 65 66 3e 0a 72 65 63 6f 6d 6d 65 6e  0</ref>.recommen
66e0: 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77 69 73  dation. Otherwis
66f0: 65 20 69 74 20 72 65 74 75 72 6e 73 20 30 2e 3c  e it returns 0.<
6700: 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20 3c  /desc>.        <
6710: 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 0a 20 20  /commanddef>..  
6720: 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 64 65        <commandde
6730: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 63 6f  f>.          <co
6740: 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d 3c 2f  mmand><cmd>dom</
6750: 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 69 73 50  cmd> <method>isP
6760: 49 56 61 6c 75 65 3c 2f 6d 65 74 68 6f 64 3e 0a  IValue</method>.
6770: 3c 6d 3e 73 74 72 69 6e 67 3c 2f 6d 3e 3c 2f 63  <m>string</m></c
6780: 6f 6d 6d 61 6e 64 3e 0a 20 20 20 20 20 20 20 20  ommand>.        
6790: 20 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73 20    <desc>Returns 
67a0: 31 20 69 66 20 3c 6d 3e 73 74 72 69 6e 67 3c 2f  1 if <m>string</
67b0: 6d 3e 20 69 73 0a 76 61 6c 69 64 20 61 63 63 6f  m> is.valid acco
67c0: 72 64 69 6e 67 20 74 6f 20 70 72 6f 64 75 63 74  rding to product
67d0: 69 6f 6e 20 31 36 20 6f 66 20 74 68 65 20 3c 72  ion 16 of the <r
67e0: 65 66 20 68 72 65 66 3d 22 68 74 74 70 3a 2f 2f  ef href="http://
67f0: 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52 2f 32 30  www.w3.org/TR/20
6800: 30 30 2f 52 45 43 2d 78 6d 6c 2d 32 30 30 30 31  00/REC-xml-20001
6810: 30 30 36 2e 68 74 6d 6c 22 3e 58 4d 4c 20 31 2e  006.html">XML 1.
6820: 30 3c 2f 72 65 66 3e 0a 72 65 63 6f 6d 6d 65 6e  0</ref>.recommen
6830: 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77 69 73  dation. Otherwis
6840: 65 20 69 74 20 72 65 74 75 72 6e 73 20 30 2e 3c  e it returns 0.<
6850: 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20 3c  /desc>.        <
6860: 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 0a 20 20  /commanddef>..  
6870: 20 20 20 20 20 20 3c 63 6f 6d 6d 61 6e 64 64 65        <commandde
6880: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c  f>.            <
6890: 63 6f 6d 6d 61 6e 64 3e 3c 63 6d 64 3e 64 6f 6d  command><cmd>dom
68a0: 3c 2f 63 6d 64 3e 20 3c 6d 65 74 68 6f 64 3e 66  </cmd> <method>f
68b0: 65 61 74 75 72 65 69 6e 66 6f 3c 2f 6d 65 74 68  eatureinfo</meth
68c0: 6f 64 3e 20 3c 6d 3e 66 65 61 74 75 72 65 3c 2f  od> <m>feature</
68d0: 6d 3e 3c 2f 63 6f 6d 6d 61 6e 64 3e 0a 20 20 20  m></command>.   
68e0: 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 54           <desc>T
68f0: 68 69 73 20 6d 65 74 68 6f 64 20 70 72 6f 76 69  his method provi
6900: 64 65 73 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 20  des information 
6910: 61 62 6f 75 74 20 74 68 65 20 75 73 65 64 0a 20  about the used. 
6920: 20 20 20 20 20 20 20 20 20 20 20 62 75 69 6c 64             build
6930: 20 6f 70 74 69 6f 6e 73 20 61 6e 64 20 74 68 65   options and the
6940: 20 65 78 70 61 74 20 76 65 72 73 69 6f 6e 2e 20   expat version. 
6950: 54 68 65 20 76 61 6c 69 64 20 76 61 6c 75 65 73  The valid values
6960: 20 66 6f 72 0a 20 20 20 20 20 20 20 20 20 20 20   for.           
6970: 20 74 68 65 20 3c 6d 3e 66 65 61 74 75 72 65 3c   the <m>feature<
6980: 2f 6d 3e 20 61 72 67 75 6d 65 6e 74 20 61 72 65  /m> argument are
6990: 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f  :.            <o
69a0: 70 74 6c 69 73 74 3e 0a 20 20 20 20 20 20 20 20  ptlist>.        
69b0: 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e          <optdef>
69c0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
69d0: 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 65 78       <optname>ex
69e0: 70 61 74 76 65 72 73 69 6f 6e 3c 2f 6f 70 74 6e  patversion</optn
69f0: 61 6d 65 3e 0a 20 20 20 20 20 20 20 20 20 20 20  ame>.           
6a00: 20 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 52           <desc>R
6a10: 65 74 75 72 6e 73 20 74 68 65 20 76 65 72 73 69  eturns the versi
6a20: 6f 6e 20 6f 66 20 74 68 65 20 75 6e 64 65 72 6c  on of the underl
6a30: 79 6c 69 6e 67 20 65 78 70 61 74 0a 20 20 20 20  yling expat.    
6a40: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6a50: 76 65 72 73 69 6f 6e 20 61 73 20 73 74 72 69 6e  version as strin
6a60: 67 2c 20 73 6f 6d 65 74 68 69 6e 67 20 6c 69 6b  g, something lik
6a70: 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  e.              
6a80: 20 20 20 20 20 20 22 65 78 61 70 74 5f 32 2e 31        "exapt_2.1
6a90: 2e 30 22 2e 20 54 68 69 73 20 69 73 20 77 68 61  .0". This is wha
6aa0: 74 20 74 68 65 20 65 78 70 61 74 20 41 50 49 0a  t the expat API.
6ab0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6ac0: 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 58 4d 4c      function XML
6ad0: 5f 45 78 70 61 74 56 65 72 73 69 6f 6e 28 29 20  _ExpatVersion() 
6ae0: 72 65 74 75 72 6e 73 2e 3c 2f 64 65 73 63 3e 0a  returns.</desc>.
6af0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6b00: 3c 2f 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20  </optdef>.      
6b10: 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65            <optde
6b20: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  f>.             
6b30: 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e         <optname>
6b40: 65 78 70 61 74 6d 61 6a 6f 72 76 65 72 73 69 6f  expatmajorversio
6b50: 6e 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20  n</optname>.    
6b60: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6b70: 3c 64 65 73 63 3e 52 65 74 75 72 6e 73 20 74 68  <desc>Returns th
6b80: 65 20 6d 61 6a 6f 72 20 76 65 72 73 69 6f 6e 20  e major version 
6b90: 6f 66 20 74 68 65 20 61 74 20 62 75 69 6c 64 0a  of the at build.
6ba0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6bb0: 20 20 20 20 74 69 6d 65 20 75 73 65 64 20 65 78      time used ex
6bc0: 70 61 74 20 76 65 72 73 69 6f 6e 20 61 73 20 69  pat version as i
6bd0: 6e 74 65 67 65 72 2e 3c 2f 64 65 73 63 3e 0a 20  nteger.</desc>. 
6be0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
6bf0: 2f 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20  /optdef>.       
6c00: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66           <optdef
6c10: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
6c20: 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 65        <optname>e
6c30: 78 70 61 74 6d 69 6e 6f 72 76 65 72 73 69 6f 6e  xpatminorversion
6c40: 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20  </optname>.     
6c50: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
6c60: 64 65 73 63 3e 52 65 74 75 72 6e 73 20 74 68 65  desc>Returns the
6c70: 20 6d 69 6e 6f 72 20 76 65 72 73 69 6f 6e 20 6f   minor version o
6c80: 66 20 74 68 65 20 61 74 20 62 75 69 6c 64 0a 20  f the at build. 
6c90: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6ca0: 20 20 20 74 69 6d 65 20 75 73 65 64 20 65 78 70     time used exp
6cb0: 61 74 20 76 65 72 73 69 6f 6e 20 61 73 20 69 6e  at version as in
6cc0: 74 65 67 65 72 2e 3c 2f 64 65 73 63 3e 0a 20 20  teger.</desc>.  
6cd0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f                </
6ce0: 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20  optdef>.        
6cf0: 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e          <optdef>
6d00: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
6d10: 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 65 78       <optname>ex
6d20: 70 61 74 6d 69 63 72 6f 76 65 72 73 69 6f 6e 3c  patmicroversion<
6d30: 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20 20  /optname>.      
6d40: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64                <d
6d50: 65 73 63 3e 52 65 74 75 72 6e 73 20 74 68 65 20  esc>Returns the 
6d60: 6d 69 63 72 6f 20 76 65 72 73 69 6f 6e 20 6f 66  micro version of
6d70: 20 74 68 65 20 61 74 20 62 75 69 6c 64 0a 20 20   the at build.  
6d80: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6d90: 20 20 74 69 6d 65 20 75 73 65 64 20 65 78 70 61    time used expa
6da0: 74 20 76 65 72 73 69 6f 6e 20 61 73 20 69 6e 74  t version as int
6db0: 65 67 65 72 2e 3c 2f 64 65 73 63 3e 0a 20 20 20  eger.</desc>.   
6dc0: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f               </o
6dd0: 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20  ptdef>.         
6de0: 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a         <optdef>.
6df0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6e00: 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 64 74 64      <optname>dtd
6e10: 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20  </optname>.     
6e20: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
6e30: 64 65 73 63 3e 52 65 74 75 72 6e 73 20 61 73 20  desc>Returns as 
6e40: 62 6f 6f 6c 65 61 6e 20 69 66 20 62 75 69 6c 64  boolean if build
6e50: 20 77 69 74 68 0a 20 20 20 20 20 20 20 20 20 20   with.          
6e60: 20 20 20 20 20 20 20 20 20 20 3c 6d 3e 2d 2d 65            <m>--e
6e70: 6e 61 62 6c 65 2d 64 74 64 3c 2f 6d 3e 2e 3c 2f  nable-dtd</m>.</
6e80: 64 65 73 63 3e 0a 20 20 20 20 20 20 20 20 20 20  desc>.          
6e90: 20 20 20 20 20 20 3c 2f 6f 70 74 64 65 66 3e 0a        </optdef>.
6ea0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6eb0: 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20  <optdef>.       
6ec0: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70               <op
6ed0: 74 6e 61 6d 65 3e 6e 73 3c 2f 6f 70 74 6e 61 6d  tname>ns</optnam
6ee0: 65 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  e>.             
6ef0: 20 20 20 20 20 20 20 3c 64 65 73 63 3e 52 65 74         <desc>Ret
6f00: 75 72 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 20  urns as boolean 
6f10: 69 66 20 62 75 69 6c 64 20 77 69 74 68 0a 20 20  if build with.  
6f20: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6f30: 20 20 3c 6d 3e 2d 2d 65 6e 61 62 6c 65 2d 6e 73    <m>--enable-ns
6f40: 3c 2f 6d 3e 2e 3c 2f 64 65 73 63 3e 0a 20 20 20  </m>.</desc>.   
6f50: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f               </o
6f60: 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20  ptdef>.         
6f70: 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a         <optdef>.
6f80: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6f90: 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 75 6e 6b      <optname>unk
6fa0: 6e 6f 77 6e 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20  nown</optname>. 
6fb0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
6fc0: 20 20 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73     <desc>Returns
6fd0: 20 61 73 20 62 6f 6f 6c 65 61 6e 20 69 66 20 62   as boolean if b
6fe0: 75 69 6c 64 20 77 69 74 68 0a 20 20 20 20 20 20  uild with.      
6ff0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6d                <m
7000: 3e 2d 2d 65 6e 61 62 6c 65 2d 75 6e 6b 6e 6f 77  >--enable-unknow
7010: 6e 3c 2f 6d 3e 2e 3c 2f 64 65 73 63 3e 0a 20 20  n</m>.</desc>.  
7020: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f                </
7030: 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20  optdef>.        
7040: 20 20 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e          <optdef>
7050: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
7060: 20 20 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 74 64       <optname>td
7070: 6f 6d 61 6c 6c 6f 63 3c 2f 6f 70 74 6e 61 6d 65  omalloc</optname
7080: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
7090: 20 20 20 20 20 20 3c 64 65 73 63 3e 52 65 74 75        <desc>Retu
70a0: 72 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 20 69  rns as boolean i
70b0: 66 20 62 75 69 6c 64 20 77 69 74 68 0a 20 20 20  f build with.   
70c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
70d0: 20 3c 6d 3e 2d 2d 65 6e 61 62 6c 65 2d 74 64 6f   <m>--enable-tdo
70e0: 6d 61 6c 6c 6f 63 3c 2f 6d 3e 2e 3c 2f 64 65 73  malloc</m>.</des
70f0: 63 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  c>.             
7100: 20 20 20 3c 2f 6f 70 74 64 65 66 3e 0a 20 20 20     </optdef>.   
7110: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70               <op
7120: 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20  tdef>.          
7130: 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61            <optna
7140: 6d 65 3e 6c 65 73 73 6e 73 3c 2f 6f 70 74 6e 61  me>lessns</optna
7150: 6d 65 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20  me>.            
7160: 20 20 20 20 20 20 20 20 3c 64 65 73 63 3e 52 65          <desc>Re
7170: 74 75 72 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e  turns as boolean
7180: 20 69 66 20 62 75 69 6c 64 20 77 69 74 68 0a 20   if build with. 
7190: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
71a0: 20 20 20 3c 6d 3e 2d 2d 65 6e 61 62 6c 65 2d 6c     <m>--enable-l
71b0: 65 73 73 6e 73 3c 2f 6d 3e 2e 3c 2f 64 65 73 63  essns</m>.</desc
71c0: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20  >.              
71d0: 20 20 3c 2f 6f 70 74 64 65 66 3e 0a 20 20 20 20    </optdef>.    
71e0: 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 70 74              <opt
71f0: 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20  def>.           
7200: 20 20 20 20 20 20 20 20 20 3c 6f 70 74 6e 61 6d           <optnam
7210: 65 3e 54 43 4c 5f 55 54 46 5f 4d 41 58 3c 2f 6f  e>TCL_UTF_MAX</o
7220: 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20 20 20 20  ptname>.        
7230: 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 65 73              <des
7240: 63 3e 52 65 74 75 72 6e 73 20 74 68 65 20 54 43  c>Returns the TC
7250: 4c 5f 55 54 46 5f 4d 41 58 20 76 61 6c 75 65 20  L_UTF_MAX value 
7260: 6f 66 20 74 68 65 20 74 63 6c 0a 20 20 20 20 20  of the tcl.     
7270: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63                 c
7280: 6f 72 65 2c 20 74 44 4f 4d 20 77 61 73 20 62 75  ore, tDOM was bu
7290: 69 6c 64 20 77 69 74 68 20 61 73 20 69 6e 74 65  ild with as inte
72a0: 67 65 72 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20  ger</desc>.     
72b0: 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74             </opt
72c0: 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20  def>.           
72d0: 20 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20       <optdef>.  
72e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
72f0: 20 20 3c 6f 70 74 6e 61 6d 65 3e 68 74 6d 6c 35    <optname>html5
7300: 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20 20 20 20 20  </optname>.     
7310: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c                 <
7320: 64 65 73 63 3e 52 65 74 75 72 6e 73 20 61 73 20  desc>Returns as 
7330: 62 6f 6f 6c 65 61 6e 2c 20 69 66 20 62 75 69 6c  boolean, if buil
7340: 64 20 77 69 74 68 0a 20 20 20 20 20 20 20 20 20  d with.         
7350: 20 20 20 20 20 20 20 20 20 20 20 3c 6d 3e 2d 2d             <m>--
7360: 65 6e 61 62 6c 65 2d 68 74 6d 6c 35 3c 2f 6d 3e  enable-html5</m>
7370: 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20 20 20 20  .</desc>.       
7380: 20 20 20 20 20 20 20 20 20 3c 2f 6f 70 74 64 65           </optde
7390: 66 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20  f>.             
73a0: 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20 20 20 20     <optdef>.    
73b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
73c0: 3c 6f 70 74 6e 61 6d 65 3e 76 65 72 73 69 6f 6e  <optname>version
73d0: 68 61 73 68 3c 2f 6f 70 74 6e 61 6d 65 3e 0a 20  hash</optname>. 
73e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
73f0: 20 20 20 3c 64 65 73 63 3e 52 65 74 75 72 6e 73     <desc>Returns
7400: 20 74 68 65 20 66 6f 73 73 69 6c 20 72 65 70 6f   the fossil repo
7410: 73 69 74 6f 72 79 20 76 65 72 73 69 6f 6e 20 68  sitory version h
7420: 61 73 68 2e 3c 2f 64 65 73 63 3e 0a 20 20 20 20  ash.</desc>.    
7430: 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 6f 70              </op
7440: 74 64 65 66 3e 0a 20 20 20 20 20 20 20 20 20 20  tdef>.          
7450: 20 20 20 20 20 20 3c 6f 70 74 64 65 66 3e 0a 20        <optdef>. 
7460: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
7470: 20 20 20 3c 6f 70 74 6e 61 6d 65 3e 70 75 6c 6c     <optname>pull
7480: 70 61 72 73 65 72 3c 2f 6f 70 74 6e 61 6d 65 3e  parser</optname>
7490: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20  .               
74a0: 20 20 20 20 20 3c 64 65 73 63 3e 52 65 74 75 72       <desc>Retur
74b0: 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 20 69 66  ns as boolean if
74c0: 20 74 68 65 20 70 75 6c 6c 70 61 72 73 65 72 20   the pullparser 
74d0: 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 20 20 20  command.        
74e0: 20 20 20 20 20 20 20 20 20 20 20 20 69 73 20 62              is b
74f0: 75 69 6c 64 20 69 6e 2e 3c 2f 64 65 73 63 3e 0a  uild in.</desc>.
7500: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20                  
7510: 3c 2f 6f 70 74 64 65 66 3e 0a 20 20 20 20 20 20  </optdef>.      
7520: 20 20 20 20 20 20 3c 2f 6f 70 74 6c 69 73 74 3e        </optlist>
7530: 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 64  .            </d
7540: 65 73 63 3e 20 20 20 0a 20 20 20 20 20 20 20 20  esc>   .        
7550: 3c 2f 63 6f 6d 6d 61 6e 64 64 65 66 3e 0a 20 20  </commanddef>.  
7560: 20 20 3c 2f 63 6f 6d 6d 61 6e 64 6c 69 73 74 3e    </commandlist>
7570: 0a 3c 2f 73 65 63 74 69 6f 6e 3e 0a 0a 3c 6b 65  .</section>..<ke
7580: 79 77 6f 72 64 73 3e 0a 20 20 20 20 3c 6b 65 79  ywords>.    <key
7590: 77 6f 72 64 3e 58 4d 4c 3c 2f 6b 65 79 77 6f 72  word>XML</keywor
75a0: 64 3e 0a 20 20 20 20 3c 6b 65 79 77 6f 72 64 3e  d>.    <keyword>
75b0: 44 4f 4d 3c 2f 6b 65 79 77 6f 72 64 3e 0a 20 20  DOM</keyword>.  
75c0: 20 20 3c 6b 65 79 77 6f 72 64 3e 64 6f 63 75 6d    <keyword>docum
75d0: 65 6e 74 3c 2f 6b 65 79 77 6f 72 64 3e 0a 20 20  ent</keyword>.  
75e0: 20 20 3c 6b 65 79 77 6f 72 64 3e 6e 6f 64 65 3c    <keyword>node<
75f0: 2f 6b 65 79 77 6f 72 64 3e 0a 20 20 20 20 3c 6b  /keyword>.    <k
7600: 65 79 77 6f 72 64 3e 70 61 72 73 69 6e 67 3c 2f  eyword>parsing</
7610: 6b 65 79 77 6f 72 64 3e 0a 3c 2f 6b 65 79 77 6f  keyword>.</keywo
7620: 72 64 73 3e 0a 3c 2f 6d 61 6e 70 61 67 65 3e 0a  rds>.</manpage>.