0000: 3c 68 74 6d 6c 3e 0a 3c 68 65 61 64 3e 0a 3c 6c <html>.<head>.<l
0010: 69 6e 6b 20 72 65 6c 3d 22 73 74 79 6c 65 73 68 ink rel="stylesh
0020: 65 65 74 22 20 68 72 65 66 3d 22 6d 61 6e 70 61 eet" href="manpa
0030: 67 65 2e 63 73 73 22 3e 3c 74 69 74 6c 65 3e 74 ge.css"><title>t
0040: 44 4f 4d 20 6d 61 6e 75 61 6c 3a 20 64 6f 6d 3c DOM manual: dom<
0050: 2f 74 69 74 6c 65 3e 3c 6d 65 74 61 20 6e 61 6d /title><meta nam
0060: 65 3d 22 78 73 6c 2d 70 72 6f 63 65 73 73 6f 72 e="xsl-processor
0070: 22 20 63 6f 6e 74 65 6e 74 3d 22 4a 6f 63 68 65 " content="Joche
0080: 6e 20 4c 6f 65 77 65 72 20 28 6c 6f 65 77 65 72 n Loewer (loewer
0090: 6a 40 68 6f 74 6d 61 69 6c 2e 63 6f 6d 29 2c 20 j@hotmail.com),
00a0: 52 6f 6c 66 20 41 64 65 20 28 72 6f 6c 66 40 70 Rolf Ade (rolf@p
00b0: 6f 69 6e 74 73 6d 61 6e 2e 64 65 29 20 65 74 2e ointsman.de) et.
00c0: 20 61 6c 2e 22 3e 3c 6d 65 74 61 20 6e 61 6d 65 al."><meta name
00d0: 3d 22 67 65 6e 65 72 61 74 6f 72 22 20 63 6f 6e ="generator" con
00e0: 74 65 6e 74 3d 22 24 52 43 53 66 69 6c 65 3a 20 tent="$RCSfile:
00f0: 74 6d 6d 6c 2d 68 74 6d 6c 2e 78 73 6c 2c 76 20 tmml-html.xsl,v
0100: 24 20 24 52 65 76 69 73 69 6f 6e 3a 20 31 2e 31 $ $Revision: 1.1
0110: 31 20 24 22 3e 3c 6d 65 74 61 20 63 68 61 72 73 1 $"><meta chars
0120: 65 74 3d 22 75 74 66 2d 38 22 3e 0a 3c 2f 68 65 et="utf-8">.</he
0130: 61 64 3e 3c 62 6f 64 79 3e 0a 3c 64 69 76 20 63 ad><body>.<div c
0140: 6c 61 73 73 3d 22 68 65 61 64 65 72 22 3e 0a 3c lass="header">.<
0150: 64 69 76 20 63 6c 61 73 73 3d 22 6e 61 76 62 61 div class="navba
0160: 72 22 20 61 6c 69 67 6e 3d 22 63 65 6e 74 65 72 r" align="center
0170: 22 3e 0a 3c 61 20 68 72 65 66 3d 22 23 53 45 43 ">.<a href="#SEC
0180: 54 69 64 30 78 31 38 32 64 39 36 30 22 3e 4e 41 Tid0x182d960">NA
0190: 4d 45 3c 2f 61 3e 20 c2 b7 20 3c 61 20 68 72 65 ME</a> · <a hre
01a0: 66 3d 22 23 53 45 43 54 69 64 30 78 31 37 64 65 f="#SECTid0x17de
01b0: 65 62 30 22 3e 53 59 4e 4f 50 53 49 53 3c 2f 61 eb0">SYNOPSIS</a
01c0: 3e 20 c2 b7 20 3c 61 20 68 72 65 66 3d 22 23 53 > · <a href="#S
01d0: 45 43 54 69 64 30 78 31 37 33 30 64 34 30 22 3e ECTid0x1730d40">
01e0: 44 45 53 43 52 49 50 54 49 4f 4e 20 3c 2f 61 3e DESCRIPTION </a>
01f0: 20 c2 b7 20 3c 61 20 68 72 65 66 3d 22 23 53 45 · <a href="#SE
0200: 43 54 69 64 30 78 31 38 37 39 62 35 30 22 3e 4b CTid0x1879b50">K
0210: 45 59 57 4f 52 44 53 3c 2f 61 3e 0a 3c 2f 64 69 EYWORDS</a>.</di
0220: 76 3e 3c 68 72 20 63 6c 61 73 73 3d 22 6e 61 76 v><hr class="nav
0230: 73 65 70 22 3e 0a 3c 2f 64 69 76 3e 3c 64 69 76 sep">.</div><div
0240: 20 63 6c 61 73 73 3d 22 62 6f 64 79 22 3e 0a 20 class="body">.
0250: 20 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 53 45 <h2><a name="SE
0260: 43 54 69 64 30 78 31 38 32 64 39 36 30 22 3e 4e CTid0x182d960">N
0270: 41 4d 45 3c 2f 61 3e 3c 2f 68 32 3e 3c 70 20 63 AME</a></h2><p c
0280: 6c 61 73 73 3d 22 6e 61 6d 65 73 65 63 74 69 6f lass="namesectio
0290: 6e 22 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 6e 61 n">.<b class="na
02a0: 6d 65 73 22 3e 64 6f 6d 20 2d 20 3c 2f 62 3e 3c mes">dom - </b><
02b0: 62 72 3e 43 72 65 61 74 65 20 61 6e 20 69 6e 2d br>Create an in-
02c0: 6d 65 6d 6f 72 79 20 44 4f 4d 20 74 72 65 65 20 memory DOM tree
02d0: 66 72 6f 6d 20 58 4d 4c 3c 2f 70 3e 0a 20 20 0a from XML</p>. .
02e0: 20 20 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 53 <h2><a name="S
02f0: 45 43 54 69 64 30 78 31 37 64 65 65 62 30 22 3e ECTid0x17deeb0">
0300: 53 59 4e 4f 50 53 49 53 3c 2f 61 3e 3c 2f 68 32 SYNOPSIS</a></h2
0310: 3e 3c 70 72 65 20 63 6c 61 73 73 3d 22 73 79 6e ><pre class="syn
0320: 74 61 78 22 3e 70 61 63 6b 61 67 65 20 72 65 71 tax">package req
0330: 75 69 72 65 20 74 64 6f 6d 0a 0a 3c 62 20 63 6c uire tdom..<b cl
0340: 61 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 ass="cmd">dom</b
0350: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 6d > <i class="m">m
0360: 65 74 68 6f 64 3c 2f 69 3e 20 3f 3c 69 20 63 6c ethod</i> ?<i cl
0370: 61 73 73 3d 22 6d 22 3e 61 72 67 20 61 72 67 20 ass="m">arg arg
0380: 2e 2e 2e 3c 2f 69 3e 3f 3c 2f 70 72 65 3e 0a 0a ...</i>?</pre>..
0390: 20 20 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 53 <h2><a name="S
03a0: 45 43 54 69 64 30 78 31 37 33 30 64 34 30 22 3e ECTid0x1730d40">
03b0: 44 45 53 43 52 49 50 54 49 4f 4e 20 3c 2f 61 3e DESCRIPTION </a>
03c0: 3c 2f 68 32 3e 3c 70 3e 54 68 69 73 20 63 6f 6d </h2><p>This com
03d0: 6d 61 6e 64 20 70 72 6f 76 69 64 65 73 20 74 68 mand provides th
03e0: 65 20 63 72 65 61 74 69 6f 6e 20 6f 66 20 44 4f e creation of DO
03f0: 4d 20 74 72 65 65 73 20 69 6e 20 6d 65 6d 6f 72 M trees in memor
0400: 79 2e 20 49 6e 0a 74 68 65 20 75 73 75 61 6c 20 y. In.the usual
0410: 63 61 73 65 20 61 20 73 74 72 69 6e 67 20 63 6f case a string co
0420: 6e 74 61 69 6e 69 6e 67 20 61 20 58 4d 4c 20 69 ntaining a XML i
0430: 6e 66 6f 72 6d 61 74 69 6f 6e 20 69 73 20 70 61 nformation is pa
0440: 72 73 65 64 20 61 6e 64 20 63 6f 6e 76 65 72 74 rsed and convert
0450: 65 64 0a 69 6e 74 6f 20 61 20 44 4f 4d 20 74 72 ed.into a DOM tr
0460: 65 65 2e 20 4f 74 68 65 72 20 70 6f 73 73 69 62 ee. Other possib
0470: 6c 65 20 70 61 72 73 65 20 69 6e 70 75 74 20 6d le parse input m
0480: 61 79 20 62 65 20 48 54 4d 4c 20 6f 72 20 4a 53 ay be HTML or JS
0490: 4f 4e 2e 0a 54 68 65 20 3c 69 20 63 6c 61 73 73 ON..The <i class
04a0: 3d 22 6d 22 3e 6d 65 74 68 6f 64 3c 2f 69 3e 20 ="m">method</i>
04b0: 69 6e 64 69 63 61 74 65 73 20 61 20 73 70 65 63 indicates a spec
04c0: 69 66 69 63 20 73 75 62 63 6f 6d 6d 61 6e 64 2e ific subcommand.
04d0: 20 3c 2f 70 3e 3c 70 3e 54 68 65 20 76 61 6c 69 </p><p>The vali
04e0: 64 20 6d 65 74 68 6f 64 73 20 61 72 65 3a 3c 2f d methods are:</
04f0: 70 3e 3c 64 6c 20 63 6c 61 73 73 3d 22 63 6f 6d p><dl class="com
0500: 6d 61 6e 64 6c 69 73 74 22 3e 0a 20 20 20 20 20 mandlist">.
0510: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c 64 . <d
0520: 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 t>.<b class="cmd
0530: 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 ">dom</b> <b cla
0540: 73 73 3d 22 6d 65 74 68 6f 64 22 3e 70 61 72 73 ss="method">pars
0550: 65 3c 2f 62 3e 20 3f 3c 69 20 63 6c 61 73 73 3d e</b> ?<i class=
0560: 22 6d 22 3e 6f 70 74 69 6f 6e 73 3c 2f 69 3e 3f "m">options</i>?
0570: 20 3f 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 ?<i class="m">d
0580: 61 74 61 3c 2f 69 3e 3f 3c 2f 64 74 3e 0a 20 20 ata</i>?</dt>.
0590: 20 20 20 20 20 20 20 20 3c 64 64 3e 50 61 72 73 <dd>Pars
05a0: 65 73 20 74 68 65 20 58 4d 4c 20 69 6e 66 6f 72 es the XML infor
05b0: 6d 61 74 69 6f 6e 20 61 6e 64 20 62 75 69 6c 64 mation and build
05c0: 73 20 75 70 20 74 68 65 20 44 4f 4d 20 74 72 65 s up the DOM tre
05d0: 65 20 69 6e 20 6d 65 6d 6f 72 79 0a 70 72 6f 76 e in memory.prov
05e0: 69 64 69 6e 67 20 61 20 54 63 6c 20 6f 62 6a 65 iding a Tcl obje
05f0: 63 74 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 74 68 ct command to th
0600: 69 73 20 44 4f 4d 20 64 6f 63 75 6d 65 6e 74 20 is DOM document
0610: 6f 62 6a 65 63 74 2e 20 45 78 61 6d 70 6c 65 3a object. Example:
0620: 0a 0a 20 20 20 20 20 20 3c 70 72 65 20 63 6c 61 .. <pre cla
0630: 73 73 3d 22 65 78 61 6d 70 6c 65 22 3e 0a 64 6f ss="example">.do
0640: 6d 20 70 61 72 73 65 20 24 78 6d 6c 20 64 6f 63 m parse $xml doc
0650: 0a 24 64 6f 63 20 64 6f 63 75 6d 65 6e 74 45 6c .$doc documentEl
0660: 65 6d 65 6e 74 20 72 6f 6f 74 3c 2f 70 72 65 3e ement root</pre>
0670: 0a 0a 20 20 20 20 20 20 3c 70 3e 70 61 72 73 65 .. <p>parse
0680: 73 20 74 68 65 20 58 4d 4c 20 69 6e 20 74 68 65 s the XML in the
0690: 20 76 61 72 69 61 62 6c 65 20 78 6d 6c 2c 20 63 variable xml, c
06a0: 72 65 61 74 65 73 20 74 68 65 20 44 4f 4d 20 74 reates the DOM t
06b0: 72 65 65 20 69 6e 20 6d 65 6d 6f 72 79 2c 0a 6d ree in memory,.m
06c0: 61 6b 65 20 61 20 72 65 66 65 72 65 6e 63 65 20 ake a reference
06d0: 74 6f 20 74 68 65 20 64 6f 63 75 6d 65 6e 74 20 to the document
06e0: 6f 62 6a 65 63 74 2c 20 76 69 73 69 62 6c 65 20 object, visible
06f0: 69 6e 20 54 63 6c 20 61 73 20 61 20 64 6f 63 75 in Tcl as a docu
0700: 6d 65 6e 74 20 6f 62 6a 65 63 74 0a 63 6f 6d 6d ment object.comm
0710: 61 6e 64 2c 20 61 6e 64 20 61 73 73 69 67 6e 73 and, and assigns
0720: 20 74 68 69 73 20 6e 65 77 20 6f 62 6a 65 63 74 this new object
0730: 20 6e 61 6d 65 20 74 6f 20 74 68 65 20 76 61 72 name to the var
0740: 69 61 62 6c 65 20 64 6f 63 2e 20 57 68 65 6e 20 iable doc. When
0750: 64 6f 63 20 67 65 74 73 0a 66 72 65 65 64 2c 20 doc gets.freed,
0760: 74 68 65 20 44 4f 4d 20 74 72 65 65 20 61 6e 64 the DOM tree and
0770: 20 74 68 65 20 61 73 73 6f 63 69 61 74 65 64 20 the associated
0780: 54 63 6c 20 63 6f 6d 6d 61 6e 64 20 6f 62 6a 65 Tcl command obje
0790: 63 74 20 28 64 6f 63 75 6d 65 6e 74 20 61 6e 64 ct (document and
07a0: 20 61 6c 6c 0a 6e 6f 64 65 20 6f 62 6a 65 63 74 all.node object
07b0: 73 29 20 61 72 65 20 66 72 65 65 64 20 61 75 74 s) are freed aut
07c0: 6f 6d 61 74 69 63 61 6c 6c 79 2e 3c 2f 70 3e 0a omatically.</p>.
07d0: 20 20 20 20 20 20 0a 20 20 20 20 20 20 3c 70 72 . <pr
07e0: 65 20 63 6c 61 73 73 3d 22 65 78 61 6d 70 6c 65 e class="example
07f0: 22 3e 0a 73 65 74 20 64 6f 63 75 6d 65 6e 74 20 ">.set document
0800: 5b 64 6f 6d 20 70 61 72 73 65 20 24 78 6d 6c 5d [dom parse $xml]
0810: 0a 73 65 74 20 72 6f 6f 74 20 20 20 20 20 5b 24 .set root [$
0820: 64 6f 63 75 6d 65 6e 74 20 64 6f 63 75 6d 65 6e document documen
0830: 74 45 6c 65 6d 65 6e 74 5d 3c 2f 70 72 65 3e 0a tElement]</pre>.
0840: 0a 20 20 20 20 20 20 3c 70 3e 70 61 72 73 65 73 . <p>parses
0850: 20 74 68 65 20 58 4d 4c 20 69 6e 20 74 68 65 20 the XML in the
0860: 76 61 72 69 61 62 6c 65 20 78 6d 6c 2c 20 63 72 variable xml, cr
0870: 65 61 74 65 73 20 74 68 65 20 44 4f 4d 20 74 72 eates the DOM tr
0880: 65 65 20 69 6e 20 6d 65 6d 6f 72 79 2c 0a 6d 61 ee in memory,.ma
0890: 6b 65 20 61 20 72 65 66 65 72 65 6e 63 65 20 74 ke a reference t
08a0: 6f 20 74 68 65 20 64 6f 63 75 6d 65 6e 74 20 6f o the document o
08b0: 62 6a 65 63 74 2c 20 76 69 73 69 62 6c 65 20 69 bject, visible i
08c0: 6e 20 54 63 6c 20 61 73 20 61 20 64 6f 63 75 6d n Tcl as a docum
08d0: 65 6e 74 20 6f 62 6a 65 63 74 0a 63 6f 6d 6d 61 ent object.comma
08e0: 6e 64 2c 20 61 6e 64 20 72 65 74 75 72 6e 73 20 nd, and returns
08f0: 74 68 69 73 20 6e 65 77 20 6f 62 6a 65 63 74 20 this new object
0900: 6e 61 6d 65 2c 20 77 68 69 63 68 20 69 73 20 74 name, which is t
0910: 68 65 6e 20 73 74 6f 72 65 64 20 69 6e 0a 3c 69 hen stored in.<i
0920: 20 63 6c 61 73 73 3d 22 6d 22 3e 64 6f 63 75 6d class="m">docum
0930: 65 6e 74 3c 2f 69 3e 2e 20 20 54 6f 20 66 72 65 ent</i>. To fre
0940: 65 20 74 68 65 20 75 6e 64 65 72 6c 79 69 6e 67 e the underlying
0950: 20 44 4f 4d 20 74 72 65 65 20 61 6e 64 20 74 68 DOM tree and th
0960: 65 20 61 73 73 6f 63 69 61 74 69 76 65 20 54 63 e associative Tc
0970: 6c 0a 6f 62 6a 65 63 74 20 63 6f 6d 6d 61 6e 64 l.object command
0980: 73 20 28 64 6f 63 75 6d 65 6e 74 20 2b 20 6e 6f s (document + no
0990: 64 65 73 20 2b 20 66 72 61 67 6d 65 6e 74 20 6e des + fragment n
09a0: 6f 64 65 73 29 20 74 68 65 20 64 6f 63 75 6d 65 odes) the docume
09b0: 6e 74 20 6f 62 6a 65 63 74 20 63 6f 6d 6d 61 6e nt object comman
09c0: 64 0a 68 61 73 20 74 6f 20 62 65 20 65 78 70 6c d.has to be expl
09d0: 69 63 69 74 6c 79 20 64 65 6c 65 74 65 64 20 62 icitly deleted b
09e0: 79 3a 3c 2f 70 3e 0a 0a 20 20 20 20 20 20 3c 70 y:</p>.. <p
09f0: 72 65 20 63 6c 61 73 73 3d 22 65 78 61 6d 70 6c re class="exampl
0a00: 65 22 3e 0a 24 64 6f 63 75 6d 65 6e 74 20 64 65 e">.$document de
0a10: 6c 65 74 65 0a 3c 2f 70 72 65 3e 6f 72 3c 70 72 lete.</pre>or<pr
0a20: 65 20 63 6c 61 73 73 3d 22 65 78 61 6d 70 6c 65 e class="example
0a30: 22 3e 0a 72 65 6e 61 6d 65 20 24 64 6f 63 75 6d ">.rename $docum
0a40: 65 6e 74 20 22 22 3c 2f 70 72 65 3e 0a 0a 3c 70 ent ""</pre>..<p
0a50: 3e 54 68 65 20 76 61 6c 69 64 20 6f 70 74 69 6f >The valid optio
0a60: 6e 73 20 61 72 65 3a 3c 2f 70 3e 0a 3c 64 6c 20 ns are:</p>.<dl
0a70: 63 6c 61 73 73 3d 22 6f 70 74 6c 69 73 74 22 3e class="optlist">
0a80: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a . .
0a90: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
0aa0: 3c 64 74 3e 3c 62 3e 2d 73 69 6d 70 6c 65 3c 2f <dt><b>-simple</
0ab0: 62 3e 3c 2f 64 74 3e 20 0a 20 20 20 20 20 20 20 b></dt> .
0ac0: 20 20 20 20 20 20 20 20 20 3c 64 64 3e 49 66 20 <dd>If
0ad0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 73 69 <i class="m">-si
0ae0: 6d 70 6c 65 3c 2f 69 3e 20 69 73 0a 73 70 65 63 mple</i> is.spec
0af0: 69 66 69 65 64 2c 20 61 20 73 69 6d 70 6c 65 20 ified, a simple
0b00: 62 75 74 20 66 61 73 74 20 70 61 72 73 65 72 20 but fast parser
0b10: 69 73 20 75 73 65 64 20 28 63 6f 6e 66 6f 72 6d is used (conform
0b20: 73 20 6e 6f 74 20 66 75 6c 6c 79 20 74 6f 20 58 s not fully to X
0b30: 4d 4c 0a 72 65 63 6f 6d 6d 65 6e 64 61 74 69 6f ML.recommendatio
0b40: 6e 29 2e 20 54 68 61 74 20 73 68 6f 75 6c 64 20 n). That should
0b50: 64 6f 75 62 6c 65 20 70 61 72 73 69 6e 67 20 61 double parsing a
0b60: 6e 64 20 44 4f 4d 20 67 65 6e 65 72 61 74 69 6f nd DOM generatio
0b70: 6e 20 73 70 65 65 64 2e 20 54 68 65 0a 65 6e 63 n speed. The.enc
0b80: 6f 64 69 6e 67 20 6f 66 20 74 68 65 20 64 61 74 oding of the dat
0b90: 61 20 69 73 20 6e 6f 74 20 74 72 61 6e 73 66 6f a is not transfo
0ba0: 72 6d 65 64 20 69 6e 73 69 64 65 20 74 68 65 20 rmed inside the
0bb0: 70 61 72 73 65 72 2e 20 54 68 65 20 73 69 6d 70 parser. The simp
0bc0: 6c 65 20 70 61 72 73 65 72 0a 64 6f 65 73 20 6e le parser.does n
0bd0: 6f 74 20 72 65 73 70 65 63 74 20 61 6e 79 20 65 ot respect any e
0be0: 6e 63 6f 64 69 6e 67 20 69 6e 66 6f 72 6d 61 74 ncoding informat
0bf0: 69 6f 6e 20 69 6e 20 74 68 65 20 58 4d 4c 20 64 ion in the XML d
0c00: 65 63 6c 61 72 61 74 69 6f 6e 2e 20 49 74 20 73 eclaration. It s
0c10: 6b 69 70 73 20 6f 76 65 72 0a 74 68 65 20 69 6e kips over.the in
0c20: 74 65 72 6e 61 6c 20 44 54 44 20 73 75 62 73 65 ternal DTD subse
0c30: 74 20 61 6e 64 20 69 67 6e 6f 72 65 73 20 61 6e t and ignores an
0c40: 79 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 20 69 6e y information in
0c50: 20 69 74 2e 20 54 68 65 72 65 66 6f 72 65 20 69 it. Therefore i
0c60: 74 20 64 6f 65 73 6e 27 74 0a 69 6e 63 6c 75 64 t doesn't.includ
0c70: 65 20 64 65 66 61 75 6c 74 65 64 20 61 74 74 72 e defaulted attr
0c80: 69 62 75 74 65 20 76 61 6c 75 65 73 20 69 6e 74 ibute values int
0c90: 6f 20 74 68 65 20 74 72 65 65 2c 20 65 76 65 6e o the tree, even
0ca0: 20 69 66 20 74 68 65 20 61 63 63 6f 72 64 69 6e if the accordin
0cb0: 67 0a 61 74 74 72 69 62 75 74 65 20 64 65 63 6c g.attribute decl
0cc0: 61 72 61 74 69 6f 6e 20 69 73 20 69 6e 20 74 68 aration is in th
0cd0: 65 20 69 6e 74 65 72 6e 61 6c 20 73 75 62 73 65 e internal subse
0ce0: 74 2e 20 49 74 20 61 6c 73 6f 20 64 6f 65 73 6e t. It also doesn
0cf0: 27 74 20 65 78 70 61 6e 64 0a 69 6e 74 65 72 6e 't expand.intern
0d00: 61 6c 20 6f 72 20 65 78 74 65 72 6e 61 6c 20 65 al or external e
0d10: 6e 74 69 74 79 20 72 65 66 65 72 65 6e 63 65 73 ntity references
0d20: 20 6f 74 68 65 72 20 74 68 61 6e 20 74 68 65 20 other than the
0d30: 70 72 65 64 65 66 69 6e 65 64 20 65 6e 74 69 74 predefined entit
0d40: 69 65 73 20 61 6e 64 0a 63 68 61 72 61 63 74 65 ies and.characte
0d50: 72 20 72 65 66 65 72 65 6e 63 65 73 2e 3c 2f 64 r references.</d
0d60: 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 d>.
0d70: 20 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ..
0d80: 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
0d90: 20 20 3c 64 74 3e 3c 62 3e 2d 68 74 6d 6c 3c 2f <dt><b>-html</
0da0: 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 20 b></dt>.
0db0: 20 20 20 20 20 20 20 20 3c 64 64 3e 49 66 20 3c <dd>If <
0dc0: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 68 74 6d i class="m">-htm
0dd0: 6c 3c 2f 69 3e 20 69 73 20 73 70 65 63 69 66 69 l</i> is specifi
0de0: 65 64 2c 20 61 20 66 61 73 74 20 48 54 4d 4c 20 ed, a fast HTML
0df0: 70 61 72 73 65 72 20 69 73 20 0a 75 73 65 64 2c parser is .used,
0e00: 20 77 68 69 63 68 20 74 72 69 65 73 20 74 6f 20 which tries to
0e10: 65 76 65 6e 20 70 61 72 73 65 20 62 61 64 6c 79 even parse badly
0e20: 20 66 6f 72 6d 65 64 20 48 54 4d 4c 20 69 6e 74 formed HTML int
0e30: 6f 20 61 20 44 4f 4d 20 74 72 65 65 2e 3c 2f 64 o a DOM tree.</d
0e40: 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 d>.
0e50: 20 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ..
0e60: 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
0e70: 20 20 3c 64 74 3e 3c 62 3e 2d 68 74 6d 6c 35 3c <dt><b>-html5<
0e80: 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 /b></dt>.
0e90: 20 20 20 20 20 20 20 20 20 3c 64 64 3e 54 68 69 <dd>Thi
0ea0: 73 20 6f 70 74 69 6f 6e 20 69 73 20 6f 6e 6c 79 s option is only
0eb0: 20 61 76 61 69 6c 61 62 6c 65 20 69 66 20 74 44 available if tD
0ec0: 4f 4d 20 77 61 73 20 62 75 69 6c 64 0a 20 20 20 OM was build.
0ed0: 20 20 20 20 20 20 20 20 20 20 20 20 20 77 69 74 wit
0ee0: 68 20 2d 2d 65 6e 61 62 6c 65 2d 68 74 6d 6c 35 h --enable-html5
0ef0: 2e 20 54 72 79 20 74 68 65 20 3c 69 20 63 6c 61 . Try the <i cla
0f00: 73 73 3d 22 6d 22 3e 66 65 61 74 75 72 65 69 6e ss="m">featurein
0f10: 66 6f 3c 2f 69 3e 20 6d 65 74 68 6f 64 0a 20 20 fo</i> method.
0f20: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 if
0f30: 20 79 6f 75 20 6e 65 65 64 20 74 6f 20 6b 6e 6f you need to kno
0f40: 77 20 69 66 20 74 68 69 73 20 66 65 61 74 75 72 w if this featur
0f50: 65 20 69 73 20 62 75 69 6c 64 20 69 6e 2e 20 49 e is build in. I
0f60: 66 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 f.
0f70: 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d <i class="m">-
0f80: 68 74 6d 6c 35 3c 2f 69 3e 20 69 73 20 73 70 65 html5</i> is spe
0f90: 63 69 66 69 65 64 2c 20 74 68 65 20 67 75 6d 62 cified, the gumb
0fa0: 6f 20 6c 69 62 20 68 74 6d 6c 35 20 70 61 72 73 o lib html5 pars
0fb0: 65 72 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 er.
0fc0: 20 20 20 28 68 74 74 70 73 3a 2f 2f 67 69 74 68 (https://gith
0fd0: 75 62 2e 63 6f 6d 2f 67 6f 6f 67 6c 65 2f 67 75 ub.com/google/gu
0fe0: 6d 62 6f 2d 70 61 72 73 65 72 29 20 69 73 20 75 mbo-parser) is u
0ff0: 73 65 64 20 74 6f 0a 20 20 20 20 20 20 20 20 20 sed to.
1000: 20 20 20 20 20 20 20 62 75 69 6c 64 20 74 68 65 build the
1010: 20 44 4f 4d 20 74 72 65 65 2e 20 54 68 69 73 20 DOM tree. This
1020: 69 73 2c 20 61 73 20 66 61 72 20 61 73 20 69 74 is, as far as it
1030: 20 67 6f 65 73 2c 20 58 4d 4c 0a 20 20 20 20 20 goes, XML.
1040: 20 20 20 20 20 20 20 20 20 20 20 6e 61 6d 65 73 names
1050: 70 61 63 65 2d 61 77 61 72 65 2e 20 53 69 6e 63 pace-aware. Sinc
1060: 65 20 74 68 69 73 20 70 72 6f 62 61 62 6c 79 20 e this probably
1070: 69 73 6e 27 74 20 77 61 6e 74 65 64 20 62 79 20 isn't wanted by
1080: 61 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 a.
1090: 20 20 6c 6f 74 20 6f 66 20 75 73 65 72 73 20 61 lot of users a
10a0: 6e 64 20 61 64 64 73 20 6f 6e 6c 79 20 62 75 72 nd adds only bur
10b0: 64 65 6e 20 66 6f 72 20 6e 6f 20 67 6f 6f 64 20 den for no good
10c0: 69 6e 20 61 20 6c 6f 74 0a 20 20 20 20 20 20 20 in a lot.
10d0: 20 20 20 20 20 20 20 20 20 6f 66 20 75 73 65 20 of use
10e0: 63 61 73 65 73 20 3c 69 20 63 6c 61 73 73 3d 22 cases <i class="
10f0: 6d 22 3e 2d 68 74 6d 6c 35 3c 2f 69 3e 20 63 61 m">-html5</i> ca
1100: 6e 20 62 65 20 63 6f 6d 62 69 6e 65 64 20 77 69 n be combined wi
1110: 74 68 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 th.
1120: 20 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e <i class="m">
1130: 2d 69 67 6e 6f 72 65 78 6d 6c 6e 73 3c 2f 69 3e -ignorexmlns</i>
1140: 2c 20 69 6e 20 77 68 69 63 68 20 63 61 73 65 20 , in which case
1150: 61 6c 6c 20 6e 6f 64 65 73 20 61 6e 64 0a 20 20 all nodes and.
1160: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 74 at
1170: 74 72 69 62 75 74 65 73 20 69 6e 20 74 68 65 20 tributes in the
1180: 44 4f 4d 20 74 72 65 65 20 61 72 65 20 6e 6f 74 DOM tree are not
1190: 20 69 6e 20 61 6e 20 58 4d 4c 0a 20 20 20 20 20 in an XML.
11a0: 20 20 20 20 20 20 20 20 20 20 20 6e 61 6d 65 73 names
11b0: 70 61 63 65 2e 20 41 6c 6c 20 74 61 67 20 61 6e pace. All tag an
11c0: 64 20 61 74 74 72 69 62 75 74 65 20 6e 61 6d 65 d attribute name
11d0: 73 20 69 6e 20 74 68 65 20 44 4f 4d 20 74 72 65 s in the DOM tre
11e0: 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 e.
11f0: 20 20 77 69 6c 6c 20 62 65 20 6c 6f 77 65 72 20 will be lower
1200: 63 61 73 65 2c 20 65 76 65 6e 20 66 6f 72 20 66 case, even for f
1210: 6f 72 65 69 67 6e 20 65 6c 65 6d 65 6e 74 73 20 oreign elements
1220: 6e 6f 74 20 69 6e 0a 20 20 20 20 20 20 20 20 20 not in.
1230: 20 20 20 20 20 20 20 74 68 65 20 78 68 74 6d 6c the xhtml
1240: 2c 20 73 76 67 20 6f 72 20 6d 61 74 68 6d 6c 20 , svg or mathml
1250: 6e 61 6d 65 73 70 61 63 65 2e 20 54 68 65 20 44 namespace. The D
1260: 4f 4d 20 74 72 65 65 20 6d 61 79 0a 20 20 20 20 OM tree may.
1270: 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 63 6c incl
1280: 75 64 65 20 6e 6f 64 65 73 2c 20 74 68 61 74 20 ude nodes, that
1290: 74 68 65 20 70 61 72 73 65 72 20 69 6e 73 65 72 the parser inser
12a0: 74 65 64 20 62 65 63 61 75 73 65 20 74 68 65 79 ted because they
12b0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
12c0: 20 61 72 65 20 69 6d 70 6c 69 65 64 20 62 79 20 are implied by
12d0: 74 68 65 20 63 6f 6e 74 65 78 74 20 28 61 73 20 the context (as
12e0: 26 6c 74 3b 68 65 61 64 26 67 74 3b 2c 0a 20 20 <head>,.
12f0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 6c &l
1300: 74 3b 74 62 6f 64 79 26 67 74 3b 2c 20 65 74 63 t;tbody>, etc
1310: 2e 29 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 .).</dd>.
1320: 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 20 ..
1330: 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 20 .
1340: 20 20 20 20 20 20 20 20 3c 64 74 3e 3c 62 3e 2d <dt><b>-
1350: 6a 73 6f 6e 3c 2f 62 3e 3c 2f 64 74 3e 0a 20 20 json</b></dt>.
1360: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
1370: 64 3e 49 66 20 3c 69 20 63 6c 61 73 73 3d 22 6d d>If <i class="m
1380: 22 3e 2d 6a 73 6f 6e 3c 2f 69 3e 20 69 73 20 73 ">-json</i> is s
1390: 70 65 63 69 66 69 65 64 2c 20 74 68 65 20 3c 69 pecified, the <i
13a0: 20 63 6c 61 73 73 3d 22 6d 22 3e 64 61 74 61 3c class="m">data<
13b0: 2f 69 3e 20 69 73 0a 20 20 20 20 20 20 20 20 20 /i> is.
13c0: 20 20 20 20 20 20 20 65 78 70 65 63 74 65 64 20 expected
13d0: 74 6f 20 62 65 20 61 20 76 61 6c 69 64 20 4a 53 to be a valid JS
13e0: 4f 4e 20 73 74 72 69 6e 67 20 28 61 63 63 6f 72 ON string (accor
13f0: 64 69 6e 67 20 74 6f 20 52 46 43 0a 20 20 20 20 ding to RFC.
1400: 20 20 20 20 20 20 20 20 20 20 20 20 37 31 35 39 7159
1410: 29 2e 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 72 ). The command r
1420: 65 74 75 72 6e 73 20 61 6e 20 6f 72 64 69 6e 61 eturns an ordina
1430: 72 79 20 44 4f 4d 20 64 6f 63 75 6d 65 6e 74 0a ry DOM document.
1440: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
1450: 77 69 74 68 20 6e 65 73 74 69 6e 67 20 74 6f 6b with nesting tok
1460: 65 6e 20 69 6e 73 69 64 65 20 74 68 65 20 4a 53 en inside the JS
1470: 4f 4e 20 64 61 74 61 20 74 72 61 6e 73 6c 61 74 ON data translat
1480: 65 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ed.
1490: 20 20 20 69 6e 74 6f 20 74 72 65 65 20 68 69 65 into tree hie
14a0: 72 61 72 63 68 79 2e 20 49 66 20 61 20 4a 53 4f rarchy. If a JSO
14b0: 4e 20 61 72 72 61 79 20 76 61 6c 75 65 20 69 73 N array value is
14c0: 20 69 74 73 65 6c 66 0a 20 20 20 20 20 20 20 20 itself.
14d0: 20 20 20 20 20 20 20 20 61 6e 20 6f 62 6a 65 63 an objec
14e0: 74 20 6f 72 20 61 72 72 61 79 20 74 68 65 6e 20 t or array then
14f0: 63 6f 6e 74 61 69 6e 65 72 20 65 6c 65 6d 65 6e container elemen
1500: 74 20 6e 6f 64 65 73 20 6e 61 6d 65 64 0a 20 20 t nodes named.
1510: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 69 (i
1520: 6e 20 61 20 64 65 66 61 75 6c 74 20 62 75 69 6c n a default buil
1530: 64 29 20 61 72 72 61 79 63 6f 6e 74 61 69 6e 65 d) arraycontaine
1540: 72 20 6f 72 0a 20 20 20 20 20 20 20 20 20 20 20 r or.
1550: 20 20 20 20 20 6f 62 6a 65 63 74 63 6f 6e 74 61 objectconta
1560: 69 6e 65 72 2c 20 72 65 73 70 65 63 74 69 76 65 iner, respective
1570: 6c 79 2c 20 61 72 65 20 69 6e 73 65 72 74 65 64 ly, are inserted
1580: 20 69 6e 74 6f 20 74 68 65 0a 20 20 20 20 20 20 into the.
1590: 20 20 20 20 20 20 20 20 20 20 74 72 65 65 2e 20 tree.
15a0: 54 68 65 20 4a 53 4f 4e 20 73 65 72 69 61 6c 69 The JSON seriali
15b0: 7a 61 74 69 6f 6e 20 6f 66 20 74 68 69 73 20 64 zation of this d
15c0: 6f 63 75 6d 65 6e 74 20 28 77 69 74 68 0a 20 20 ocument (with.
15d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 th
15e0: 65 20 64 6f 6d 44 6f 63 20 6d 65 74 68 6f 64 20 e domDoc method
15f0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 61 73 4a <i class="m">asJ
1600: 53 4f 4e 3c 2f 69 3e 29 20 69 73 20 74 68 65 20 SON</i>) is the
1610: 73 61 6d 65 20 4a 53 4f 4e 0a 20 20 20 20 20 20 same JSON.
1620: 20 20 20 20 20 20 20 20 20 20 69 6e 66 6f 72 6d inform
1630: 61 74 69 6f 6e 20 61 73 20 74 68 65 20 3c 69 20 ation as the <i
1640: 63 6c 61 73 73 3d 22 6d 22 3e 64 61 74 61 3c 2f class="m">data</
1650: 69 3e 2c 20 70 72 65 73 65 72 76 69 6e 67 20 4a i>, preserving J
1660: 53 4f 4e 0a 20 20 20 20 20 20 20 20 20 20 20 20 SON.
1670: 20 20 20 20 64 61 74 61 74 79 70 65 73 2c 20 61 datatypes, a
1680: 6c 6c 6f 77 69 6e 67 20 6e 6f 6e 2d 75 6e 69 71 llowing non-uniq
1690: 75 65 20 6d 65 6d 62 65 72 20 6e 61 6d 65 73 20 ue member names
16a0: 6f 66 20 6f 62 6a 65 63 74 73 0a 20 20 20 20 20 of objects.
16b0: 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c 65 while
16c0: 20 70 72 65 73 65 72 76 69 6e 67 20 74 68 65 69 preserving thei
16d0: 72 20 6f 72 64 65 72 20 61 6e 64 20 74 68 65 20 r order and the
16e0: 66 75 6c 6c 20 72 61 6e 67 65 20 6f 66 0a 20 20 full range of.
16f0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 4a 53 JS
1700: 4f 4e 20 73 74 72 69 6e 67 20 76 61 6c 75 65 73 ON string values
1710: 2e 20 4a 53 4f 4e 20 64 61 74 61 74 79 70 65 20 . JSON datatype
1720: 68 61 6e 64 6c 69 6e 67 20 69 73 20 64 6f 6e 65 handling is done
1730: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
1740: 20 77 69 74 68 20 61 6e 20 61 64 64 69 74 69 6f with an additio
1750: 6e 61 6c 20 70 72 6f 70 65 72 74 79 20 22 73 74 nal property "st
1760: 69 63 6b 69 6e 67 22 20 61 74 20 74 68 65 20 64 icking" at the d
1770: 6f 63 20 61 6e 64 0a 20 20 20 20 20 20 20 20 20 oc and.
1780: 20 20 20 20 20 20 20 74 72 65 65 20 6e 6f 64 65 tree node
1790: 73 2e 20 54 68 69 73 20 70 72 6f 70 65 72 74 79 s. This property
17a0: 20 69 73 6e 27 74 20 63 6f 6e 74 61 69 6e 65 64 isn't contained
17b0: 20 69 6e 20 61 6e 20 58 4d 4c 0a 20 20 20 20 20 in an XML.
17c0: 20 20 20 20 20 20 20 20 20 20 20 73 65 72 69 61 seria
17d0: 6c 69 7a 61 74 69 6f 6e 20 6f 66 20 74 68 65 20 lization of the
17e0: 64 6f 63 75 6d 65 6e 74 2e 20 49 66 20 79 6f 75 document. If you
17f0: 20 6e 65 65 64 20 74 6f 20 73 74 6f 72 65 0a 20 need to store.
1800: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 t
1810: 68 65 20 4a 53 4f 4e 20 64 61 74 61 20 72 65 70 he JSON data rep
1820: 72 65 73 65 6e 74 65 64 20 62 79 20 61 20 64 6f resented by a do
1830: 63 75 6d 65 6e 74 2c 20 73 74 6f 72 65 20 74 68 cument, store th
1840: 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 e.
1850: 20 20 4a 53 4f 4e 20 73 65 72 69 61 6c 69 7a 61 JSON serializa
1860: 74 69 6f 6e 20 61 6e 64 20 70 61 72 73 65 20 69 tion and parse i
1870: 74 20 62 61 63 6b 20 66 72 6f 6d 20 74 68 65 72 t back from ther
1880: 65 2e 20 41 70 61 72 74 0a 20 20 20 20 20 20 20 e. Apart.
1890: 20 20 20 20 20 20 20 20 20 66 72 6f 6d 20 74 68 from th
18a0: 69 73 20 4a 53 4f 4e 20 74 79 70 65 20 69 6e 66 is JSON type inf
18b0: 6f 72 6d 61 74 69 6f 6e 20 74 68 65 20 72 65 74 ormation the ret
18c0: 75 72 6e 65 64 20 64 6f 63 0a 20 20 20 20 20 20 urned doc.
18d0: 20 20 20 20 20 20 20 20 20 20 63 6f 6d 6d 61 6e comman
18e0: 64 20 6f 72 20 68 61 6e 64 6c 65 20 69 73 20 61 d or handle is a
18f0: 6e 20 6f 72 64 69 6e 61 72 79 20 44 4f 4d 20 64 n ordinary DOM d
1900: 6f 63 2c 20 77 68 69 63 68 20 6d 61 79 20 62 65 oc, which may be
1910: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
1920: 20 69 6e 76 65 73 74 69 67 61 74 65 64 20 6f 72 investigated or
1930: 20 6d 6f 64 69 66 69 65 64 20 77 69 74 68 20 74 modified with t
1940: 68 65 20 66 75 6c 6c 20 72 61 6e 67 65 20 6f 66 he full range of
1950: 20 74 68 65 0a 20 20 20 20 20 20 20 20 20 20 20 the.
1960: 20 20 20 20 20 64 6f 63 20 61 6e 64 20 6e 6f 64 doc and nod
1970: 65 20 6d 65 74 68 6f 64 73 2e 20 50 6c 65 61 73 e methods. Pleas
1980: 65 20 6e 6f 74 65 20 74 68 61 74 20 74 68 65 20 e note that the
1990: 65 6c 65 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 element.
19a0: 20 20 20 20 20 20 20 20 6e 6f 64 65 20 6e 61 6d node nam
19b0: 65 73 20 61 6e 64 20 74 68 65 20 74 65 78 74 20 es and the text
19c0: 6e 6f 64 65 20 76 61 6c 75 65 73 20 77 69 74 68 node values with
19d0: 69 6e 20 74 68 65 20 74 72 65 65 0a 20 20 20 20 in the tree.
19e0: 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 79 20 may
19f0: 62 65 20 6f 75 74 73 69 64 65 20 6f 66 20 77 68 be outside of wh
1a00: 61 74 20 74 68 65 20 61 70 70 72 6f 70 72 69 61 at the appropria
1a10: 74 65 20 58 4d 4c 20 70 72 6f 64 75 63 74 69 6f te XML productio
1a20: 6e 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ns.
1a30: 20 20 20 61 6c 6c 6f 77 2e 3c 2f 64 64 3e 0a 20 allow.</dd>.
1a40: 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 0a 20 ..
1a50: 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 .
1a60: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
1a70: 74 3e 0a 3c 62 3e 2d 6a 73 6f 6e 6d 61 78 6e 65 t>.<b>-jsonmaxne
1a80: 73 74 69 6e 67 3c 2f 62 3e 20 3c 69 3e 69 6e 74 sting</b> <i>int
1a90: 65 67 65 72 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 eger</i>.</dt>.
1aa0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a .
1ab0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
1ac0: 3c 64 64 3e 54 68 69 73 20 6f 70 74 69 6f 6e 20 <dd>This option
1ad0: 6f 6e 6c 79 20 68 61 73 20 65 66 66 65 63 74 20 only has effect
1ae0: 69 66 20 75 73 65 64 20 74 6f 67 65 74 68 65 72 if used together
1af0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
1b00: 20 77 69 74 68 20 74 68 65 20 3c 69 20 63 6c 61 with the <i cla
1b10: 73 73 3d 22 6d 22 3e 2d 6a 73 6f 6e 3c 2f 69 3e ss="m">-json</i>
1b20: 20 6f 70 74 69 6f 6e 2e 20 54 68 65 20 63 75 72 option. The cur
1b30: 72 65 6e 74 20 69 6d 70 6c 65 6d 65 6e 74 61 74 rent implementat
1b40: 69 6f 6e 20 75 73 65 73 20 72 65 63 75 72 73 69 ion uses recursi
1b50: 76 65 20 64 65 73 63 65 6e 74 20 4a 53 4f 4e 20 ve descent JSON
1b60: 70 61 72 73 65 72 2e 20 49 6e 20 6f 72 64 65 72 parser. In order
1b70: 20 74 6f 20 61 76 6f 69 64 20 75 73 69 6e 67 20 to avoid using
1b80: 65 78 63 65 73 73 20 73 74 61 63 6b 20 73 70 61 excess stack spa
1b90: 63 65 2c 20 61 6e 79 20 4a 53 4f 4e 20 69 6e 70 ce, any JSON inp
1ba0: 75 74 20 74 68 61 74 20 68 61 73 20 6d 6f 72 65 ut that has more
1bb0: 20 74 68 61 6e 20 61 20 63 65 72 74 61 69 6e 20 than a certain
1bc0: 6c 65 76 65 6c 73 20 6f 66 20 6e 65 73 74 69 6e levels of nestin
1bd0: 67 20 69 73 20 63 6f 6e 73 69 64 65 72 65 64 20 g is considered
1be0: 69 6e 76 61 6c 69 64 2e 20 54 68 65 20 64 65 66 invalid. The def
1bf0: 61 75 6c 74 20 6d 61 78 69 6d 75 6d 20 6e 65 73 ault maximum nes
1c00: 74 69 6e 67 20 69 73 20 32 30 30 30 2e 20 54 68 ting is 2000. Th
1c10: 65 20 6f 70 74 69 6f 6e 20 2d 6a 73 6f 6e 6d 61 e option -jsonma
1c20: 78 6e 65 73 74 69 6e 67 20 61 6c 6c 6f 77 73 20 xnesting allows
1c30: 74 68 65 20 75 73 65 72 20 74 6f 20 61 64 6a 75 the user to adju
1c40: 73 74 20 74 68 61 74 2e 3c 2f 64 64 3e 0a 20 20 st that.</dd>.
1c50: 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 .
1c60: 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 .
1c70: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
1c80: 20 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 3c <dt><
1c90: 62 3e 2d 2d 3c 2f 62 3e 3c 2f 64 74 3e 20 0a 20 b>--</b></dt> .
1ca0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
1cb0: 64 64 3e 54 68 65 20 6f 70 74 69 6f 6e 20 3c 69 dd>The option <i
1cc0: 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 2d 3c 2f 69 class="m">--</i
1cd0: 3e 20 6d 61 72 6b 73 20 74 68 65 20 65 6e 64 20 > marks the end
1ce0: 6f 66 20 6f 70 74 69 6f 6e 73 2e 0a 20 20 20 20 of options..
1cf0: 20 20 20 20 20 20 20 20 20 20 20 20 57 68 69 6c Whil
1d00: 65 20 72 65 73 70 65 63 74 65 64 20 69 6e 20 67 e respected in g
1d10: 65 6e 65 72 61 6c 20 74 68 69 73 20 6f 70 74 69 eneral this opti
1d20: 6f 6e 20 69 73 20 6f 6e 6c 79 20 6e 65 65 64 65 on is only neede
1d30: 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 d.
1d40: 20 20 69 6e 20 63 61 73 65 20 6f 66 20 70 61 72 in case of par
1d50: 73 69 6e 67 20 4a 53 4f 4e 20 64 61 74 61 2c 20 sing JSON data,
1d60: 77 68 69 63 68 20 6d 61 79 20 73 74 61 72 74 20 which may start
1d70: 77 69 74 68 20 61 0a 20 20 20 20 20 20 20 20 20 with a.
1d80: 20 20 20 20 20 20 20 22 2d 22 2e 3c 2f 64 64 3e "-".</dd>
1d90: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a . .
1da0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a . .
1db0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
1dc0: 3c 64 74 3e 3c 62 3e 2d 6b 65 65 70 45 6d 70 74 <dt><b>-keepEmpt
1dd0: 69 65 73 3c 2f 62 3e 3c 2f 64 74 3e 20 0a 20 20 ies</b></dt> .
1de0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
1df0: 64 3e 49 66 20 3c 69 20 63 6c 61 73 73 3d 22 6d d>If <i class="m
1e00: 22 3e 2d 6b 65 65 70 45 6d 70 74 69 65 73 3c 2f ">-keepEmpties</
1e10: 69 3e 20 69 73 0a 73 70 65 63 69 66 69 65 64 20 i> is.specified
1e20: 74 68 65 6e 20 74 65 78 74 20 6e 6f 64 65 73 20 then text nodes
1e30: 77 68 69 63 68 20 63 6f 6e 74 61 69 6e 20 6f 6e which contain on
1e40: 6c 79 20 77 68 69 74 65 73 70 61 63 65 73 20 77 ly whitespaces w
1e50: 69 6c 6c 20 62 65 20 70 61 72 74 20 6f 66 20 74 ill be part of t
1e60: 68 65 0a 72 65 73 75 6c 74 69 6e 67 20 44 4f 4d he.resulting DOM
1e70: 20 74 72 65 65 2e 20 49 6e 20 64 65 66 61 75 6c tree. In defaul
1e80: 74 20 63 61 73 65 20 28 3c 69 20 63 6c 61 73 73 t case (<i class
1e90: 3d 22 6d 22 3e 2d 6b 65 65 70 45 6d 70 74 69 65 ="m">-keepEmptie
1ea0: 73 3c 2f 69 3e 20 6e 6f 74 20 67 69 76 65 6e 29 s</i> not given)
1eb0: 20 74 68 6f 73 65 20 65 6d 70 74 79 0a 74 65 78 those empty.tex
1ec0: 74 20 6e 6f 64 65 73 20 61 72 65 20 72 65 6d 6f t nodes are remo
1ed0: 76 65 64 20 61 74 20 70 61 72 73 69 6e 67 20 74 ved at parsing t
1ee0: 69 6d 65 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 ime.</dd>.
1ef0: 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 ..
1f00: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
1f10: 20 20 20 20 20 20 20 20 20 3c 64 74 3e 3c 62 3e <dt><b>
1f20: 2d 6b 65 65 70 43 44 41 54 41 3c 2f 62 3e 3c 2f -keepCDATA</b></
1f30: 64 74 3e 20 0a 20 20 20 20 20 20 20 20 20 20 20 dt> .
1f40: 20 20 20 20 20 3c 64 64 3e 49 66 20 3c 69 20 63 <dd>If <i c
1f50: 6c 61 73 73 3d 22 6d 22 3e 2d 6b 65 65 70 43 44 lass="m">-keepCD
1f60: 41 54 41 3c 2f 69 3e 20 69 73 0a 73 70 65 63 69 ATA</i> is.speci
1f70: 66 69 65 64 20 74 68 65 6e 20 43 44 41 54 41 20 fied then CDATA
1f80: 73 65 63 74 69 6f 6e 73 20 61 72 65 6e 27 74 20 sections aren't
1f90: 61 64 64 65 64 20 74 6f 20 74 68 65 20 74 72 65 added to the tre
1fa0: 65 20 61 73 20 74 65 78 74 20 6e 6f 64 65 73 0a e as text nodes.
1fb0: 28 61 6e 64 2c 20 69 66 20 6e 65 63 65 73 73 61 (and, if necessa
1fc0: 72 79 2c 20 63 6f 6d 62 69 6e 65 64 20 77 69 74 ry, combined wit
1fd0: 68 20 73 69 62 6c 69 6e 67 20 74 65 78 74 20 6e h sibling text n
1fe0: 6f 64 65 73 20 69 6e 74 6f 20 6f 6e 65 20 74 65 odes into one te
1ff0: 78 74 0a 6e 6f 64 65 29 20 61 73 20 77 69 74 68 xt.node) as with
2000: 6f 75 74 20 74 68 69 73 20 6f 70 74 69 6f 6e 20 out this option
2010: 62 75 74 20 61 72 65 20 61 64 64 65 64 20 61 73 but are added as
2020: 20 43 44 41 54 41 5f 53 45 43 54 49 4f 4e 5f 4e CDATA_SECTION_N
2030: 4f 44 45 73 20 74 6f 0a 74 68 65 20 74 72 65 65 ODEs to.the tree
2040: 2e 20 50 6c 65 61 73 65 20 6e 6f 74 65 20 74 68 . Please note th
2050: 61 74 20 74 68 65 20 72 65 73 75 6c 74 69 6e 67 at the resulting
2060: 20 74 72 65 65 20 69 73 6e 27 74 20 70 72 65 70 tree isn't prep
2070: 61 72 65 64 20 66 6f 72 20 58 50 61 74 68 0a 73 ared for XPath.s
2080: 65 6c 65 63 74 73 20 6f 72 20 74 6f 20 62 65 20 elects or to be
2090: 74 68 65 20 73 6f 75 72 63 65 20 6f 72 20 74 68 the source or th
20a0: 65 20 73 74 79 6c 65 73 68 65 65 74 20 6f 66 20 e stylesheet of
20b0: 61 6e 20 58 53 4c 54 0a 74 72 61 6e 73 66 6f 72 an XSLT.transfor
20c0: 6d 61 74 69 6f 6e 2e 20 49 66 20 6e 6f 74 20 63 mation. If not c
20d0: 6f 6d 62 69 6e 65 64 20 77 69 74 68 20 3c 69 20 ombined with <i
20e0: 63 6c 61 73 73 3d 22 6d 22 3e 2d 6b 65 65 70 45 class="m">-keepE
20f0: 6d 70 74 69 65 73 3c 2f 69 3e 20 6f 6e 6c 79 20 mpties</i> only
2100: 6e 6f 74 0a 77 68 69 74 65 73 70 61 63 65 20 6f not.whitespace o
2110: 6e 6c 79 20 43 44 41 54 41 20 73 65 63 74 69 6f nly CDATA sectio
2120: 6e 73 20 77 69 6c 6c 20 62 65 20 61 64 64 65 64 ns will be added
2130: 20 74 6f 20 74 68 65 20 72 65 73 75 6c 74 69 6e to the resultin
2140: 67 20 44 4f 4d 0a 20 20 20 20 20 20 20 20 20 20 g DOM.
2150: 20 20 20 20 20 20 74 72 65 65 2e 3c 2f 64 64 3e tree.</dd>
2160: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a . .
2170: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 .
2180: 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 .
2190: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
21a0: 74 3e 0a 3c 62 3e 2d 63 68 61 6e 6e 65 6c 3c 2f t>.<b>-channel</
21b0: 62 3e 20 3c 69 3e 26 6c 74 3b 63 68 61 6e 6e 65 b> <i><channe
21c0: 6c 2d 49 44 26 67 74 3b 3c 2f 69 3e 0a 3c 2f 64 l-ID></i>.</d
21d0: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 t>.
21e0: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 .
21f0: 20 20 20 20 3c 64 64 3e 49 66 20 3c 69 20 63 6c <dd>If <i cl
2200: 61 73 73 3d 22 6d 22 3e 2d 63 68 61 6e 6e 65 6c ass="m">-channel
2210: 20 26 6c 74 3b 63 68 61 6e 6e 65 6c 2d 49 44 26 <channel-ID&
2220: 67 74 3b 3c 2f 69 3e 20 69 73 20 73 70 65 63 69 gt;</i> is speci
2230: 66 69 65 64 2c 20 74 68 65 0a 69 6e 70 75 74 20 fied, the.input
2240: 74 6f 20 62 65 20 70 61 72 73 65 64 20 69 73 20 to be parsed is
2250: 72 65 61 64 20 66 72 6f 6d 20 74 68 65 20 73 70 read from the sp
2260: 65 63 69 66 69 65 64 20 63 68 61 6e 6e 65 6c 2e ecified channel.
2270: 20 54 68 65 20 65 6e 63 6f 64 69 6e 67 20 73 65 The encoding se
2280: 74 74 69 6e 67 20 6f 66 0a 74 68 65 20 63 68 61 tting of.the cha
2290: 6e 6e 65 6c 20 28 76 69 61 20 66 63 6f 6e 66 69 nnel (via fconfi
22a0: 67 75 72 65 20 2d 65 6e 63 6f 64 69 6e 67 29 20 gure -encoding)
22b0: 69 73 20 72 65 73 70 65 63 74 65 64 2c 20 69 65 is respected, ie
22c0: 20 74 68 65 20 64 61 74 61 20 72 65 61 64 20 66 the data read f
22d0: 72 6f 6d 20 74 68 65 0a 63 68 61 6e 6e 65 6c 20 rom the.channel
22e0: 61 72 65 20 63 6f 6e 76 65 72 74 65 64 20 74 6f are converted to
22f0: 20 55 54 46 2d 38 20 61 63 63 6f 72 64 69 6e 67 UTF-8 according
2300: 20 74 6f 20 74 68 65 20 65 6e 63 6f 64 69 6e 67 to the encoding
2310: 20 73 65 74 74 69 6e 67 73 20 62 65 66 6f 72 65 settings before
2320: 20 74 68 65 0a 64 61 74 61 20 69 73 20 70 61 72 the.data is par
2330: 73 65 64 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 sed.</dd>.
2340: 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 ..
2350: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
2360: 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a 3c 62 <dt>.<b
2370: 3e 2d 62 61 73 65 75 72 6c 3c 2f 62 3e 20 3c 69 >-baseurl</b> <i
2380: 3e 26 6c 74 3b 62 61 73 65 55 52 49 26 67 74 3b ><baseURI>
2390: 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 20 20 </i>.</dt>.
23a0: 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 .
23b0: 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 64 3e <dd>
23c0: 49 66 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e If <i class="m">
23d0: 2d 62 61 73 65 75 72 6c 20 26 6c 74 3b 62 61 73 -baseurl <bas
23e0: 65 55 52 49 26 67 74 3b 3c 2f 69 3e 20 69 73 20 eURI></i> is
23f0: 73 70 65 63 69 66 69 65 64 2c 0a 20 20 20 20 20 specified,.
2400: 20 20 20 20 20 20 20 20 20 20 20 74 68 65 20 62 the b
2410: 61 73 65 55 52 49 20 69 73 20 75 73 65 64 20 61 aseURI is used a
2420: 73 20 74 68 65 20 62 61 73 65 20 55 52 49 20 6f s the base URI o
2430: 66 20 74 68 65 20 64 6f 63 75 6d 65 6e 74 2e 0a f the document..
2440: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
2450: 45 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 69 65 External entitie
2460: 73 20 72 65 66 65 72 65 6e 63 65 73 20 69 6e 20 s references in
2470: 74 68 65 20 64 6f 63 75 6d 65 6e 74 20 61 72 65 the document are
2480: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
2490: 20 72 65 73 6f 6c 76 65 64 20 72 65 6c 61 74 69 resolved relati
24a0: 76 65 20 74 6f 20 74 68 69 73 20 62 61 73 65 20 ve to this base
24b0: 55 52 49 2e 20 54 68 69 73 20 62 61 73 65 20 55 URI. This base U
24c0: 52 49 20 69 73 0a 20 20 20 20 20 20 20 20 20 20 RI is.
24d0: 20 20 20 20 20 20 61 6c 73 6f 20 73 74 6f 72 65 also store
24e0: 64 20 77 69 74 68 69 6e 20 74 68 65 20 44 4f 4d d within the DOM
24f0: 20 74 72 65 65 2e 3c 2f 64 64 3e 0a 20 20 20 20 tree.</dd>.
2500: 20 20 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 ..
2510: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
2520: 20 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a <dt>.
2530: 3c 62 3e 2d 66 65 65 64 62 61 63 6b 41 66 74 65 <b>-feedbackAfte
2540: 72 3c 2f 62 3e 20 3c 69 3e 26 6c 74 3b 23 62 79 r</b> <i><#by
2550: 74 65 73 26 67 74 3b 3c 2f 69 3e 0a 3c 2f 64 74 tes></i>.</dt
2560: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 >.
2570: 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 .
2580: 20 20 20 3c 64 64 3e 49 66 20 3c 69 20 63 6c 61 <dd>If <i cla
2590: 73 73 3d 22 6d 22 3e 2d 66 65 65 64 62 61 63 6b ss="m">-feedback
25a0: 41 66 74 65 72 20 26 6c 74 3b 23 62 79 74 65 73 After <#bytes
25b0: 26 67 74 3b 3c 2f 69 3e 20 69 73 0a 20 20 20 20 ></i> is.
25c0: 20 20 20 20 20 20 20 20 20 20 20 20 73 70 65 63 spec
25d0: 69 66 69 65 64 2c 20 74 68 65 20 74 63 6c 20 63 ified, the tcl c
25e0: 6f 6d 6d 61 6e 64 20 67 69 76 65 6e 20 62 79 0a ommand given by.
25f0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
2600: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 66 65 <i class="m">-fe
2610: 65 64 62 61 63 6b 63 6d 64 3c 2f 69 3e 20 69 73 edbackcmd</i> is
2620: 20 65 76 61 6c 75 61 74 65 64 20 61 74 20 74 68 evaluated at th
2630: 65 20 66 69 72 73 74 20 65 6c 65 6d 65 6e 74 0a e first element.
2640: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
2650: 73 74 61 72 74 20 77 69 74 68 69 6e 20 74 68 65 start within the
2660: 20 64 6f 63 75 6d 65 6e 74 20 28 6f 72 20 61 6e document (or an
2670: 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 79 external entity
2680: 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ).
2690: 20 20 61 66 74 65 72 20 74 68 65 20 73 74 61 72 after the star
26a0: 74 20 6f 66 20 74 68 65 20 64 6f 63 75 6d 65 6e t of the documen
26b0: 74 20 6f 72 20 65 78 74 65 72 6e 61 6c 20 65 6e t or external en
26c0: 74 69 74 79 20 6f 72 0a 20 20 20 20 20 20 20 20 tity or.
26d0: 20 20 20 20 20 20 20 20 74 68 65 20 6c 61 73 74 the last
26e0: 20 73 75 63 68 20 63 61 6c 6c 20 61 66 74 65 72 such call after
26f0: 20 23 62 79 74 65 73 2e 20 46 6f 72 20 62 61 63 #bytes. For bac
2700: 6b 77 61 72 64 0a 20 20 20 20 20 20 20 20 20 20 kward.
2710: 20 20 20 20 20 20 63 6f 6d 70 61 74 69 62 69 6c compatibil
2720: 69 74 79 20 69 66 20 6e 6f 20 2d 66 65 65 64 62 ity if no -feedb
2730: 61 63 6b 63 6d 64 20 69 73 20 67 69 76 65 6e 20 ackcmd is given
2740: 62 75 74 20 74 68 65 72 65 20 69 73 0a 20 20 20 but there is.
2750: 20 20 20 20 20 20 20 20 20 20 20 20 20 61 20 74 a t
2760: 63 6c 20 70 72 6f 63 20 6e 61 6d 65 64 20 3a 3a cl proc named ::
2770: 64 6f 6d 3a 3a 64 6f 6d 50 61 72 73 65 46 65 65 dom::domParseFee
2780: 64 62 61 63 6b 20 74 68 69 73 20 70 72 6f 63 20 dback this proc
2790: 69 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 is.
27a0: 20 20 20 75 73 65 64 20 61 73 20 2d 66 65 65 64 used as -feed
27b0: 62 61 63 6b 63 6d 64 2e 20 49 66 20 74 68 65 72 backcmd. If ther
27c0: 65 20 69 73 6e 27 74 20 73 75 63 68 20 61 20 70 e isn't such a p
27d0: 72 6f 63 20 61 6e 64 0a 20 20 20 20 20 20 20 20 roc and.
27e0: 20 20 20 20 20 20 20 20 2d 66 65 65 64 62 61 63 -feedbac
27f0: 6b 41 66 74 65 72 20 69 73 20 75 73 65 64 20 69 kAfter is used i
2800: 74 20 69 73 20 61 6e 20 65 72 72 6f 72 20 74 6f t is an error to
2810: 20 6e 6f 74 20 61 6c 73 6f 20 75 73 65 0a 20 20 not also use.
2820: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 66 -f
2830: 65 65 64 62 61 63 6b 63 6d 64 2e 20 49 66 20 74 eedbackcmd. If t
2840: 68 65 20 63 61 6c 6c 65 64 20 73 63 72 69 70 74 he called script
2850: 20 72 61 69 73 65 73 20 65 72 72 6f 72 2c 20 74 raises error, t
2860: 68 65 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 hen.
2870: 20 20 20 20 70 61 72 73 69 6e 67 20 77 69 6c 6c parsing will
2880: 20 62 65 20 61 62 6f 72 74 65 64 2c 20 74 68 65 be aborted, the
2890: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 6f <i class="m">do
28a0: 6d 20 70 61 72 73 65 3c 2f 69 3e 20 63 61 6c 6c m parse</i> call
28b0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
28c0: 20 72 65 74 75 72 6e 73 20 65 72 72 6f 72 2c 20 returns error,
28d0: 77 69 74 68 20 74 68 65 20 73 63 72 69 70 74 20 with the script
28e0: 65 72 72 6f 72 20 6d 73 67 20 61 73 20 65 72 72 error msg as err
28f0: 6f 72 20 6d 73 67 2e 0a 20 20 20 20 20 20 20 20 or msg..
2900: 20 20 20 20 20 20 20 20 49 66 20 74 68 65 20 63 If the c
2910: 61 6c 6c 65 64 20 73 63 72 69 70 74 20 3c 69 20 alled script <i
2920: 63 6c 61 73 73 3d 22 6d 22 3e 72 65 74 75 72 6e class="m">return
2930: 20 2d 63 6f 64 65 20 62 72 65 61 6b 3c 2f 69 3e -code break</i>
2940: 2c 20 74 68 65 0a 20 20 20 20 20 20 20 20 20 20 , the.
2950: 20 20 20 20 20 20 70 61 72 73 69 6e 67 20 77 69 parsing wi
2960: 6c 6c 20 61 62 6f 72 74 20 61 6e 64 20 74 68 65 ll abort and the
2970: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 6f <i class="m">do
2980: 6d 20 70 61 72 73 65 3c 2f 69 3e 20 63 61 6c 6c m parse</i> call
2990: 20 77 69 6c 6c 0a 20 20 20 20 20 20 20 20 20 20 will.
29a0: 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 65 return the
29b0: 20 65 6d 70 74 79 20 73 74 72 69 6e 67 2e 3c 2f empty string.</
29c0: 64 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 dd>.
29d0: 20 20 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 ..
29e0: 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 .
29f0: 20 20 20 3c 64 74 3e 0a 3c 62 3e 2d 66 65 65 64 <dt>.<b>-feed
2a00: 62 61 63 6b 63 6d 64 3c 2f 62 3e 20 3c 69 3e 26 backcmd</b> <i>&
2a10: 6c 74 3b 73 63 72 69 70 74 26 67 74 3b 3c 2f 69 lt;script></i
2a20: 3e 0a 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 20 >.</dt>.
2a30: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
2a40: 20 20 20 20 20 20 20 20 20 3c 64 64 3e 49 66 20 <dd>If
2a50: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 66 65 <i class="m">-fe
2a60: 65 64 62 61 63 6b 63 6d 64 20 26 6c 74 3b 73 63 edbackcmd <sc
2a70: 72 69 70 74 26 67 74 3b 3c 2f 69 3e 20 69 73 20 ript></i> is
2a80: 73 70 65 63 69 66 69 65 64 2c 20 74 68 65 0a 73 specified, the.s
2a90: 63 72 69 70 74 20 3c 69 20 63 6c 61 73 73 3d 22 cript <i class="
2aa0: 6d 22 3e 73 63 72 69 70 74 3c 2f 69 3e 20 69 73 m">script</i> is
2ab0: 20 65 76 61 6c 75 61 74 65 64 20 61 74 20 74 68 evaluated at th
2ac0: 65 20 66 69 72 73 74 0a 65 6c 65 6d 65 6e 74 20 e first.element
2ad0: 73 74 61 72 74 20 77 69 74 68 69 6e 20 74 68 65 start within the
2ae0: 20 64 6f 63 75 6d 65 6e 74 20 28 6f 72 20 61 6e document (or an
2af0: 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 79 external entity
2b00: 29 20 61 66 74 65 72 20 74 68 65 0a 73 74 61 72 ) after the.star
2b10: 74 20 6f 66 20 74 68 65 20 64 6f 63 75 6d 65 6e t of the documen
2b20: 74 20 6f 72 20 65 78 74 65 72 6e 61 6c 20 65 6e t or external en
2b30: 74 69 74 79 20 6f 72 20 74 68 65 20 6c 61 73 74 tity or the last
2b40: 20 73 75 63 68 20 63 61 6c 6c 20 61 66 74 65 72 such call after
2b50: 0a 23 62 79 74 65 73 20 76 61 6c 75 65 20 67 69 .#bytes value gi
2b60: 76 65 6e 20 62 79 20 74 68 65 20 3c 69 20 63 6c ven by the <i cl
2b70: 61 73 73 3d 22 6d 22 3e 2d 66 65 65 64 62 61 63 ass="m">-feedbac
2b80: 6b 41 66 74 65 72 3c 2f 69 3e 20 6f 70 74 69 6f kAfter</i> optio
2b90: 6e 2e 20 49 66 0a 3c 69 20 63 6c 61 73 73 3d 22 n. If.<i class="
2ba0: 6d 22 3e 2d 66 65 65 64 62 61 63 6b 41 66 74 65 m">-feedbackAfte
2bb0: 72 3c 2f 69 3e 20 69 73 6e 27 74 20 67 69 76 65 r</i> isn't give
2bc0: 6e 2c 20 75 73 69 6e 67 20 74 68 69 73 20 6f 70 n, using this op
2bd0: 74 69 6f 6e 0a 64 6f 65 73 6e 27 74 20 68 61 73 tion.doesn't has
2be0: 20 61 6e 79 20 65 66 66 65 63 74 2e 20 49 66 20 any effect. If
2bf0: 74 68 65 20 63 61 6c 6c 65 64 0a 73 63 72 69 70 the called.scrip
2c00: 74 20 72 61 69 73 65 73 20 65 72 72 6f 72 2c 20 t raises error,
2c10: 74 68 65 6e 20 70 61 72 73 69 6e 67 20 77 69 6c then parsing wil
2c20: 6c 20 62 65 20 61 62 6f 72 74 65 64 2c 20 74 68 l be aborted, th
2c30: 65 0a 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 e.<i class="m">d
2c40: 6f 6d 20 70 61 72 73 65 3c 2f 69 3e 20 63 61 6c om parse</i> cal
2c50: 6c 20 72 65 74 75 72 6e 73 20 65 72 72 6f 72 2c l returns error,
2c60: 20 77 69 74 68 20 74 68 65 20 73 63 72 69 70 74 with the script
2c70: 0a 65 72 72 6f 72 20 6d 73 67 20 61 73 20 65 72 .error msg as er
2c80: 72 6f 72 20 6d 73 67 2e 20 49 66 20 74 68 65 20 ror msg. If the
2c90: 63 61 6c 6c 65 64 20 73 63 72 69 70 74 20 3c 69 called script <i
2ca0: 20 63 6c 61 73 73 3d 22 6d 22 3e 72 65 74 75 72 class="m">retur
2cb0: 6e 0a 2d 63 6f 64 65 20 62 72 65 61 6b 3c 2f 69 n.-code break</i
2cc0: 3e 2c 20 74 68 65 20 70 61 72 73 69 6e 67 20 77 >, the parsing w
2cd0: 69 6c 6c 20 61 62 6f 72 74 20 61 6e 64 20 74 68 ill abort and th
2ce0: 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 e <i class="m">d
2cf0: 6f 6d 0a 70 61 72 73 65 3c 2f 69 3e 20 63 61 6c om.parse</i> cal
2d00: 6c 20 77 69 6c 6c 20 72 65 74 75 72 6e 20 74 68 l will return th
2d10: 65 20 65 6d 70 74 79 20 73 74 72 69 6e 67 2e 3c e empty string.<
2d20: 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 /dd>.
2d30: 20 20 20 0a 0a 20 20 20 20 20 20 20 20 20 20 20 ..
2d40: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 .
2d50: 20 20 20 20 3c 64 74 3e 0a 3c 62 3e 2d 65 78 74 <dt>.<b>-ext
2d60: 65 72 6e 61 6c 65 6e 74 69 74 79 63 6f 6d 6d 61 ernalentitycomma
2d70: 6e 64 3c 2f 62 3e 20 3c 69 3e 26 6c 74 3b 73 63 nd</b> <i><sc
2d80: 72 69 70 74 26 67 74 3b 3c 2f 69 3e 0a 3c 2f 64 ript></i>.</d
2d90: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 t>.
2da0: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 .
2db0: 20 20 20 20 3c 64 64 3e 49 66 20 3c 69 20 63 6c <dd>If <i cl
2dc0: 61 73 73 3d 22 6d 22 3e 2d 65 78 74 65 72 6e 61 ass="m">-externa
2dd0: 6c 65 6e 74 69 74 79 63 6f 6d 6d 61 6e 64 20 26 lentitycommand &
2de0: 6c 74 3b 73 63 72 69 70 74 26 67 74 3b 3c 2f 69 lt;script></i
2df0: 3e 20 69 73 0a 73 70 65 63 69 66 69 65 64 2c 20 > is.specified,
2e00: 74 68 65 20 73 70 65 63 69 66 69 65 64 20 74 63 the specified tc
2e10: 6c 20 73 63 72 69 70 74 20 69 73 20 63 61 6c 6c l script is call
2e20: 65 64 20 74 6f 20 72 65 73 6f 6c 76 65 20 61 6e ed to resolve an
2e30: 79 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 y external entit
2e40: 69 65 73 0a 6f 66 20 74 68 65 20 64 6f 63 75 6d ies.of the docum
2e50: 65 6e 74 2e 20 54 68 65 20 61 63 74 75 61 6c 20 ent. The actual
2e60: 65 76 61 6c 75 61 74 65 64 20 63 6f 6d 6d 61 6e evaluated comman
2e70: 64 20 63 6f 6e 73 69 73 74 73 20 6f 66 20 74 68 d consists of th
2e80: 69 73 20 6f 70 74 69 6f 6e 20 66 6f 6c 6c 6f 77 is option follow
2e90: 65 64 0a 62 79 20 74 68 72 65 65 20 61 72 67 75 ed.by three argu
2ea0: 6d 65 6e 74 73 3a 20 74 68 65 20 62 61 73 65 20 ments: the base
2eb0: 75 72 69 2c 20 74 68 65 20 73 79 73 74 65 6d 20 uri, the system
2ec0: 69 64 65 6e 74 69 66 69 65 72 20 6f 66 20 74 68 identifier of th
2ed0: 65 20 65 6e 74 69 74 79 20 61 6e 64 20 74 68 65 e entity and the
2ee0: 0a 70 75 62 6c 69 63 20 69 64 65 6e 74 69 66 69 .public identifi
2ef0: 65 72 20 6f 66 20 74 68 65 20 65 6e 74 69 74 79 er of the entity
2f00: 2e 20 54 68 65 20 62 61 73 65 20 75 72 69 20 61 . The base uri a
2f10: 6e 64 20 74 68 65 20 70 75 62 6c 69 63 20 69 64 nd the public id
2f20: 65 6e 74 69 66 69 65 72 20 6d 61 79 20 62 65 0a entifier may be.
2f30: 74 68 65 20 65 6d 70 74 79 20 6c 69 73 74 2e 20 the empty list.
2f40: 54 68 65 20 73 63 72 69 70 74 20 68 61 73 20 74 The script has t
2f50: 6f 20 72 65 74 75 72 6e 20 61 20 74 63 6c 20 6c o return a tcl l
2f60: 69 73 74 20 63 6f 6e 73 69 73 74 69 6e 67 20 6f ist consisting o
2f70: 66 20 74 68 72 65 65 0a 65 6c 65 6d 65 6e 74 73 f three.elements
2f80: 2e 20 54 68 65 20 66 69 72 73 74 20 65 6c 65 6d . The first elem
2f90: 65 6e 74 20 6f 66 20 74 68 69 73 20 6c 69 73 74 ent of this list
2fa0: 20 73 69 67 6e 61 6c 73 20 68 6f 77 20 74 68 65 signals how the
2fb0: 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 79 external entity
2fc0: 20 69 73 0a 72 65 74 75 72 6e 65 64 20 74 6f 20 is.returned to
2fd0: 74 68 65 20 70 72 6f 63 65 73 73 6f 72 2e 20 43 the processor. C
2fe0: 75 72 72 65 6e 74 6c 79 20 74 68 65 20 74 77 6f urrently the two
2ff0: 20 61 6c 6c 6f 77 65 64 20 74 79 70 65 73 20 61 allowed types a
3000: 72 65 20 22 73 74 72 69 6e 67 22 0a 61 6e 64 20 re "string".and
3010: 22 63 68 61 6e 6e 65 6c 22 2e 20 54 68 65 20 73 "channel". The s
3020: 65 63 6f 6e 64 20 65 6c 65 6d 65 6e 74 20 6f 66 econd element of
3030: 20 74 68 65 20 6c 69 73 74 20 68 61 73 20 74 6f the list has to
3040: 20 62 65 20 74 68 65 20 28 61 62 73 6f 6c 75 74 be the (absolut
3050: 65 29 20 62 61 73 65 20 55 52 49 0a 6f 66 20 74 e) base URI.of t
3060: 68 65 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 he external enti
3070: 74 79 20 74 6f 20 62 65 20 70 61 72 73 65 64 2e ty to be parsed.
3080: 20 20 54 68 65 20 74 68 69 72 64 20 65 6c 65 6d The third elem
3090: 65 6e 74 20 6f 66 20 74 68 65 20 6c 69 73 74 20 ent of the list
30a0: 61 72 65 20 64 61 74 61 2c 0a 65 69 74 68 65 72 are data,.either
30b0: 20 74 68 65 20 61 6c 72 65 61 64 79 20 72 65 61 the already rea
30c0: 64 20 64 61 74 61 20 6f 75 74 20 6f 66 20 74 68 d data out of th
30d0: 65 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 74 e external entit
30e0: 79 20 61 73 20 73 74 72 69 6e 67 20 69 6e 20 74 y as string in t
30f0: 68 65 20 63 61 73 65 0a 6f 66 20 74 79 70 65 20 he case.of type
3100: 22 73 74 72 69 6e 67 22 2c 20 6f 72 20 74 68 65 "string", or the
3110: 20 6e 61 6d 65 20 6f 66 20 61 20 74 63 6c 20 63 name of a tcl c
3120: 68 61 6e 6e 65 6c 2c 20 69 6e 20 74 68 65 20 63 hannel, in the c
3130: 61 73 65 20 6f 66 20 74 79 70 65 0a 22 63 68 61 ase of type."cha
3140: 6e 6e 65 6c 22 2e 20 4e 6f 74 65 20 74 68 61 74 nnel". Note that
3150: 20 69 66 20 74 68 65 20 73 63 72 69 70 74 20 72 if the script r
3160: 65 74 75 72 6e 73 20 61 20 74 63 6c 20 63 68 61 eturns a tcl cha
3170: 6e 6e 65 6c 2c 20 69 74 20 77 69 6c 6c 20 6e 6f nnel, it will no
3180: 74 20 62 65 20 63 6c 6f 73 65 64 0a 62 79 20 74 t be closed.by t
3190: 68 65 20 70 72 6f 63 65 73 73 6f 72 2e 20 20 49 he processor. I
31a0: 74 20 6d 75 73 74 20 62 65 20 63 6c 6f 73 65 64 t must be closed
31b0: 20 73 65 70 61 72 61 74 65 6c 79 20 69 66 20 69 separately if i
31c0: 74 20 69 73 20 6e 6f 20 6c 6f 6e 67 65 72 0a 6e t is no longer.n
31d0: 65 65 64 65 64 2e 3c 2f 64 64 3e 0a 20 20 20 20 eeded.</dd>.
31e0: 20 20 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 ..
31f0: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
3200: 20 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a <dt>.
3210: 3c 62 3e 2d 75 73 65 46 6f 72 65 69 67 6e 44 54 <b>-useForeignDT
3220: 44 3c 2f 62 3e 20 3c 69 3e 26 6c 74 3b 62 6f 6f D</b> <i><boo
3230: 6c 65 61 6e 26 67 74 3b 3c 2f 69 3e 0a 3c 2f 64 lean></i>.</d
3240: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 t>.
3250: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 .
3260: 20 20 20 20 3c 64 64 3e 49 66 20 26 6c 74 3b 62 <dd>If <b
3270: 6f 6f 6c 65 61 6e 26 67 74 3b 20 69 73 20 74 72 oolean> is tr
3280: 75 65 20 61 6e 64 20 74 68 65 20 64 6f 63 75 6d ue and the docum
3290: 65 6e 74 20 64 6f 65 73 20 6e 6f 74 20 68 61 76 ent does not hav
32a0: 65 0a 61 6e 20 65 78 74 65 72 6e 61 6c 20 73 75 e.an external su
32b0: 62 73 65 74 2c 20 74 68 65 20 70 61 72 73 65 72 bset, the parser
32c0: 20 77 69 6c 6c 20 63 61 6c 6c 20 74 68 65 20 2d will call the -
32d0: 65 78 74 65 72 6e 61 6c 65 6e 74 69 74 79 63 6f externalentityco
32e0: 6d 6d 61 6e 64 20 73 63 72 69 70 74 20 77 69 74 mmand script wit
32f0: 68 0a 65 6d 70 74 79 20 76 61 6c 75 65 73 20 66 h.empty values f
3300: 6f 72 20 74 68 65 20 73 79 73 74 65 6d 49 64 20 or the systemId
3310: 61 6e 64 20 70 75 62 6c 69 63 49 44 20 61 72 67 and publicID arg
3320: 75 6d 65 6e 74 73 2e 20 50 6c 65 61 73 65 20 6e uments. Please n
3330: 6f 74 65 20 74 68 61 74 20 69 66 0a 74 68 65 20 ote that if.the
3340: 64 6f 63 75 6d 65 6e 74 20 61 6c 73 6f 20 64 6f document also do
3350: 65 73 6e 27 74 20 68 61 76 65 20 61 6e 20 69 6e esn't have an in
3360: 74 65 72 6e 61 6c 20 73 75 62 73 65 74 2c 20 74 ternal subset, t
3370: 68 65 0a 2d 73 74 61 72 74 64 6f 63 74 79 70 65 he.-startdoctype
3380: 64 65 63 6c 63 6f 6d 6d 61 6e 64 20 61 6e 64 20 declcommand and
3390: 2d 65 6e 64 64 6f 63 74 79 70 65 64 65 63 6c 63 -enddoctypedeclc
33a0: 6f 6d 6d 61 6e 64 20 73 63 72 69 70 74 73 2c 20 ommand scripts,
33b0: 69 66 20 73 65 74 2c 20 61 72 65 20 6e 6f 74 0a if set, are not.
33c0: 63 61 6c 6c 65 64 2e 20 54 68 65 20 3c 69 20 63 called. The <i c
33d0: 6c 61 73 73 3d 22 6d 22 3e 2d 75 73 65 46 6f 72 lass="m">-useFor
33e0: 65 69 67 6e 44 54 44 3c 2f 69 3e 20 72 65 73 70 eignDTD</i> resp
33f0: 65 63 74 73 20 3c 2f 64 64 3e 0a 20 20 20 20 20 ects </dd>.
3400: 20 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 ..
3410: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
3420: 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a 3c <dt>.<
3430: 62 3e 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61 b>-paramentitypa
3440: 72 73 69 6e 67 3c 2f 62 3e 20 3c 69 3e 26 6c 74 rsing</b> <i><
3450: 3b 61 6c 77 61 79 73 7c 6e 65 76 65 72 7c 6e 6f ;always|never|no
3460: 74 73 74 61 6e 64 61 6c 6f 6e 65 26 67 74 3b 3c tstandalone><
3470: 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 20 20 20 /i>.</dt>.
3480: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
3490: 20 20 20 20 20 20 20 20 20 20 20 3c 64 64 3e 54 <dd>T
34a0: 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e he <i class="m">
34b0: 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61 72 73 -paramentitypars
34c0: 69 6e 67 3c 2f 69 3e 20 6f 70 74 69 6f 6e 20 63 ing</i> option c
34d0: 6f 6e 74 72 6f 6c 73 2c 0a 20 20 20 20 20 20 20 ontrols,.
34e0: 20 20 20 20 20 20 20 20 20 69 66 20 74 68 65 20 if the
34f0: 70 61 72 73 65 72 20 74 72 69 65 73 20 74 6f 20 parser tries to
3500: 72 65 73 6f 6c 76 65 20 74 68 65 20 65 78 74 65 resolve the exte
3510: 72 6e 61 6c 20 65 6e 74 69 74 69 65 73 0a 20 20 rnal entities.
3520: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 69 (i
3530: 6e 63 6c 75 64 69 6e 67 20 74 68 65 20 65 78 74 ncluding the ext
3540: 65 72 6e 61 6c 20 44 54 44 20 73 75 62 73 65 74 ernal DTD subset
3550: 29 20 6f 66 20 74 68 65 20 64 6f 63 75 6d 65 6e ) of the documen
3560: 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 t.
3570: 20 20 77 68 69 6c 65 20 62 75 69 6c 64 69 6e 67 while building
3580: 20 74 68 65 20 44 4f 4d 20 74 72 65 65 2e 0a 20 the DOM tree..
3590: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
35a0: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 70 61 72 i class="m">-par
35b0: 61 6d 65 6e 74 69 74 79 70 61 72 73 69 6e 67 3c amentityparsing<
35c0: 2f 69 3e 20 72 65 71 75 69 72 65 73 20 61 6e 20 /i> requires an
35d0: 61 72 67 75 6d 65 6e 74 2c 20 77 68 69 63 68 0a argument, which.
35e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
35f0: 6d 75 73 74 20 62 65 20 65 69 74 68 65 72 20 22 must be either "
3600: 61 6c 77 61 79 73 22 2c 20 22 6e 65 76 65 72 22 always", "never"
3610: 2c 20 6f 72 20 22 6e 6f 74 73 74 61 6e 64 61 6c , or "notstandal
3620: 6f 6e 65 22 2e 0a 20 20 20 20 20 20 20 20 20 20 one"..
3630: 20 20 20 20 20 20 54 68 65 20 76 61 6c 75 65 20 The value
3640: 22 61 6c 77 61 79 73 22 20 6d 65 61 6e 73 20 74 "always" means t
3650: 68 61 74 20 74 68 65 20 70 61 72 73 65 72 20 74 hat the parser t
3660: 72 69 65 73 20 74 6f 0a 20 20 20 20 20 20 20 20 ries to.
3670: 20 20 20 20 20 20 20 20 72 65 73 6f 6c 76 65 73 resolves
3680: 20 28 72 65 63 75 72 73 69 76 65 6c 79 29 20 61 (recursively) a
3690: 6c 6c 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 69 ll external enti
36a0: 74 69 65 73 20 6f 66 20 74 68 65 0a 20 20 20 20 ties of the.
36b0: 20 20 20 20 20 20 20 20 20 20 20 20 58 4d 4c 20 XML
36c0: 73 6f 75 72 63 65 2e 20 54 68 69 73 20 69 73 20 source. This is
36d0: 74 68 65 20 64 65 66 61 75 6c 74 20 69 6e 20 63 the default in c
36e0: 61 73 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 ase.
36f0: 20 20 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 <i class="m"
3700: 3e 2d 70 61 72 61 6d 65 6e 74 69 74 79 70 61 72 >-paramentitypar
3710: 73 69 6e 67 3c 2f 69 3e 20 69 73 20 6f 6d 69 74 sing</i> is omit
3720: 74 65 64 2e 20 54 68 65 20 76 61 6c 75 65 0a 20 ted. The value.
3730: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 22 "
3740: 6e 65 76 65 72 22 20 6d 65 61 6e 73 20 74 68 61 never" means tha
3750: 74 20 6f 6e 6c 79 20 74 68 65 20 67 69 76 65 6e t only the given
3760: 20 58 4d 4c 20 73 6f 75 72 63 65 20 69 73 0a 20 XML source is.
3770: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 70 p
3780: 61 72 73 65 64 20 61 6e 64 20 6e 6f 20 65 78 74 arsed and no ext
3790: 65 72 6e 61 6c 20 65 6e 74 69 74 79 20 28 69 6e ernal entity (in
37a0: 63 6c 75 64 69 6e 67 20 74 68 65 20 65 78 74 65 cluding the exte
37b0: 72 6e 61 6c 0a 20 20 20 20 20 20 20 20 20 20 20 rnal.
37c0: 20 20 20 20 20 73 75 62 73 65 74 29 20 77 69 6c subset) wil
37d0: 6c 20 62 65 20 72 65 73 6f 6c 76 65 64 20 61 6e l be resolved an
37e0: 64 20 70 61 72 73 65 64 2e 20 54 68 65 20 76 61 d parsed. The va
37f0: 6c 75 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 lue.
3800: 20 20 20 20 22 6e 6f 74 73 74 61 6e 64 61 6c 6f "notstandalo
3810: 6e 65 22 20 6d 65 61 6e 73 2c 20 74 68 61 74 20 ne" means, that
3820: 61 6c 6c 20 65 78 74 65 72 6e 61 6c 20 65 6e 74 all external ent
3830: 69 74 69 65 73 20 77 69 6c 6c 0a 20 20 20 20 20 ities will.
3840: 20 20 20 20 20 20 20 20 20 20 20 62 65 20 72 65 be re
3850: 73 6f 6c 76 65 64 20 61 6e 64 20 70 61 72 73 65 solved and parse
3860: 64 2c 20 77 69 74 68 20 74 68 65 20 65 78 63 65 d, with the exce
3870: 70 74 69 6f 6e 20 6f 66 0a 20 20 20 20 20 20 20 ption of.
3880: 20 20 20 20 20 20 20 20 20 64 6f 63 75 6d 65 6e documen
3890: 74 73 2c 20 77 68 69 63 68 20 65 78 70 6c 69 63 ts, which explic
38a0: 69 74 6c 79 20 73 74 61 74 65 73 20 73 74 61 6e itly states stan
38b0: 64 61 6c 6f 6e 65 3d 22 79 65 73 22 20 69 6e 0a dalone="yes" in.
38c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
38d0: 74 68 65 69 72 20 58 4d 4c 20 64 65 63 6c 61 72 their XML declar
38e0: 61 74 69 6f 6e 2e 3c 2f 64 64 3e 0a 20 20 20 20 ation.</dd>.
38f0: 20 20 20 20 20 20 20 20 20 20 0a 0a 0a 20 20 20 ...
3900: 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 .
3910: 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e <dt>
3920: 3c 62 3e 2d 69 67 6e 6f 72 65 78 6d 6c 6e 73 3c <b>-ignorexmlns<
3930: 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 /b></dt>.
3940: 20 20 20 20 20 20 20 20 20 3c 64 64 3e 49 74 20 <dd>It
3950: 69 73 20 72 65 63 6f 6d 6d 65 6e 64 65 64 2c 20 is recommended,
3960: 74 68 61 74 20 79 6f 75 20 6f 6e 6c 79 20 75 73 that you only us
3970: 65 20 74 68 69 73 20 6f 70 74 69 6f 6e 0a 20 20 e this option.
3980: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 69 wi
3990: 74 68 20 74 68 65 20 3c 69 20 63 6c 61 73 73 3d th the <i class=
39a0: 22 6d 22 3e 2d 68 74 6d 6c 35 3c 2f 69 3e 20 6f "m">-html5</i> o
39b0: 70 74 69 6f 6e 2e 20 49 66 20 74 68 69 73 20 6f ption. If this o
39c0: 70 74 69 6f 6e 20 69 73 0a 20 20 20 20 20 20 20 ption is.
39d0: 20 20 20 20 20 20 20 20 20 67 69 76 65 6e 2c 20 given,
39e0: 6e 6f 20 6e 6f 64 65 20 77 69 74 68 69 6e 20 74 no node within t
39f0: 68 65 20 63 72 65 61 74 65 64 20 44 4f 4d 20 74 he created DOM t
3a00: 72 65 65 20 77 69 6c 6c 20 62 65 0a 20 20 20 20 ree will be.
3a10: 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 inte
3a20: 72 6e 61 6c 6c 79 20 6d 61 72 6b 65 64 20 61 73 rnally marked as
3a30: 20 70 6c 61 63 65 64 20 69 6e 74 6f 20 61 6e 20 placed into an
3a40: 58 4d 4c 20 4e 61 6d 65 73 70 61 63 65 2c 0a 20 XML Namespace,.
3a50: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 65 e
3a60: 76 65 6e 20 69 66 20 74 68 65 72 65 20 69 73 20 ven if there is
3a70: 61 20 64 65 66 61 75 6c 74 20 6e 61 6d 65 73 70 a default namesp
3a80: 61 63 65 20 69 6e 20 73 63 6f 70 65 20 66 6f 72 ace in scope for
3a90: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
3aa0: 20 75 6e 2d 70 72 65 66 69 78 65 64 20 65 6c 65 un-prefixed ele
3ab0: 6d 65 6e 74 73 20 6f 72 20 65 76 65 6e 20 69 66 ments or even if
3ac0: 20 74 68 65 20 65 6c 65 6d 65 6e 74 20 68 61 73 the element has
3ad0: 20 61 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 a.
3ae0: 20 20 20 64 65 66 69 6e 65 64 20 6e 61 6d 65 73 defined names
3af0: 70 61 63 65 20 70 72 65 66 69 78 2e 20 4f 6e 65 pace prefix. One
3b00: 20 63 6f 6e 73 65 71 75 65 6e 63 65 20 69 73 20 consequence is
3b10: 74 68 61 74 0a 20 20 20 20 20 20 20 20 20 20 20 that.
3b20: 20 20 20 20 20 58 50 61 74 68 20 6e 6f 64 65 20 XPath node
3b30: 65 78 70 72 65 73 73 69 6f 6e 73 20 6f 6e 20 73 expressions on s
3b40: 75 63 68 20 61 20 44 4f 4d 20 74 72 65 65 20 64 uch a DOM tree d
3b50: 6f 65 73 6e 27 74 20 77 6f 72 6b 0a 20 20 20 20 oesn't work.
3b60: 20 20 20 20 20 20 20 20 20 20 20 20 61 73 20 65 as e
3b70: 78 70 65 63 74 65 64 2e 20 50 72 65 66 69 78 65 xpected. Prefixe
3b80: 64 20 65 6c 65 6d 65 6e 74 20 6e 6f 64 65 73 20 d element nodes
3b90: 63 61 6e 27 74 20 62 65 20 73 65 6c 65 63 74 65 can't be selecte
3ba0: 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 d.
3bb0: 20 20 61 6e 64 20 65 6c 65 6d 65 6e 74 20 6e 6f and element no
3bc0: 64 65 73 20 77 69 74 68 6f 75 74 20 70 72 65 66 des without pref
3bd0: 69 78 20 77 69 6c 6c 20 62 65 20 73 65 65 6e 20 ix will be seen
3be0: 62 79 20 58 50 61 74 68 0a 20 20 20 20 20 20 20 by XPath.
3bf0: 20 20 20 20 20 20 20 20 20 65 78 70 72 65 73 73 express
3c00: 69 6f 6e 73 20 61 73 20 69 66 20 74 68 65 79 20 ions as if they
3c10: 61 72 65 20 6e 6f 74 20 69 6e 20 61 6e 79 20 6e are not in any n
3c20: 61 6d 65 73 70 61 63 65 20 28 6e 6f 0a 20 20 20 amespace (no.
3c30: 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 74 mat
3c40: 74 65 72 20 69 66 20 74 68 65 79 20 61 72 65 20 ter if they are
3c50: 69 6e 20 66 61 63 74 20 73 68 6f 75 6c 64 20 62 in fact should b
3c60: 65 20 69 6e 20 61 20 64 65 66 61 75 6c 74 0a 20 e in a default.
3c70: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6e n
3c80: 61 6d 65 73 70 61 63 65 29 2e 0a 20 20 20 20 20 amespace)..
3c90: 20 20 20 20 20 20 20 20 20 20 20 3c 2f 64 64 3e </dd>
3ca0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a . .
3cb0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c 2f 64 . </d
3cc0: 6c 3e 0a 3c 70 3e 3c 2f 70 3e 0a 3c 2f 64 64 3e l>.<p></p>.</dd>
3cd0: 0a 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 . ..
3ce0: 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c 64 . <d
3cf0: 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 t>.<b class="cmd
3d00: 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 ">dom</b> <b cla
3d10: 73 73 3d 22 6d 65 74 68 6f 64 22 3e 63 72 65 61 ss="method">crea
3d20: 74 65 44 6f 63 75 6d 65 6e 74 3c 2f 62 3e 0a 3c teDocument</b>.<
3d30: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 6f 63 45 i class="m">docE
3d40: 6c 65 6d 4e 61 6d 65 3c 2f 69 3e 20 3f 3c 69 20 lemName</i> ?<i
3d50: 63 6c 61 73 73 3d 22 6d 22 3e 6f 62 6a 56 61 72 class="m">objVar
3d60: 3c 2f 69 3e 3f 3c 2f 64 74 3e 0a 20 20 20 20 20 </i>?</dt>.
3d70: 20 20 20 20 20 3c 64 64 3e 43 72 65 61 74 65 73 <dd>Creates
3d80: 20 61 20 6e 65 77 20 44 4f 4d 20 64 6f 63 75 6d a new DOM docum
3d90: 65 6e 74 20 6f 62 6a 65 63 74 20 77 69 74 68 20 ent object with
3da0: 6f 6e 65 20 65 6c 65 6d 65 6e 74 20 6e 6f 64 65 one element node
3db0: 20 77 69 74 68 0a 6e 6f 64 65 20 6e 61 6d 65 20 with.node name
3dc0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 6f 63 <i class="m">doc
3dd0: 45 6c 65 6d 4e 61 6d 65 3c 2f 69 3e 2e 20 54 68 ElemName</i>. Th
3de0: 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 6f e <i class="m">o
3df0: 62 6a 56 61 72 3c 2f 69 3e 20 63 6f 6e 74 72 6f bjVar</i> contro
3e00: 6c 73 20 74 68 65 0a 6d 65 6d 6f 72 79 20 68 61 ls the.memory ha
3e10: 6e 64 6c 69 6e 67 20 61 73 20 65 78 70 6c 61 69 ndling as explai
3e20: 6e 65 64 20 61 62 6f 76 65 2e 3c 2f 64 64 3e 0a ned above.</dd>.
3e30: 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 ..
3e40: 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c 64 74 . <dt
3e50: 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 >.<b class="cmd"
3e60: 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 >dom</b> <b clas
3e70: 73 3d 22 6d 65 74 68 6f 64 22 3e 63 72 65 61 74 s="method">creat
3e80: 65 44 6f 63 75 6d 65 6e 74 4e 53 3c 2f 62 3e 0a eDocumentNS</b>.
3e90: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 75 72 69 <i class="m">uri
3ea0: 3c 2f 69 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d </i> <i class="m
3eb0: 22 3e 64 6f 63 45 6c 65 6d 4e 61 6d 65 3c 2f 69 ">docElemName</i
3ec0: 3e 20 3f 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e > ?<i class="m">
3ed0: 6f 62 6a 56 61 72 3c 2f 69 3e 3f 3c 2f 64 74 3e objVar</i>?</dt>
3ee0: 0a 20 20 20 20 20 20 20 20 20 20 3c 64 64 3e 43 . <dd>C
3ef0: 72 65 61 74 65 73 20 61 20 6e 65 77 20 44 4f 4d reates a new DOM
3f00: 20 64 6f 63 75 6d 65 6e 74 20 6f 62 6a 65 63 74 document object
3f10: 20 77 69 74 68 20 6f 6e 65 20 65 6c 65 6d 65 6e with one elemen
3f20: 74 20 6e 6f 64 65 20 77 69 74 68 0a 6e 6f 64 65 t node with.node
3f30: 20 6e 61 6d 65 20 3c 69 20 63 6c 61 73 73 3d 22 name <i class="
3f40: 6d 22 3e 64 6f 63 45 6c 65 6d 4e 61 6d 65 3c 2f m">docElemName</
3f50: 69 3e 2e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 i>. <i class="m"
3f60: 3e 55 72 69 3c 2f 69 3e 20 67 69 76 65 73 20 74 >Uri</i> gives t
3f70: 68 65 20 6e 61 6d 65 73 70 61 63 65 20 6f 66 20 he namespace of
3f80: 74 68 65 0a 64 6f 63 75 6d 65 6e 74 20 65 6c 65 the.document ele
3f90: 6d 65 6e 74 20 74 6f 20 63 72 65 61 74 65 2e 20 ment to create.
3fa0: 54 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 The <i class="m"
3fb0: 3e 6f 62 6a 56 61 72 3c 2f 69 3e 20 63 6f 6e 74 >objVar</i> cont
3fc0: 72 6f 6c 73 20 74 68 65 0a 6d 65 6d 6f 72 79 20 rols the.memory
3fd0: 68 61 6e 64 6c 69 6e 67 20 61 73 20 65 78 70 6c handling as expl
3fe0: 61 69 6e 65 64 20 61 62 6f 76 65 2e 3c 2f 64 64 ained above.</dd
3ff0: 3e 0a 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 >. ..
4000: 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c . <
4010: 64 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d dt>.<b class="cm
4020: 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c d">dom</b> <b cl
4030: 61 73 73 3d 22 6d 65 74 68 6f 64 22 3e 63 72 65 ass="method">cre
4040: 61 74 65 44 6f 63 75 6d 65 6e 74 4e 6f 64 65 3c ateDocumentNode<
4050: 2f 62 3e 0a 3f 3c 69 20 63 6c 61 73 73 3d 22 6d /b>.?<i class="m
4060: 22 3e 6f 62 6a 56 61 72 3c 2f 69 3e 3f 3c 2f 64 ">objVar</i>?</d
4070: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 64 t>. <dd
4080: 3e 43 72 65 61 74 65 73 20 61 20 6e 65 77 20 27 >Creates a new '
4090: 65 6d 70 74 79 27 20 44 4f 4d 20 64 6f 63 75 6d empty' DOM docum
40a0: 65 6e 74 20 6f 62 6a 65 63 74 20 77 69 74 68 6f ent object witho
40b0: 75 74 20 61 6e 79 20 65 6c 65 6d 65 6e 74 0a 6e ut any element.n
40c0: 6f 64 65 2e 20 3c 69 20 63 6c 61 73 73 3d 22 6d ode. <i class="m
40d0: 22 3e 6f 62 6a 56 61 72 3c 2f 69 3e 20 63 6f 6e ">objVar</i> con
40e0: 74 72 6f 6c 73 20 74 68 65 20 6d 65 6d 6f 72 79 trols the memory
40f0: 20 68 61 6e 64 6c 69 6e 67 20 61 73 20 65 78 70 handling as exp
4100: 6c 61 69 6e 65 64 20 61 62 6f 76 65 2e 3c 2f 64 lained above.</d
4110: 64 3e 0a 20 20 20 20 20 20 20 20 0a 0a 20 20 20 d>. ..
4120: 20 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 .
4130: 3c 64 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 <dt>.<b class="c
4140: 6d 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 md">dom</b> <b c
4150: 6c 61 73 73 3d 22 6d 65 74 68 6f 64 22 3e 73 65 lass="method">se
4160: 74 52 65 73 75 6c 74 45 6e 63 6f 64 69 6e 67 3c tResultEncoding<
4170: 2f 62 3e 20 3f 3c 69 20 63 6c 61 73 73 3d 22 6d /b> ?<i class="m
4180: 22 3e 65 6e 63 6f 64 69 6e 67 4e 61 6d 65 3c 2f ">encodingName</
4190: 69 3e 3f 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 i>?</dt>.
41a0: 20 20 20 3c 64 64 3e 54 68 69 73 20 6f 70 74 69 <dd>This opti
41b0: 6f 6e 20 69 73 20 66 6f 72 20 62 61 63 6b 77 61 on is for backwa
41c0: 72 64 20 63 6f 6d 70 61 74 69 62 69 6c 69 74 79 rd compatibility
41d0: 20 77 69 74 68 20 54 63 6c 0a 20 20 20 20 20 20 with Tcl.
41e0: 20 20 20 20 38 2e 30 2e 20 49 66 20 74 44 4f 4d 8.0. If tDOM
41f0: 20 69 73 20 62 75 69 6c 64 20 77 69 74 68 20 61 is build with a
4200: 6e 79 20 6e 65 77 65 72 20 54 63 6c 20 76 65 72 ny newer Tcl ver
4210: 73 69 6f 6e 20 74 68 69 73 20 6f 70 74 69 6f 6e sion this option
4220: 0a 20 20 20 20 20 20 20 20 20 20 64 6f 65 73 20 . does
4230: 6e 6f 74 20 68 61 73 20 61 6e 79 20 65 66 66 65 not has any effe
4240: 63 74 2e 20 49 66 20 3c 69 20 63 6c 61 73 73 3d ct. If <i class=
4250: 22 6d 22 3e 65 6e 63 6f 64 69 6e 67 4e 61 6d 65 "m">encodingName
4260: 3c 2f 69 3e 20 69 73 20 6e 6f 74 20 67 69 76 65 </i> is not give
4270: 6e 0a 20 20 20 20 20 20 20 20 20 20 74 68 65 20 n. the
4280: 63 75 72 72 65 6e 74 20 67 6c 6f 62 61 6c 20 72 current global r
4290: 65 73 75 6c 74 20 65 6e 63 6f 64 69 6e 67 20 69 esult encoding i
42a0: 73 20 72 65 74 75 72 6e 65 64 2e 20 4f 74 68 65 s returned. Othe
42b0: 72 77 69 73 65 0a 20 20 20 20 20 20 20 20 20 20 rwise.
42c0: 74 68 65 20 67 6c 6f 62 61 6c 20 72 65 73 75 6c the global resul
42d0: 74 20 65 6e 63 6f 64 69 6e 67 20 69 73 20 73 65 t encoding is se
42e0: 74 20 74 6f 20 3c 69 20 63 6c 61 73 73 3d 22 6d t to <i class="m
42f0: 22 3e 65 6e 63 6f 64 69 6e 67 4e 61 6d 65 3c 2f ">encodingName</
4300: 69 3e 2e 0a 20 20 20 20 20 20 20 20 20 20 41 6c i>.. Al
4310: 6c 20 63 68 61 72 61 63 74 65 72 20 64 61 74 61 l character data
4320: 2c 20 61 74 74 72 69 62 75 74 65 20 76 61 6c 75 , attribute valu
4330: 65 73 20 65 74 63 2e 20 77 69 6c 6c 20 74 68 65 es etc. will the
4340: 6e 20 62 65 0a 20 20 20 20 20 20 20 20 20 20 63 n be. c
4350: 6f 6e 76 65 72 74 65 64 20 66 72 6f 6d 20 55 54 onverted from UT
4360: 46 2d 38 2c 20 77 68 69 63 68 20 69 73 20 64 65 F-8, which is de
4370: 6c 69 76 65 72 65 64 20 66 72 6f 6d 20 74 68 65 livered from the
4380: 20 45 78 70 61 74 20 58 4d 4c 0a 20 20 20 20 20 Expat XML.
4390: 20 20 20 20 20 70 61 72 73 65 72 2c 20 74 6f 20 parser, to
43a0: 74 68 65 20 67 69 76 65 6e 20 38 20 62 69 74 20 the given 8 bit
43b0: 65 6e 63 6f 64 69 6e 67 20 61 74 20 58 4d 4c 2f encoding at XML/
43c0: 44 4f 4d 20 70 61 72 73 65 20 74 69 6d 65 2e 0a DOM parse time..
43d0: 20 20 20 20 20 20 20 20 20 20 56 61 6c 69 64 20 Valid
43e0: 76 61 6c 75 65 73 20 66 6f 72 20 3c 69 20 63 6c values for <i cl
43f0: 61 73 73 3d 22 6d 22 3e 65 6e 63 6f 64 69 6e 67 ass="m">encoding
4400: 4e 61 6d 65 3c 2f 69 3e 20 61 72 65 3a 20 75 74 Name</i> are: ut
4410: 66 2d 38 2c 20 61 73 63 69 69 2c 0a 20 20 20 20 f-8, ascii,.
4420: 20 20 20 20 20 20 63 70 31 32 35 30 2c 20 63 70 cp1250, cp
4430: 31 32 35 31 2c 20 63 70 31 32 35 32 2c 20 63 70 1251, cp1252, cp
4440: 31 32 35 33 2c 20 63 70 31 32 35 34 2c 20 63 70 1253, cp1254, cp
4450: 31 32 35 35 2c 20 63 70 31 32 35 36 2c 0a 20 20 1255, cp1256,.
4460: 20 20 20 20 20 20 20 20 63 70 34 33 37 2c 20 63 cp437, c
4470: 70 38 35 30 2c 20 65 6e 2c 20 69 73 6f 38 38 35 p850, en, iso885
4480: 39 2d 31 2c 20 69 73 6f 38 38 35 39 2d 32 2c 20 9-1, iso8859-2,
4490: 69 73 6f 38 38 35 39 2d 33 2c 0a 20 20 20 20 20 iso8859-3,.
44a0: 20 20 20 20 20 69 73 6f 38 38 35 39 2d 34 2c 20 iso8859-4,
44b0: 69 73 6f 38 38 35 39 2d 35 2c 20 69 73 6f 38 38 iso8859-5, iso88
44c0: 35 39 2d 36 2c 20 69 73 6f 38 38 35 39 2d 37 2c 59-6, iso8859-7,
44d0: 20 69 73 6f 38 38 35 39 2d 38 2c 0a 20 20 20 20 iso8859-8,.
44e0: 20 20 20 20 20 20 69 73 6f 38 38 35 39 2d 39 2c iso8859-9,
44f0: 20 6b 6f 69 38 2d 72 2e 3c 2f 64 64 3e 0a 20 20 koi8-r.</dd>.
4500: 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 20 20 ..
4510: 0a 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a . <dt>.
4520: 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 64 <b class="cmd">d
4530: 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 73 3d om</b> <b class=
4540: 22 6d 65 74 68 6f 64 22 3e 63 72 65 61 74 65 4e "method">createN
4550: 6f 64 65 43 6d 64 3c 2f 62 3e 0a 3c 69 20 63 6c odeCmd</b>.<i cl
4560: 61 73 73 3d 22 6d 22 3e 3f 2d 72 65 74 75 72 6e ass="m">?-return
4570: 4e 6f 64 65 43 6d 64 3f 3c 2f 69 3e 20 3c 69 20 NodeCmd?</i> <i
4580: 63 6c 61 73 73 3d 22 6d 22 3e 3f 2d 74 61 67 4e class="m">?-tagN
4590: 61 6d 65 20 6e 61 6d 65 3f 3c 2f 69 3e 20 3c 69 ame name?</i> <i
45a0: 20 63 6c 61 73 73 3d 22 6d 22 3e 3f 2d 6a 73 6f class="m">?-jso
45b0: 6e 54 79 70 65 20 6a 73 6f 6e 54 79 70 65 3f 3c nType jsonType?<
45c0: 2f 69 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 /i> <i class="m"
45d0: 3e 3f 2d 6e 61 6d 65 73 70 61 63 65 20 55 52 49 >?-namespace URI
45e0: 3f 3c 2f 69 3e 20 3c 69 20 63 6c 61 73 73 3d 22 ?</i> <i class="
45f0: 6d 22 3e 28 65 6c 65 6d 65 6e 74 7c 63 6f 6d 6d m">(element|comm
4600: 65 6e 74 7c 74 65 78 74 7c 63 64 61 74 61 7c 70 ent|text|cdata|p
4610: 69 29 4e 6f 64 65 3c 2f 69 3e 20 3c 69 20 63 6c i)Node</i> <i cl
4620: 61 73 73 3d 22 6d 22 3e 63 6f 6d 6d 61 6e 64 4e ass="m">commandN
4630: 61 6d 65 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 ame</i>.</dt>.
4640: 20 20 20 20 20 20 20 20 3c 64 64 3e 54 68 69 73 <dd>This
4650: 20 6d 65 74 68 6f 64 20 63 72 65 61 74 65 73 20 method creates
4660: 54 63 6c 20 63 6f 6d 6d 61 6e 64 73 2c 20 77 68 Tcl commands, wh
4670: 69 63 68 20 69 6e 20 74 75 72 6e 20 63 72 65 61 ich in turn crea
4680: 74 65 0a 20 20 20 20 20 20 20 20 20 20 74 44 4f te. tDO
4690: 4d 20 6e 6f 64 65 73 2e 20 54 63 6c 20 63 6f 6d M nodes. Tcl com
46a0: 6d 61 6e 64 73 20 63 72 65 61 74 65 64 20 62 79 mands created by
46b0: 20 74 68 69 73 20 63 6f 6d 6d 61 6e 64 20 61 72 this command ar
46c0: 65 20 6f 6e 6c 79 0a 20 20 20 20 20 20 20 20 20 e only.
46d0: 20 61 76 61 69 6c 61 62 6c 65 20 69 6e 73 69 64 available insid
46e0: 65 20 61 20 73 63 72 69 70 74 20 67 69 76 65 6e e a script given
46f0: 20 74 6f 20 74 68 65 20 64 6f 6d 4e 6f 64 65 20 to the domNode
4700: 6d 65 74 68 6f 64 73 0a 20 20 20 20 20 20 20 20 methods.
4710: 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 61 <i class="m">a
4720: 70 70 65 6e 64 46 72 6f 6d 53 63 72 69 70 74 3c ppendFromScript<
4730: 2f 69 3e 20 6f 72 20 3c 69 20 63 6c 61 73 73 3d /i> or <i class=
4740: 22 6d 22 3e 69 6e 73 65 72 74 42 65 66 6f 72 65 "m">insertBefore
4750: 46 72 6f 6d 53 63 72 69 70 74 3c 2f 69 3e 2e 20 FromScript</i>.
4760: 49 66 0a 20 20 20 20 20 20 20 20 20 20 61 20 63 If. a c
4770: 6f 6d 6d 61 6e 64 20 63 72 65 61 74 65 64 20 77 ommand created w
4780: 69 74 68 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 ith <i class="m"
4790: 3e 63 72 65 61 74 65 4e 6f 64 65 43 6d 64 3c 2f >createNodeCmd</
47a0: 69 3e 20 69 73 20 69 6e 76 6f 6b 65 64 20 69 6e i> is invoked in
47b0: 0a 20 20 20 20 20 20 20 20 20 20 61 6e 79 20 6f . any o
47c0: 74 68 65 72 20 63 6f 6e 74 65 78 74 2c 20 69 74 ther context, it
47d0: 20 77 69 6c 6c 20 72 65 74 75 72 6e 20 65 72 72 will return err
47e0: 6f 72 2e 20 54 68 65 20 63 72 65 61 74 65 64 20 or. The created
47f0: 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 20 20 20 command.
4800: 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 63 <i class="m">c
4810: 6f 6d 6d 61 6e 64 4e 61 6d 65 3c 2f 69 3e 20 72 ommandName</i> r
4820: 65 70 6c 61 63 65 73 20 61 6e 79 20 65 78 69 73 eplaces any exis
4830: 74 69 6e 67 20 63 6f 6d 6d 61 6e 64 20 6f 72 0a ting command or.
4840: 20 20 20 20 20 20 20 20 20 20 70 72 6f 63 65 64 proced
4850: 75 72 65 20 77 69 74 68 20 74 68 61 74 20 6e 61 ure with that na
4860: 6d 65 2e 20 49 66 20 74 68 65 20 3c 69 20 63 6c me. If the <i cl
4870: 61 73 73 3d 22 6d 22 3e 63 6f 6d 6d 61 6e 64 4e ass="m">commandN
4880: 61 6d 65 3c 2f 69 3e 20 69 6e 63 6c 75 64 65 73 ame</i> includes
4890: 0a 20 20 20 20 20 20 20 20 20 20 61 6e 79 20 6e . any n
48a0: 61 6d 65 73 70 61 63 65 20 71 75 61 6c 69 66 69 amespace qualifi
48b0: 65 72 73 2c 20 69 74 20 69 73 20 63 72 65 61 74 ers, it is creat
48c0: 65 64 20 69 6e 20 74 68 65 20 73 70 65 63 69 66 ed in the specif
48d0: 69 65 64 0a 20 20 20 20 20 20 20 20 20 20 6e 61 ied. na
48e0: 6d 65 73 70 61 63 65 2e 20 54 68 65 20 3c 69 20 mespace. The <i
48f0: 63 6c 61 73 73 3d 22 6d 22 3e 2d 74 61 67 4e 61 class="m">-tagNa
4900: 6d 65 3c 2f 69 3e 20 6f 70 74 69 6f 6e 20 69 73 me</i> option is
4910: 20 6f 6e 6c 79 20 61 6c 6c 6f 77 65 64 20 66 6f only allowed fo
4920: 72 0a 20 20 20 20 20 20 20 20 20 20 74 68 65 20 r. the
4930: 65 6c 65 6d 65 6e 74 4e 6f 64 65 20 74 79 70 65 elementNode type
4940: 2e 20 54 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 . The <i class="
4950: 6d 22 3e 2d 6a 73 6f 6e 54 79 70 65 3c 2f 69 3e m">-jsonType</i>
4960: 20 6f 70 74 69 6f 6e 20 69 73 20 6f 6e 6c 79 0a option is only.
4970: 20 20 20 20 20 20 20 20 20 20 61 6c 6c 6f 77 65 allowe
4980: 64 20 66 6f 72 20 65 6c 65 6d 65 6e 74 4e 6f 64 d for elementNod
4990: 65 20 61 6e 64 20 74 65 78 74 4e 6f 64 65 20 74 e and textNode t
49a0: 79 70 65 73 2e 0a 0a 3c 70 3e 49 66 20 73 75 63 ypes...<p>If suc
49b0: 68 20 63 6f 6d 6d 61 6e 64 20 69 73 20 69 6e 76 h command is inv
49c0: 6f 6b 65 64 20 69 6e 73 69 64 65 20 61 20 73 63 oked inside a sc
49d0: 72 69 70 74 20 67 69 76 65 6e 20 61 73 20 61 72 ript given as ar
49e0: 67 75 6d 65 6e 74 20 74 6f 20 74 68 65 0a 64 6f gument to the.do
49f0: 6d 4e 6f 64 65 20 6d 65 74 68 6f 64 20 3c 69 20 mNode method <i
4a00: 63 6c 61 73 73 3d 22 6d 22 3e 61 70 70 65 6e 64 class="m">append
4a10: 46 72 6f 6d 53 63 72 69 70 74 3c 2f 69 3e 20 6f FromScript</i> o
4a20: 72 0a 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 69 r.<i class="m">i
4a30: 6e 73 65 72 74 42 65 66 6f 72 65 46 72 6f 6d 53 nsertBeforeFromS
4a40: 63 72 69 70 74 3c 2f 69 3e 20 69 74 20 63 72 65 cript</i> it cre
4a50: 61 74 65 73 20 61 20 6e 65 77 20 6e 6f 64 65 20 ates a new node
4a60: 61 6e 64 20 61 70 70 65 6e 64 73 20 74 68 69 73 and appends this
4a70: 0a 6e 6f 64 65 20 61 74 20 74 68 65 20 65 6e 64 .node at the end
4a80: 20 6f 66 20 74 68 65 20 63 68 69 6c 64 20 6c 69 of the child li
4a90: 73 74 20 6f 66 20 74 68 65 20 69 6e 76 6f 6b 69 st of the invoki
4aa0: 6e 67 20 65 6c 65 6d 65 6e 74 20 6e 6f 64 65 2e ng element node.
4ab0: 20 49 66 20 74 68 65 0a 6f 70 74 69 6f 6e 20 3c If the.option <
4ac0: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 72 65 74 i class="m">-ret
4ad0: 75 72 6e 4e 6f 64 65 43 6d 64 3c 2f 69 3e 20 77 urnNodeCmd</i> w
4ae0: 61 73 20 67 69 76 65 6e 2c 20 74 68 65 20 63 6f as given, the co
4af0: 6d 6d 61 6e 64 20 72 65 74 75 72 6e 73 20 74 68 mmand returns th
4b00: 65 0a 63 72 65 61 74 65 64 20 6e 6f 64 65 20 61 e.created node a
4b10: 73 20 54 63 6c 20 63 6f 6d 6d 61 6e 64 2e 20 49 s Tcl command. I
4b20: 66 20 74 68 69 73 20 6f 70 74 69 6f 6e 20 77 61 f this option wa
4b30: 73 20 6f 6d 69 74 74 65 64 2c 20 74 68 65 20 63 s omitted, the c
4b40: 6f 6d 6d 61 6e 64 0a 72 65 74 75 72 6e 73 20 6e ommand.returns n
4b50: 6f 74 68 69 6e 67 2e 20 45 61 63 68 20 63 6f 6d othing. Each com
4b60: 6d 61 6e 64 20 63 72 65 61 74 65 73 20 61 6c 77 mand creates alw
4b70: 61 79 73 20 74 68 65 20 73 61 6d 65 20 74 79 70 ays the same typ
4b80: 65 20 6f 66 20 6e 6f 64 65 2e 0a 57 68 69 63 68 e of node..Which
4b90: 20 74 79 70 65 20 6f 66 20 6e 6f 64 65 20 69 73 type of node is
4ba0: 20 63 72 65 61 74 65 64 20 62 79 20 74 68 65 20 created by the
4bb0: 63 6f 6d 6d 61 6e 64 20 69 73 20 64 65 74 65 72 command is deter
4bc0: 6d 69 6e 65 64 20 62 79 20 74 68 65 0a 66 69 72 mined by the.fir
4bd0: 73 74 20 61 72 67 75 6d 65 6e 74 20 74 6f 20 74 st argument to t
4be0: 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e he <i class="m">
4bf0: 63 72 65 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 69 createNodeCmd</i
4c00: 3e 2e 20 54 68 65 20 73 79 6e 74 61 78 20 6f 66 >. The syntax of
4c10: 20 74 68 65 20 63 72 65 61 74 65 64 0a 63 6f 6d the created.com
4c20: 6d 61 6e 64 20 64 65 70 65 6e 64 73 20 6f 6e 20 mand depends on
4c30: 74 68 65 20 74 79 70 65 20 6f 66 20 74 68 65 20 the type of the
4c40: 6e 6f 64 65 20 69 74 20 63 72 65 61 74 65 73 2e node it creates.
4c50: 3c 2f 70 3e 0a 0a 3c 70 3e 49 66 20 74 68 65 20 </p>..<p>If the
4c60: 63 6f 6d 6d 61 6e 64 20 74 79 70 65 20 74 6f 20 command type to
4c70: 63 72 65 61 74 65 20 69 73 20 3c 69 20 63 6c 61 create is <i cla
4c80: 73 73 3d 22 6d 22 3e 65 6c 65 6d 65 6e 74 4e 6f ss="m">elementNo
4c90: 64 65 3c 2f 69 3e 2c 20 74 68 65 20 63 72 65 61 de</i>, the crea
4ca0: 74 65 64 0a 63 6f 6d 6d 61 6e 64 20 77 69 6c 6c ted.command will
4cb0: 20 63 72 65 61 74 65 20 61 6e 20 65 6c 65 6d 65 create an eleme
4cc0: 6e 74 20 6e 6f 64 65 2c 20 69 66 20 63 61 6c 6c nt node, if call
4cd0: 65 64 2e 20 57 69 74 68 6f 75 74 20 74 68 65 0a ed. Without the.
4ce0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 74 61 <i class="m">-ta
4cf0: 67 4e 61 6d 65 3c 2f 69 3e 20 6f 70 74 69 6f 6e gName</i> option
4d00: 20 74 68 65 20 74 61 67 20 6e 61 6d 65 20 6f 66 the tag name of
4d10: 20 74 68 65 20 63 72 65 61 74 65 64 20 6e 6f 64 the created nod
4d20: 65 20 69 73 0a 3c 69 20 63 6c 61 73 73 3d 22 6d e is.<i class="m
4d30: 22 3e 63 6f 6d 6d 61 6e 64 4e 61 6d 65 3c 2f 69 ">commandName</i
4d40: 3e 20 77 69 74 68 6f 75 74 20 6e 61 6d 65 73 70 > without namesp
4d50: 61 63 65 20 71 75 61 6c 69 66 69 65 72 73 2e 20 ace qualifiers.
4d60: 49 66 20 74 68 65 0a 3c 69 20 63 6c 61 73 73 3d If the.<i class=
4d70: 22 6d 22 3e 2d 74 61 67 4e 61 6d 65 3c 2f 69 3e "m">-tagName</i>
4d80: 20 6f 70 74 69 6f 6e 20 77 61 73 20 67 69 76 65 option was give
4d90: 6e 20 74 68 65 6e 20 74 68 65 20 63 72 65 61 74 n then the creat
4da0: 65 64 20 63 6f 6d 6d 61 6e 64 20 74 68 65 20 63 ed command the c
4db0: 72 65 61 74 65 64 0a 65 6c 65 6d 65 6e 74 73 20 reated.elements
4dc0: 77 69 6c 6c 20 68 61 76 65 20 74 68 69 73 20 74 will have this t
4dd0: 61 67 20 6e 61 6d 65 2e 20 49 66 20 74 68 65 20 ag name. If the
4de0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 6a 73 <i class="m">-js
4df0: 6f 6e 54 79 70 65 3c 2f 69 3e 20 6f 70 74 69 6f onType</i> optio
4e00: 6e 20 77 61 73 0a 67 69 76 65 6e 20 74 68 65 6e n was.given then
4e10: 20 74 68 65 20 63 72 65 61 74 65 64 20 6e 6f 64 the created nod
4e20: 65 20 65 6c 65 6d 65 6e 74 73 20 77 69 6c 6c 20 e elements will
4e30: 68 61 76 65 20 74 68 65 20 67 69 76 65 6e 20 4a have the given J
4e40: 53 4f 4e 20 74 79 70 65 2e 20 49 66 0a 74 68 65 SON type. If.the
4e50: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 6e <i class="m">-n
4e60: 61 6d 65 73 70 61 63 65 3c 2f 69 3e 20 6f 70 74 amespace</i> opt
4e70: 69 6f 6e 20 69 73 20 67 69 76 65 6e 20 74 68 65 ion is given the
4e80: 20 63 72 65 61 74 65 64 20 65 6c 65 6d 65 6e 74 created element
4e90: 20 6e 6f 64 65 20 77 69 6c 6c 20 62 65 0a 58 4d node will be.XM
4ea0: 4c 20 6e 61 6d 65 73 70 61 63 65 64 20 61 6e 64 L namespaced and
4eb0: 20 69 6e 20 74 68 65 20 6e 61 6d 65 73 70 61 63 in the namespac
4ec0: 65 20 67 69 76 65 6e 20 62 79 20 74 68 65 20 6f e given by the o
4ed0: 70 74 69 6f 6e 2e 20 54 68 65 20 65 6c 65 6d 65 ption. The eleme
4ee0: 6e 74 0a 6e 61 6d 65 20 77 69 6c 6c 20 62 65 20 nt.name will be
4ef0: 6c 69 74 65 72 61 6c 20 61 73 20 67 69 76 65 6e literal as given
4f00: 20 65 69 74 68 65 72 20 62 79 20 74 68 65 20 63 either by the c
4f10: 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 6f 72 20 74 ommand name or t
4f20: 68 65 0a 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e he.<i class="m">
4f30: 2d 74 61 67 6e 61 6d 65 3c 2f 69 3e 20 6f 70 74 -tagname</i> opt
4f40: 69 6f 6e 2c 20 69 66 20 74 68 61 74 20 77 61 73 ion, if that was
4f50: 20 67 69 76 65 6e 2e 20 41 6e 20 61 70 70 72 6f given. An appro
4f60: 70 72 69 61 74 65 20 58 4d 4c 0a 6e 61 6d 65 73 priate XML.names
4f70: 70 61 63 65 20 64 65 63 6c 61 72 61 74 69 6f 6e pace declaration
4f80: 20 77 69 6c 6c 20 62 65 20 61 75 74 6f 6d 61 74 will be automat
4f90: 69 63 61 6c 6c 79 20 61 64 64 65 64 2c 20 74 6f ically added, to
4fa0: 20 62 69 6e 64 20 74 68 65 20 70 72 65 66 69 78 bind the prefix
4fb0: 0a 28 69 66 20 74 68 65 20 65 6c 65 6d 65 6e 74 .(if the element
4fc0: 20 6e 61 6d 65 20 68 61 73 20 6f 6e 65 29 20 6f name has one) o
4fd0: 72 20 74 68 65 20 64 65 66 61 75 6c 74 20 6e 61 r the default na
4fe0: 6d 65 73 70 61 63 65 20 28 69 66 20 74 68 65 20 mespace (if the
4ff0: 65 6c 65 6d 65 6e 74 0a 6e 61 6d 65 20 68 61 73 element.name has
5000: 6e 27 74 20 61 20 70 72 65 66 69 78 29 20 74 6f n't a prefix) to
5010: 20 74 68 65 20 6e 61 6d 65 73 70 61 63 65 20 69 the namespace i
5020: 66 20 73 75 63 68 20 61 20 62 69 6e 64 69 6e 67 f such a binding
5030: 20 69 73 6e 27 74 20 69 6e 0a 73 63 6f 70 65 2e isn't in.scope.
5040: 3c 2f 70 3e 0a 0a 3c 70 3e 54 68 65 20 73 79 6e </p>..<p>The syn
5050: 74 61 78 20 6f 66 20 74 68 65 20 63 72 65 61 74 tax of the creat
5060: 65 64 20 63 6f 6d 6d 61 6e 64 20 69 73 3a 3c 2f ed command is:</
5070: 70 3e 0a 0a 3c 70 72 65 20 63 6c 61 73 73 3d 22 p>..<pre class="
5080: 73 79 6e 74 61 78 22 3e 0a 3c 62 20 63 6c 61 73 syntax">.<b clas
5090: 73 3d 22 63 6d 64 22 3e 65 6c 65 6d 65 6e 74 4e s="cmd">elementN
50a0: 6f 64 65 43 6d 64 3c 2f 62 3e 20 3c 69 20 63 6c odeCmd</b> <i cl
50b0: 61 73 73 3d 22 6d 22 3e 3f 61 74 74 72 69 62 75 ass="m">?attribu
50c0: 74 65 4e 61 6d 65 20 61 74 74 72 69 62 75 74 65 teName attribute
50d0: 56 61 6c 75 65 20 2e 2e 2e 3f 20 3f 73 63 72 69 Value ...? ?scri
50e0: 70 74 3f 3c 2f 69 3e 0a 3c 62 20 63 6c 61 73 73 pt?</i>.<b class
50f0: 3d 22 63 6d 64 22 3e 65 6c 65 6d 65 6e 74 4e 6f ="cmd">elementNo
5100: 64 65 43 6d 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 deCmd</b> <i cla
5110: 73 73 3d 22 6d 22 3e 3f 2d 61 74 74 72 69 62 75 ss="m">?-attribu
5120: 74 65 4e 61 6d 65 20 61 74 74 72 69 62 75 74 65 teName attribute
5130: 56 61 6c 75 65 20 2e 2e 2e 3f 20 3f 73 63 72 69 Value ...? ?scri
5140: 70 74 3f 3c 2f 69 3e 0a 3c 62 20 63 6c 61 73 73 pt?</i>.<b class
5150: 3d 22 63 6d 64 22 3e 65 6c 65 6d 65 6e 74 4e 6f ="cmd">elementNo
5160: 64 65 43 6d 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 deCmd</b> <i cla
5170: 73 73 3d 22 6d 22 3e 6e 61 6d 65 5f 76 61 6c 75 ss="m">name_valu
5180: 65 5f 6c 69 73 74 20 73 63 72 69 70 74 3c 2f 69 e_list script</i
5190: 3e 0a 3c 2f 70 72 65 3e 0a 0a 3c 70 3e 54 68 65 >.</pre>..<p>The
51a0: 20 63 6f 6d 6d 61 6e 64 20 73 79 6e 74 61 78 20 command syntax
51b0: 61 6c 6c 6f 77 73 20 74 68 72 65 65 20 64 69 66 allows three dif
51c0: 66 65 72 65 6e 74 20 77 61 79 73 20 74 6f 20 73 ferent ways to s
51d0: 70 65 63 69 66 79 20 74 68 65 20 61 74 74 72 69 pecify the attri
51e0: 62 75 74 65 73 20 6f 66 0a 74 68 65 20 72 65 73 butes of.the res
51f0: 75 6c 74 69 6e 67 20 65 6c 65 6d 65 6e 74 2e 20 ulting element.
5200: 54 68 65 73 65 20 63 6f 75 6c 64 20 62 65 20 73 These could be s
5210: 70 65 63 69 66 69 65 64 20 77 69 74 68 20 3c 69 pecified with <i
5220: 20 63 6c 61 73 73 3d 22 6d 22 3e 61 74 74 72 69 class="m">attri
5230: 62 75 74 65 4e 61 6d 65 0a 61 74 74 72 69 62 75 buteName.attribu
5240: 74 65 56 61 6c 75 65 3c 2f 69 3e 20 61 72 67 75 teValue</i> argu
5250: 6d 65 6e 74 20 70 61 69 72 73 2c 20 69 6e 20 61 ment pairs, in a
5260: 6e 20 22 6f 70 74 69 6f 6e 20 73 74 79 6c 65 22 n "option style"
5270: 20 77 61 79 20 77 69 74 68 0a 3c 69 20 63 6c 61 way with.<i cla
5280: 73 73 3d 22 6d 22 3e 2d 61 74 74 72 69 75 62 74 ss="m">-attriubt
5290: 65 4e 61 6d 65 20 61 74 74 72 69 62 75 74 65 56 eName attributeV
52a0: 61 6c 75 65 3c 2f 69 3e 20 61 72 67 75 6d 65 6e alue</i> argumen
52b0: 74 20 70 61 69 72 73 20 28 74 68 65 20 27 2d 27 t pairs (the '-'
52c0: 20 63 68 61 72 61 63 74 65 72 20 69 73 20 6f 6e character is on
52d0: 6c 79 0a 73 79 6e 74 61 63 74 69 63 61 6c 20 73 ly.syntactical s
52e0: 75 67 61 72 20 61 6e 64 20 77 69 6c 6c 20 62 65 ugar and will be
52f0: 20 73 74 72 69 70 70 65 64 20 6f 66 66 29 20 6f stripped off) o
5300: 72 20 61 73 20 61 20 54 63 6c 20 6c 69 73 74 20 r as a Tcl list
5310: 77 69 74 68 20 65 6c 65 6d 65 6e 74 73 0a 69 6e with elements.in
5320: 74 65 72 70 72 65 74 65 64 20 61 73 20 61 74 74 terpreted as att
5330: 72 69 62 75 74 65 20 6e 61 6d 65 20 61 6e 64 20 ribute name and
5340: 74 68 65 20 63 6f 72 72 65 73 70 6f 6e 64 69 6e the correspondin
5350: 67 20 61 74 74 72 69 62 75 74 65 20 76 61 6c 75 g attribute valu
5360: 65 2e 0a 54 68 65 20 61 74 74 72 69 62 75 74 65 e..The attribute
5370: 20 6e 61 6d 65 20 65 6c 65 6d 65 6e 74 73 20 69 name elements i
5380: 6e 20 74 68 65 20 6c 69 73 74 20 6d 61 79 20 68 n the list may h
5390: 61 76 65 20 61 20 6c 65 61 64 69 6e 67 20 27 2d ave a leading '-
53a0: 27 20 63 68 61 72 61 63 74 65 72 2c 20 77 68 69 ' character, whi
53b0: 63 68 0a 77 69 6c 6c 20 62 65 20 73 74 72 69 70 ch.will be strip
53c0: 70 65 64 20 6f 66 66 2e 3c 2f 70 3e 0a 0a 3c 70 ped off.</p>..<p
53d0: 3e 45 76 65 72 79 20 3c 69 20 63 6c 61 73 73 3d >Every <i class=
53e0: 22 6d 22 3e 65 6c 65 6d 65 6e 74 4e 6f 64 65 43 "m">elementNodeC
53f0: 6d 64 3c 2f 69 3e 20 61 63 63 65 70 74 73 20 61 md</i> accepts a
5400: 6e 20 6f 70 74 69 6f 6e 61 6c 20 54 63 6c 20 73 n optional Tcl s
5410: 63 72 69 70 74 20 61 73 20 6c 61 73 74 0a 61 72 cript as last.ar
5420: 67 75 6d 65 6e 74 2e 20 54 68 69 73 20 73 63 72 gument. This scr
5430: 69 70 74 20 69 73 20 65 76 61 6c 75 61 74 65 64 ipt is evaluated
5440: 20 61 73 20 72 65 63 75 72 73 69 76 65 20 3c 69 as recursive <i
5450: 20 63 6c 61 73 73 3d 22 6d 22 3e 61 70 70 65 6e class="m">appen
5460: 64 46 72 6f 6d 53 63 72 69 70 74 3c 2f 69 3e 20 dFromScript</i>
5470: 73 63 72 69 70 74 0a 77 69 74 68 20 74 68 65 20 script.with the
5480: 6e 6f 64 65 20 63 72 65 61 74 65 64 20 62 79 20 node created by
5490: 74 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 the <i class="m"
54a0: 3e 65 6c 65 6d 65 6e 74 4e 6f 64 65 43 6d 64 3c >elementNodeCmd<
54b0: 2f 69 3e 20 61 73 20 70 61 72 65 6e 74 20 6f 66 /i> as parent of
54c0: 20 61 6c 6c 20 6e 6f 64 65 73 0a 63 72 65 61 74 all nodes.creat
54d0: 65 64 20 62 79 20 74 68 65 20 73 63 72 69 70 74 ed by the script
54e0: 2e 3c 2f 70 3e 0a 0a 3c 70 3e 49 66 20 74 68 65 .</p>..<p>If the
54f0: 20 66 69 72 73 74 20 61 72 67 75 6d 65 6e 74 20 first argument
5500: 6f 66 20 74 68 65 20 6d 65 74 68 6f 64 20 69 73 of the method is
5510: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 74 65 <i class="m">te
5520: 78 74 4e 6f 64 65 3c 2f 69 3e 2c 20 74 68 65 20 xtNode</i>, the
5530: 63 6f 6d 6d 61 6e 64 0a 77 69 6c 6c 20 63 72 65 command.will cre
5540: 61 74 65 20 61 20 74 65 78 74 20 6e 6f 64 65 2e ate a text node.
5550: 20 49 66 20 74 68 65 20 3c 69 20 63 6c 61 73 73 If the <i class
5560: 3d 22 6d 22 3e 2d 6a 73 6f 6e 54 79 70 65 3c 2f ="m">-jsonType</
5570: 69 3e 20 6f 70 74 69 6f 6e 20 77 61 73 20 67 69 i> option was gi
5580: 76 65 6e 20 74 68 65 6e 0a 74 68 65 20 63 72 65 ven then.the cre
5590: 61 74 65 64 20 74 65 78 74 20 6e 6f 64 65 20 77 ated text node w
55a0: 69 6c 6c 20 68 61 76 65 20 74 68 61 74 20 4a 53 ill have that JS
55b0: 4f 4e 20 74 79 70 65 2e 20 54 68 65 20 73 79 6e ON type. The syn
55c0: 74 61 78 20 6f 66 20 74 68 65 0a 63 72 65 61 74 tax of the.creat
55d0: 65 64 20 63 6f 6d 6d 61 6e 64 20 69 73 3a 3c 2f ed command is:</
55e0: 70 3e 0a 0a 3c 70 72 65 20 63 6c 61 73 73 3d 22 p>..<pre class="
55f0: 73 79 6e 74 61 78 22 3e 0a 3c 62 20 63 6c 61 73 syntax">.<b clas
5600: 73 3d 22 63 6d 64 22 3e 74 65 78 74 4e 6f 64 65 s="cmd">textNode
5610: 43 6d 64 3c 2f 62 3e 20 3f 2d 64 69 73 61 62 6c Cmd</b> ?-disabl
5620: 65 4f 75 74 70 75 74 45 73 63 61 70 69 6e 67 3f eOutputEscaping?
5630: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 61 <i class="m">da
5640: 74 61 3c 2f 69 3e 0a 3c 2f 70 72 65 3e 0a 0a 3c ta</i>.</pre>..<
5650: 70 3e 49 66 20 74 68 65 20 6f 70 74 69 6f 6e 61 p>If the optiona
5660: 6c 20 66 6c 61 67 20 3c 69 20 63 6c 61 73 73 3d l flag <i class=
5670: 22 6d 22 3e 2d 64 69 73 61 62 6c 65 4f 75 74 70 "m">-disableOutp
5680: 75 74 45 73 63 61 70 69 6e 67 3c 2f 69 3e 20 69 utEscaping</i> i
5690: 73 20 67 69 76 65 6e 2c 20 74 68 65 0a 65 73 63 s given, the.esc
56a0: 61 70 69 6e 67 20 6f 66 20 74 68 65 20 61 6d 70 aping of the amp
56b0: 65 72 73 61 6e 64 20 63 68 61 72 61 63 74 65 72 ersand character
56c0: 20 28 26 61 6d 70 3b 29 20 61 6e 64 20 74 68 65 (&) and the
56d0: 20 6c 65 66 74 20 61 6e 67 6c 65 20 62 72 61 63 left angle brac
56e0: 6b 65 74 20 28 26 6c 74 3b 29 0a 69 6e 73 69 64 ket (<).insid
56f0: 65 20 74 68 65 20 64 61 74 61 20 69 73 20 64 69 e the data is di
5700: 73 61 62 6c 65 64 2e 20 59 6f 75 20 73 68 6f 75 sabled. You shou
5710: 6c 64 20 75 73 65 20 74 68 69 73 20 66 6c 61 67 ld use this flag
5720: 20 63 61 72 65 66 75 6c 6c 79 2e 3c 2f 70 3e 0a carefully.</p>.
5730: 0a 3c 70 3e 49 66 20 74 68 65 20 66 69 72 73 74 .<p>If the first
5740: 20 61 72 67 75 6d 65 6e 74 20 6f 66 20 74 68 65 argument of the
5750: 20 6d 65 74 68 6f 64 20 69 73 20 3c 69 20 63 6c method is <i cl
5760: 61 73 73 3d 22 6d 22 3e 63 6f 6d 6d 65 6e 74 4e ass="m">commentN
5770: 6f 64 65 3c 2f 69 3e 20 6f 72 20 0a 3c 69 20 63 ode</i> or .<i c
5780: 6c 61 73 73 3d 22 6d 22 3e 63 64 61 74 61 4e 6f lass="m">cdataNo
5790: 64 65 3c 2f 69 3e 20 74 68 65 20 63 6f 6d 6d 61 de</i> the comma
57a0: 6e 64 20 77 69 6c 6c 20 63 72 65 61 74 65 20 61 nd will create a
57b0: 6e 20 63 6f 6d 6d 65 6e 74 20 6e 6f 64 65 20 6f n comment node o
57c0: 72 20 43 44 41 54 41 20 73 65 63 74 69 6f 6e 20 r CDATA section
57d0: 0a 6e 6f 64 65 2e 20 54 68 65 20 73 79 6e 74 61 .node. The synta
57e0: 78 20 6f 66 20 74 68 65 20 63 72 65 61 74 65 64 x of the created
57f0: 20 63 6f 6d 6d 61 6e 64 20 69 73 3a 3c 2f 70 3e command is:</p>
5800: 0a 0a 3c 70 72 65 20 63 6c 61 73 73 3d 22 73 79 ..<pre class="sy
5810: 6e 74 61 78 22 3e 0a 3c 62 20 63 6c 61 73 73 3d ntax">.<b class=
5820: 22 63 6d 64 22 3e 6e 6f 64 65 43 6d 64 3c 2f 62 "cmd">nodeCmd</b
5830: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 64 > <i class="m">d
5840: 61 74 61 3c 2f 69 3e 0a 3c 2f 70 72 65 3e 0a 0a ata</i>.</pre>..
5850: 3c 70 3e 49 66 20 74 68 65 20 66 69 72 73 74 20 <p>If the first
5860: 61 72 67 75 6d 65 6e 74 20 6f 66 20 74 68 65 20 argument of the
5870: 6d 65 74 68 6f 64 20 69 73 20 3c 69 20 63 6c 61 method is <i cla
5880: 73 73 3d 22 6d 22 3e 70 69 4e 6f 64 65 3c 2f 69 ss="m">piNode</i
5890: 3e 2c 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 77 >, the command w
58a0: 69 6c 6c 0a 63 72 65 61 74 65 20 61 20 70 72 6f ill.create a pro
58b0: 63 65 73 73 69 6e 67 20 69 6e 73 74 72 75 63 74 cessing instruct
58c0: 69 6f 6e 20 6e 6f 64 65 2e 20 54 68 65 20 73 79 ion node. The sy
58d0: 6e 74 61 78 20 6f 66 20 74 68 65 20 63 72 65 61 ntax of the crea
58e0: 74 65 64 0a 63 6f 6d 6d 61 6e 64 20 69 73 3a 3c ted.command is:<
58f0: 2f 70 3e 0a 0a 3c 70 72 65 20 63 6c 61 73 73 3d /p>..<pre class=
5900: 22 73 79 6e 74 61 78 22 3e 0a 3c 62 20 63 6c 61 "syntax">.<b cla
5910: 73 73 3d 22 63 6d 64 22 3e 70 69 4e 6f 64 65 43 ss="cmd">piNodeC
5920: 6d 64 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d md</b> <i class=
5930: 22 6d 22 3e 74 61 72 67 65 74 20 64 61 74 61 3c "m">target data<
5940: 2f 69 3e 0a 3c 2f 70 72 65 3e 0a 0a 3c 2f 64 64 /i>.</pre>..</dd
5950: 3e 0a 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 >. ..
5960: 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c . <
5970: 64 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d dt>.<b class="cm
5980: 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c d">dom</b> <b cl
5990: 61 73 73 3d 22 6d 65 74 68 6f 64 22 3e 73 65 74 ass="method">set
59a0: 53 74 6f 72 65 4c 69 6e 65 43 6f 6c 75 6d 6e 3c StoreLineColumn<
59b0: 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 /b> <i class="m"
59c0: 3e 3f 62 6f 6f 6c 65 61 6e 3c 2f 69 3e 3f 3c 2f >?boolean</i>?</
59d0: 64 74 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 dt>. <d
59e0: 64 3e 49 66 20 73 77 69 74 63 68 65 64 20 6f 6e d>If switched on
59f0: 2c 20 74 68 65 20 44 4f 4d 20 6e 6f 64 65 73 20 , the DOM nodes
5a00: 77 69 6c 6c 20 63 6f 6e 74 61 69 6e 20 6c 69 6e will contain lin
5a10: 65 20 61 6e 64 20 63 6f 6c 75 6d 6e 0a 70 6f 73 e and column.pos
5a20: 69 74 69 6f 6e 20 69 6e 66 6f 72 6d 61 74 69 6f ition informatio
5a30: 6e 20 66 6f 72 20 74 68 65 20 6f 72 69 67 69 6e n for the origin
5a40: 61 6c 20 58 4d 4c 20 64 6f 63 75 6d 65 6e 74 20 al XML document
5a50: 61 66 74 65 72 20 70 61 72 73 69 6e 67 2e 20 54 after parsing. T
5a60: 68 65 20 64 65 66 61 75 6c 74 0a 69 73 20 6e 6f he default.is no
5a70: 74 20 74 6f 20 73 74 6f 72 65 20 6c 69 6e 65 20 t to store line
5a80: 61 6e 64 20 63 6f 6c 75 6d 6e 20 70 6f 73 69 74 and column posit
5a90: 69 6f 6e 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2e ion information.
5aa0: 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0a 0a </dd>. ..
5ab0: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
5ac0: 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 73 73 <dt>.<b class
5ad0: 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c ="cmd">dom</b> <
5ae0: 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f 64 22 b class="method"
5af0: 3e 73 65 74 4e 61 6d 65 43 68 65 63 6b 3c 2f 62 >setNameCheck</b
5b00: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 3f > <i class="m">?
5b10: 62 6f 6f 6c 65 61 6e 3c 2f 69 3e 3f 3c 2f 64 74 boolean</i>?</dt
5b20: 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 64 3e >. <dd>
5b30: 49 66 20 4e 61 6d 65 43 68 65 63 6b 20 69 73 20 If NameCheck is
5b40: 74 72 75 65 2c 20 65 76 65 72 79 20 6d 65 74 68 true, every meth
5b50: 6f 64 20 77 68 69 63 68 20 65 78 70 65 63 74 73 od which expects
5b60: 20 61 6e 20 58 4d 4c 20 4e 61 6d 65 2c 0a 61 20 an XML Name,.a
5b70: 66 75 6c 6c 20 71 75 61 6c 69 66 69 65 64 20 6e full qualified n
5b80: 61 6d 65 20 6f 72 20 61 20 70 72 6f 63 65 73 73 ame or a process
5b90: 69 6e 67 20 69 6e 73 74 72 75 63 74 69 6e 67 20 ing instructing
5ba0: 74 61 72 67 65 74 20 77 69 6c 6c 20 63 68 65 63 target will chec
5bb0: 6b 2c 20 69 66 20 74 68 65 0a 67 69 76 65 6e 20 k, if the.given
5bc0: 73 74 72 69 6e 67 20 69 73 20 76 61 6c 69 64 20 string is valid
5bd0: 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 69 74 73 according to its
5be0: 20 70 72 6f 64 75 63 74 69 6f 6e 20 72 75 6c 65 production rule
5bf0: 2e 20 46 6f 72 20 63 6f 6d 6d 61 6e 64 73 20 63 . For commands c
5c00: 72 65 61 74 65 64 0a 77 69 74 68 20 74 68 65 20 reated.with the
5c10: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 63 72 65 <i class="m">cre
5c20: 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 69 3e 20 6d ateNodeCmd</i> m
5c30: 65 74 68 6f 64 20 74 6f 20 62 65 20 75 73 65 64 ethod to be used
5c40: 20 69 6e 20 74 68 65 20 63 6f 6e 74 65 78 74 20 in the context
5c50: 6f 66 0a 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e of.<i class="m">
5c60: 61 70 70 65 6e 64 46 72 6f 6d 53 63 72 69 70 74 appendFromScript
5c70: 3c 2f 69 3e 20 74 68 65 20 73 74 61 74 75 73 20 </i> the status
5c80: 6f 66 20 74 68 65 20 66 6c 61 67 20 61 74 20 63 of the flag at c
5c90: 72 65 61 74 69 6f 6e 20 74 69 6d 65 0a 64 65 63 reation time.dec
5ca0: 69 64 65 73 2e 20 49 66 20 4e 61 6d 65 43 68 65 ides. If NameChe
5cb0: 63 6b 20 69 73 20 74 72 75 65 20 61 74 20 63 72 ck is true at cr
5cc0: 65 61 74 69 6f 6e 20 74 69 6d 65 2c 20 74 68 65 eation time, the
5cd0: 20 63 6f 6d 6d 61 6e 64 20 77 69 6c 6c 0a 63 68 command will.ch
5ce0: 65 63 6b 20 69 74 73 20 61 72 67 75 6d 65 6e 74 eck its argument
5cf0: 73 2c 20 6f 74 68 65 72 77 69 73 65 20 6e 6f 74 s, otherwise not
5d00: 2e 20 54 68 65 20 3c 69 20 63 6c 61 73 73 3d 22 . The <i class="
5d10: 6d 22 3e 73 65 74 4e 61 6d 65 43 68 65 63 6b 3c m">setNameCheck<
5d20: 2f 69 3e 0a 73 65 74 20 74 68 69 73 20 66 6c 61 /i>.set this fla
5d30: 67 2e 20 49 74 20 72 65 74 75 72 6e 73 20 74 68 g. It returns th
5d40: 65 20 63 75 72 72 65 6e 74 20 4e 61 6d 65 43 68 e current NameCh
5d50: 65 63 6b 20 66 6c 61 67 20 73 74 61 74 65 2e 20 eck flag state.
5d60: 54 68 65 0a 64 65 66 61 75 6c 74 20 73 74 61 74 The.default stat
5d70: 65 20 66 6f 72 20 4e 61 6d 65 43 68 65 63 6b 20 e for NameCheck
5d80: 69 73 20 74 72 75 65 2e 20 3c 2f 64 64 3e 0a 20 is true. </dd>.
5d90: 20 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 20 ..
5da0: 20 0a 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e . <dt>
5db0: 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e .<b class="cmd">
5dc0: 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 73 dom</b> <b class
5dd0: 3d 22 6d 65 74 68 6f 64 22 3e 73 65 74 54 65 78 ="method">setTex
5de0: 74 43 68 65 63 6b 3c 2f 62 3e 20 3c 69 20 63 6c tCheck</b> <i cl
5df0: 61 73 73 3d 22 6d 22 3e 3f 62 6f 6f 6c 65 61 6e ass="m">?boolean
5e00: 3c 2f 69 3e 3f 3c 2f 64 74 3e 0a 20 20 20 20 20 </i>?</dt>.
5e10: 20 20 20 20 20 3c 64 64 3e 49 66 20 54 65 78 74 <dd>If Text
5e20: 43 68 65 63 6b 20 69 73 20 74 72 75 65 2c 20 65 Check is true, e
5e30: 76 65 72 79 20 63 6f 6d 6d 61 6e 64 20 77 68 69 very command whi
5e40: 63 68 20 65 78 70 65 63 74 73 20 58 4d 4c 20 43 ch expects XML C
5e50: 68 61 72 73 2c 0a 61 20 63 6f 6d 6d 65 6e 74 2c hars,.a comment,
5e60: 20 61 20 43 44 41 54 41 20 73 65 63 74 69 6f 6e a CDATA section
5e70: 20 76 61 6c 75 65 20 6f 72 20 61 20 70 72 6f 63 value or a proc
5e80: 65 73 73 69 6e 67 20 69 6e 73 74 72 75 63 74 69 essing instructi
5e90: 6e 67 20 76 61 6c 75 65 20 77 69 6c 6c 20 63 68 ng value will ch
5ea0: 65 63 6b 2c 0a 69 66 20 74 68 65 20 67 69 76 65 eck,.if the give
5eb0: 6e 20 73 74 72 69 6e 67 20 69 73 20 76 61 6c 69 n string is vali
5ec0: 64 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 69 d according to i
5ed0: 74 73 20 70 72 6f 64 75 63 74 69 6f 6e 20 72 75 ts production ru
5ee0: 6c 65 2e 20 46 6f 72 20 63 6f 6d 6d 61 6e 64 73 le. For commands
5ef0: 0a 63 72 65 61 74 65 64 20 77 69 74 68 20 74 68 .created with th
5f00: 65 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 63 e <i class="m">c
5f10: 72 65 61 74 65 4e 6f 64 65 43 6d 64 3c 2f 69 3e reateNodeCmd</i>
5f20: 20 6d 65 74 68 6f 64 20 74 6f 20 62 65 20 75 73 method to be us
5f30: 65 64 20 69 6e 20 74 68 65 0a 63 6f 6e 74 65 78 ed in the.contex
5f40: 74 20 6f 66 20 3c 69 20 63 6c 61 73 73 3d 22 6d t of <i class="m
5f50: 22 3e 61 70 70 65 6e 64 46 72 6f 6d 53 63 72 69 ">appendFromScri
5f60: 70 74 3c 2f 69 3e 20 74 68 65 20 73 74 61 74 75 pt</i> the statu
5f70: 73 20 6f 66 20 74 68 65 20 66 6c 61 67 20 61 74 s of the flag at
5f80: 0a 63 72 65 61 74 69 6f 6e 20 74 69 6d 65 20 64 .creation time d
5f90: 65 63 69 64 65 73 2e 20 49 66 20 54 65 78 74 43 ecides. If TextC
5fa0: 68 65 63 6b 20 69 73 20 74 72 75 65 20 61 74 20 heck is true at
5fb0: 63 72 65 61 74 69 6f 6e 20 74 69 6d 65 2c 20 74 creation time, t
5fc0: 68 65 0a 63 6f 6d 6d 61 6e 64 20 77 69 6c 6c 20 he.command will
5fd0: 63 68 65 63 6b 20 69 74 73 20 61 72 67 75 6d 65 check its argume
5fe0: 6e 74 73 2c 20 6f 74 68 65 72 77 69 73 65 20 6e nts, otherwise n
5ff0: 6f 74 2e 54 68 65 0a 3c 69 20 63 6c 61 73 73 3d ot.The.<i class=
6000: 22 6d 22 3e 73 65 74 54 65 78 74 43 68 65 63 6b "m">setTextCheck
6010: 3c 2f 69 3e 20 6d 65 74 68 6f 64 20 73 65 74 73 </i> method sets
6020: 20 74 68 69 73 20 66 6c 61 67 2e 20 49 74 20 72 this flag. It r
6030: 65 74 75 72 6e 73 20 74 68 65 20 63 75 72 72 65 eturns the curre
6040: 6e 74 0a 54 65 78 74 43 68 65 63 6b 20 66 6c 61 nt.TextCheck fla
6050: 67 20 73 74 61 74 65 2e 20 54 68 65 20 64 65 66 g state. The def
6060: 61 75 6c 74 20 73 74 61 74 65 20 66 6f 72 20 54 ault state for T
6070: 65 78 74 43 68 65 63 6b 20 69 73 20 74 72 75 65 extCheck is true
6080: 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 0a 0a 20 .</dd>. ..
6090: 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 20 .
60a0: 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 73 73 3d <dt>.<b class=
60b0: 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 "cmd">dom</b> <b
60c0: 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f 64 22 3e class="method">
60d0: 73 65 74 4f 62 6a 65 63 74 43 6f 6d 6d 61 6e 64 setObjectCommand
60e0: 73 3c 2f 62 3e 20 3f 3c 69 20 63 6c 61 73 73 3d s</b> ?<i class=
60f0: 22 6d 22 3e 28 61 75 74 6f 6d 61 74 69 63 7c 74 "m">(automatic|t
6100: 6f 6b 65 6e 7c 63 6f 6d 6d 61 6e 64 29 3c 2f 69 oken|command)</i
6110: 3e 3f 3c 2f 64 74 3e 0a 20 20 20 20 20 20 20 20 >?</dt>.
6120: 20 20 3c 64 64 3e 43 6f 6e 74 72 6f 6c 73 20 69 <dd>Controls i
6130: 66 20 64 6f 63 75 6d 65 6e 74 73 20 61 6e 64 20 f documents and
6140: 6e 6f 64 65 73 20 61 72 65 20 63 72 65 61 74 65 nodes are create
6150: 64 20 61 73 20 74 63 6c 20 63 6f 6d 6d 61 6e 64 d as tcl command
6160: 73 20 6f 72 0a 61 73 20 74 6f 6b 65 6e 20 74 6f s or.as token to
6170: 20 62 65 0a 75 73 65 64 20 77 69 74 68 20 74 68 be.used with th
6180: 65 20 64 6f 6d 4e 6f 64 65 20 61 6e 64 20 64 6f e domNode and do
6190: 6d 44 6f 63 20 63 6f 6d 6d 61 6e 64 73 2e 20 49 mDoc commands. I
61a0: 66 20 74 68 65 20 6d 6f 64 65 20 69 73 0a 27 61 f the mode is.'a
61b0: 75 74 6f 6d 61 74 69 63 27 2c 20 74 68 65 6e 20 utomatic', then
61c0: 6d 65 74 68 6f 64 73 20 75 73 65 64 20 61 74 20 methods used at
61d0: 74 63 6c 20 63 6f 6d 6d 61 6e 64 73 20 77 69 6c tcl commands wil
61e0: 6c 20 63 72 65 61 74 65 20 74 63 6c 0a 63 6f 6d l create tcl.com
61f0: 6d 61 6e 64 73 20 61 6e 64 20 6d 65 74 68 6f 64 mands and method
6200: 73 20 75 73 65 64 20 61 74 20 64 6f 63 20 6f 72 s used at doc or
6210: 20 6e 6f 64 65 20 74 6f 6b 65 73 20 77 69 6c 6c node tokes will
6220: 20 63 72 65 61 74 65 20 74 6f 6b 65 6e 73 2e 20 create tokens.
6230: 49 66 0a 74 68 65 20 6d 6f 64 65 20 69 73 20 27 If.the mode is '
6240: 63 6f 6d 6d 61 6e 64 27 20 74 68 65 6e 20 61 6c command' then al
6250: 77 61 79 73 20 74 63 6c 20 63 6f 6d 6d 61 6e 64 ways tcl command
6260: 73 20 77 69 6c 6c 20 62 65 20 63 72 65 61 74 65 s will be create
6270: 64 2e 20 49 66 0a 74 68 65 20 6d 6f 64 65 20 69 d. If.the mode i
6280: 73 20 27 74 6f 6b 65 6e 27 2c 20 74 68 65 6e 20 s 'token', then
6290: 61 6c 77 61 79 73 20 74 6f 6b 65 6e 20 77 69 6c always token wil
62a0: 6c 20 62 65 20 63 72 65 61 74 65 64 2e 20 54 68 l be created. Th
62b0: 65 20 6d 65 74 68 6f 64 0a 72 65 74 75 72 6e 73 e method.returns
62c0: 20 74 68 65 20 63 75 72 72 65 6e 74 20 6d 6f 64 the current mod
62d0: 65 2e 20 54 68 69 73 20 6d 65 74 68 6f 64 20 69 e. This method i
62e0: 73 20 61 6e 20 65 78 70 65 72 69 6d 65 6e 74 61 s an experimenta
62f0: 6c 20 69 6e 74 65 72 66 61 63 65 2e 3c 2f 64 64 l interface.</dd
6300: 3e 0a 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 >. ..
6310: 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c 64 74 . <dt
6320: 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 >.<b class="cmd"
6330: 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 >dom</b> <b clas
6340: 73 3d 22 6d 65 74 68 6f 64 22 3e 69 73 4e 61 6d s="method">isNam
6350: 65 3c 2f 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 e</b> <i class="
6360: 6d 22 3e 6e 61 6d 65 3c 2f 69 3e 0a 3c 2f 64 74 m">name</i>.</dt
6370: 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 64 3e >. <dd>
6380: 52 65 74 75 72 6e 73 20 31 20 69 66 20 3c 69 20 Returns 1 if <i
6390: 63 6c 61 73 73 3d 22 6d 22 3e 6e 61 6d 65 3c 2f class="m">name</
63a0: 69 3e 20 69 73 20 61 20 76 61 6c 69 64 20 58 4d i> is a valid XM
63b0: 4c 20 4e 61 6d 65 20 61 63 63 6f 72 64 69 6e 67 L Name according
63c0: 20 74 6f 0a 70 72 6f 64 75 63 74 69 6f 6e 20 35 to.production 5
63d0: 20 6f 66 20 74 68 65 20 3c 61 20 68 72 65 66 3d of the <a href=
63e0: 22 68 74 74 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f "http://www.w3.o
63f0: 72 67 2f 54 52 2f 32 30 30 34 2f 52 45 43 2d 78 rg/TR/2004/REC-x
6400: 6d 6c 2d 32 30 30 34 30 32 30 34 2f 23 4e 54 2d ml-20040204/#NT-
6410: 4e 61 6d 65 43 68 61 72 22 3e 58 4d 4c 0a 20 20 NameChar">XML.
6420: 20 20 20 20 20 20 20 20 20 20 31 2e 30 3c 2f 61 1.0</a
6430: 3e 20 72 65 63 6f 6d 6d 65 6e 64 61 74 69 6f 6e > recommendation
6440: 2e 20 54 68 69 73 20 6d 65 61 6e 73 20 74 68 61 . This means tha
6450: 74 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 6e t <i class="m">n
6460: 61 6d 65 3c 2f 69 3e 20 69 73 20 61 20 76 61 6c ame</i> is a val
6470: 69 64 0a 20 20 20 20 20 20 20 20 20 20 58 4d 4c id. XML
6480: 20 65 6c 65 6d 65 6e 74 20 6f 72 20 61 74 74 72 element or attr
6490: 69 62 75 74 65 20 6e 61 6d 65 2e 20 4f 74 68 65 ibute name. Othe
64a0: 72 77 69 73 65 20 69 74 20 72 65 74 75 72 6e 73 rwise it returns
64b0: 20 30 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 0.</dd>.
64c0: 20 0a 0a 20 20 20 20 20 20 20 20 0a 20 20 20 20 .. .
64d0: 20 20 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c <dt>.<b cl
64e0: 61 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 ass="cmd">dom</b
64f0: 3e 20 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 > <b class="meth
6500: 6f 64 22 3e 69 73 50 49 4e 61 6d 65 3c 2f 62 3e od">isPIName</b>
6510: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 6e 61 <i class="m">na
6520: 6d 65 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 me</i>.</dt>.
6530: 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 <dd>Retur
6540: 6e 73 20 31 20 69 66 20 3c 69 20 63 6c 61 73 73 ns 1 if <i class
6550: 3d 22 6d 22 3e 6e 61 6d 65 3c 2f 69 3e 20 69 73 ="m">name</i> is
6560: 20 61 20 76 61 6c 69 64 20 58 4d 4c 20 70 72 6f a valid XML pro
6570: 63 65 73 73 69 6e 67 20 69 6e 73 74 72 75 63 74 cessing instruct
6580: 69 6f 6e 0a 20 20 20 20 20 20 20 20 20 20 74 61 ion. ta
6590: 72 67 65 74 20 61 63 63 6f 72 64 69 6e 67 20 74 rget according t
65a0: 6f 0a 70 72 6f 64 75 63 74 69 6f 6e 20 31 37 20 o.production 17
65b0: 6f 66 20 74 68 65 20 3c 61 20 68 72 65 66 3d 22 of the <a href="
65c0: 68 74 74 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 http://www.w3.or
65d0: 67 2f 54 52 2f 32 30 30 30 2f 52 45 43 2d 78 6d g/TR/2000/REC-xm
65e0: 6c 2d 32 30 30 30 31 30 30 36 2e 68 74 6d 6c 22 l-20001006.html"
65f0: 3e 58 4d 4c 20 31 2e 30 3c 2f 61 3e 20 72 65 63 >XML 1.0</a> rec
6600: 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 ommendation. Oth
6610: 65 72 77 69 73 65 20 69 74 20 72 65 74 75 72 6e erwise it return
6620: 73 20 30 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 s 0.</dd>.
6630: 20 20 0a 0a 20 20 20 20 20 20 20 20 0a 20 20 20 .. .
6640: 20 20 20 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 <dt>.<b c
6650: 6c 61 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f lass="cmd">dom</
6660: 62 3e 20 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 b> <b class="met
6670: 68 6f 64 22 3e 69 73 4e 43 4e 61 6d 65 3c 2f 62 hod">isNCName</b
6680: 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 6e > <i class="m">n
6690: 61 6d 65 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 ame</i>.</dt>.
66a0: 20 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 <dd>Retu
66b0: 72 6e 73 20 31 20 69 66 20 3c 69 20 63 6c 61 73 rns 1 if <i clas
66c0: 73 3d 22 6d 22 3e 6e 61 6d 65 3c 2f 69 3e 20 69 s="m">name</i> i
66d0: 73 20 61 20 76 61 6c 69 64 20 4e 43 4e 61 6d 65 s a valid NCName
66e0: 20 61 63 63 6f 72 64 69 6e 67 0a 74 6f 20 70 72 according.to pr
66f0: 6f 64 75 63 74 69 6f 6e 20 34 20 6f 66 20 74 68 oduction 4 of th
6700: 65 20 6f 66 20 74 68 65 20 3c 61 20 68 72 65 66 e of the <a href
6710: 3d 22 68 74 74 70 3a 2f 2f 77 77 77 2e 77 33 2e ="http://www.w3.
6720: 6f 72 67 2f 54 52 2f 31 39 39 39 2f 52 45 43 2d org/TR/1999/REC-
6730: 78 6d 6c 2d 6e 61 6d 65 73 2d 31 39 39 39 30 31 xml-names-199901
6740: 31 34 22 3e 4e 61 6d 65 73 70 61 63 65 73 20 69 14">Namespaces i
6750: 6e 20 58 4d 4c 3c 2f 61 3e 20 72 65 63 6f 6d 6d n XML</a> recomm
6760: 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77 endation. Otherw
6770: 69 73 65 20 69 74 20 72 65 74 75 72 6e 73 0a 30 ise it returns.0
6780: 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0a .</dd>. .
6790: 0a 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 . .
67a0: 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 73 <dt>.<b clas
67b0: 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e 20 s="cmd">dom</b>
67c0: 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f 64 <b class="method
67d0: 22 3e 69 73 51 4e 61 6d 65 3c 2f 62 3e 20 3c 69 ">isQName</b> <i
67e0: 20 63 6c 61 73 73 3d 22 6d 22 3e 6e 61 6d 65 3c class="m">name<
67f0: 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 20 20 20 /i>.</dt>.
6800: 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 20 <dd>Returns
6810: 31 20 69 66 20 3c 69 20 63 6c 61 73 73 3d 22 6d 1 if <i class="m
6820: 22 3e 6e 61 6d 65 3c 2f 69 3e 20 69 73 20 61 20 ">name</i> is a
6830: 76 61 6c 69 64 20 51 4e 61 6d 65 20 61 63 63 6f valid QName acco
6840: 72 64 69 6e 67 0a 74 6f 20 70 72 6f 64 75 63 74 rding.to product
6850: 69 6f 6e 20 36 20 6f 66 20 74 68 65 20 6f 66 20 ion 6 of the of
6860: 74 68 65 20 3c 61 20 68 72 65 66 3d 22 68 74 74 the <a href="htt
6870: 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f 54 p://www.w3.org/T
6880: 52 2f 31 39 39 39 2f 52 45 43 2d 78 6d 6c 2d 6e R/1999/REC-xml-n
6890: 61 6d 65 73 2d 31 39 39 39 30 31 31 34 22 3e 4e ames-19990114">N
68a0: 61 6d 65 73 70 61 63 65 73 20 69 6e 20 58 4d 4c amespaces in XML
68b0: 3c 2f 61 3e 20 72 65 63 6f 6d 6d 65 6e 64 61 74 </a> recommendat
68c0: 69 6f 6e 2e 20 4f 74 68 65 72 77 69 73 65 20 69 ion. Otherwise i
68d0: 74 20 72 65 74 75 72 6e 73 0a 30 2e 3c 2f 64 64 t returns.0.</dd
68e0: 3e 0a 20 20 20 20 20 20 20 20 0a 0a 20 20 20 20 >. ..
68f0: 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 3c . <
6900: 64 74 3e 0a 3c 62 20 63 6c 61 73 73 3d 22 63 6d dt>.<b class="cm
6910: 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c d">dom</b> <b cl
6920: 61 73 73 3d 22 6d 65 74 68 6f 64 22 3e 69 73 43 ass="method">isC
6930: 68 61 72 44 61 74 61 3c 2f 62 3e 0a 3c 69 20 63 harData</b>.<i c
6940: 6c 61 73 73 3d 22 6d 22 3e 73 74 72 69 6e 67 3c lass="m">string<
6950: 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 20 20 20 /i>.</dt>.
6960: 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 20 <dd>Returns
6970: 31 20 69 66 20 65 76 65 72 79 20 63 68 61 72 61 1 if every chara
6980: 63 74 65 72 20 69 6e 20 3c 69 20 63 6c 61 73 73 cter in <i class
6990: 3d 22 6d 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 20 ="m">string</i>
69a0: 69 73 0a 61 20 76 61 6c 69 64 20 58 4d 4c 20 43 is.a valid XML C
69b0: 68 61 72 20 61 63 63 6f 72 64 69 6e 67 20 74 6f har according to
69c0: 20 70 72 6f 64 75 63 74 69 6f 6e 20 32 20 6f 66 production 2 of
69d0: 20 74 68 65 20 3c 61 20 68 72 65 66 3d 22 68 74 the <a href="ht
69e0: 74 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f tp://www.w3.org/
69f0: 54 52 2f 32 30 30 30 2f 52 45 43 2d 78 6d 6c 2d TR/2000/REC-xml-
6a00: 32 30 30 30 31 30 30 36 2e 68 74 6d 6c 22 3e 58 20001006.html">X
6a10: 4d 4c 20 31 2e 30 3c 2f 61 3e 0a 72 65 63 6f 6d ML 1.0</a>.recom
6a20: 6d 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 mendation. Other
6a30: 77 69 73 65 20 69 74 20 72 65 74 75 72 6e 73 20 wise it returns
6a40: 30 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0.</dd>.
6a50: 0a 0a 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .. .
6a60: 20 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 <dt>.<b cla
6a70: 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e ss="cmd">dom</b>
6a80: 20 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f <b class="metho
6a90: 64 22 3e 69 73 42 4d 50 43 68 61 72 44 61 74 61 d">isBMPCharData
6aa0: 3c 2f 62 3e 0a 3c 69 20 63 6c 61 73 73 3d 22 6d </b>.<i class="m
6ab0: 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 0a 3c 2f 64 ">string</i>.</d
6ac0: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 3c 64 64 t>. <dd
6ad0: 3e 52 65 74 75 72 6e 73 20 31 20 69 66 20 65 76 >Returns 1 if ev
6ae0: 65 72 79 20 63 68 61 72 61 63 74 65 72 20 69 6e ery character in
6af0: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 73 74 <i class="m">st
6b00: 72 69 6e 67 3c 2f 69 3e 20 69 73 0a 61 20 76 61 ring</i> is.a va
6b10: 6c 69 64 20 58 4d 4c 20 43 68 61 72 20 77 69 74 lid XML Char wit
6b20: 68 20 61 20 55 6e 69 63 6f 64 65 20 63 6f 64 65 h a Unicode code
6b30: 20 70 6f 69 6e 74 20 77 69 74 68 69 6e 20 74 68 point within th
6b40: 65 20 42 61 73 69 63 0a 4d 75 6c 74 69 6c 69 6e e Basic.Multilin
6b50: 67 75 61 6c 20 50 6c 61 6e 65 20 28 74 68 61 74 gual Plane (that
6b60: 20 6d 65 61 6e 73 2c 20 74 68 61 74 20 65 76 65 means, that eve
6b70: 72 79 20 63 68 61 72 61 63 74 65 72 20 77 69 74 ry character wit
6b80: 68 69 6e 20 74 68 65 20 73 74 72 69 6e 67 0a 69 hin the string.i
6b90: 73 20 61 74 20 6d 6f 73 74 20 33 20 62 79 74 65 s at most 3 byte
6ba0: 73 20 6c 6f 6e 67 29 2e 20 4f 74 68 65 72 77 69 s long). Otherwi
6bb0: 73 65 20 69 74 20 72 65 74 75 72 6e 73 20 30 2e se it returns 0.
6bc0: 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0a 0a </dd>. ..
6bd0: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
6be0: 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 73 73 <dt>.<b class
6bf0: 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e 20 3c ="cmd">dom</b> <
6c00: 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f 64 22 b class="method"
6c10: 3e 69 73 43 6f 6d 6d 65 6e 74 3c 2f 62 3e 0a 3c >isComment</b>.<
6c20: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 73 74 72 69 i class="m">stri
6c30: 6e 67 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 ng</i>.</dt>.
6c40: 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 <dd>Retur
6c50: 6e 73 20 31 20 69 66 20 3c 69 20 63 6c 61 73 73 ns 1 if <i class
6c60: 3d 22 6d 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 20 ="m">string</i>
6c70: 69 73 0a 61 20 76 61 6c 69 64 20 63 6f 6d 6d 65 is.a valid comme
6c80: 6e 74 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 nt according to
6c90: 70 72 6f 64 75 63 74 69 6f 6e 20 31 35 20 6f 66 production 15 of
6ca0: 20 74 68 65 20 3c 61 20 68 72 65 66 3d 22 68 74 the <a href="ht
6cb0: 74 70 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f tp://www.w3.org/
6cc0: 54 52 2f 32 30 30 30 2f 52 45 43 2d 78 6d 6c 2d TR/2000/REC-xml-
6cd0: 32 30 30 30 31 30 30 36 2e 68 74 6d 6c 22 3e 58 20001006.html">X
6ce0: 4d 4c 20 31 2e 30 3c 2f 61 3e 0a 72 65 63 6f 6d ML 1.0</a>.recom
6cf0: 6d 65 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 mendation. Other
6d00: 77 69 73 65 20 69 74 20 72 65 74 75 72 6e 73 20 wise it returns
6d10: 30 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0.</dd>.
6d20: 0a 0a 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .. .
6d30: 20 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 <dt>.<b cla
6d40: 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e ss="cmd">dom</b>
6d50: 20 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f <b class="metho
6d60: 64 22 3e 69 73 43 44 41 54 41 3c 2f 62 3e 0a 3c d">isCDATA</b>.<
6d70: 69 20 63 6c 61 73 73 3d 22 6d 22 3e 73 74 72 69 i class="m">stri
6d80: 6e 67 3c 2f 69 3e 0a 3c 2f 64 74 3e 0a 20 20 20 ng</i>.</dt>.
6d90: 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 <dd>Retur
6da0: 6e 73 20 31 20 69 66 20 3c 69 20 63 6c 61 73 73 ns 1 if <i class
6db0: 3d 22 6d 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 20 ="m">string</i>
6dc0: 69 73 0a 76 61 6c 69 64 20 61 63 63 6f 72 64 69 is.valid accordi
6dd0: 6e 67 20 74 6f 20 70 72 6f 64 75 63 74 69 6f 6e ng to production
6de0: 20 32 30 20 6f 66 20 74 68 65 20 3c 61 20 68 72 20 of the <a hr
6df0: 65 66 3d 22 68 74 74 70 3a 2f 2f 77 77 77 2e 77 ef="http://www.w
6e00: 33 2e 6f 72 67 2f 54 52 2f 32 30 30 30 2f 52 45 3.org/TR/2000/RE
6e10: 43 2d 78 6d 6c 2d 32 30 30 30 31 30 30 36 2e 68 C-xml-20001006.h
6e20: 74 6d 6c 22 3e 58 4d 4c 20 31 2e 30 3c 2f 61 3e tml">XML 1.0</a>
6e30: 0a 72 65 63 6f 6d 6d 65 6e 64 61 74 69 6f 6e 2e .recommendation.
6e40: 20 4f 74 68 65 72 77 69 73 65 20 69 74 20 72 65 Otherwise it re
6e50: 74 75 72 6e 73 20 30 2e 3c 2f 64 64 3e 0a 20 20 turns 0.</dd>.
6e60: 20 20 20 20 20 20 0a 0a 20 20 20 20 20 20 20 20 ..
6e70: 0a 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 0a . <dt>.
6e80: 3c 62 20 63 6c 61 73 73 3d 22 63 6d 64 22 3e 64 <b class="cmd">d
6e90: 6f 6d 3c 2f 62 3e 20 3c 62 20 63 6c 61 73 73 3d om</b> <b class=
6ea0: 22 6d 65 74 68 6f 64 22 3e 69 73 50 49 56 61 6c "method">isPIVal
6eb0: 75 65 3c 2f 62 3e 0a 3c 69 20 63 6c 61 73 73 3d ue</b>.<i class=
6ec0: 22 6d 22 3e 73 74 72 69 6e 67 3c 2f 69 3e 0a 3c "m">string</i>.<
6ed0: 2f 64 74 3e 0a 20 20 20 20 20 20 20 20 20 20 3c /dt>. <
6ee0: 64 64 3e 52 65 74 75 72 6e 73 20 31 20 69 66 20 dd>Returns 1 if
6ef0: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 73 74 72 <i class="m">str
6f00: 69 6e 67 3c 2f 69 3e 20 69 73 0a 76 61 6c 69 64 ing</i> is.valid
6f10: 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 70 72 according to pr
6f20: 6f 64 75 63 74 69 6f 6e 20 31 36 20 6f 66 20 74 oduction 16 of t
6f30: 68 65 20 3c 61 20 68 72 65 66 3d 22 68 74 74 70 he <a href="http
6f40: 3a 2f 2f 77 77 77 2e 77 33 2e 6f 72 67 2f 54 52 ://www.w3.org/TR
6f50: 2f 32 30 30 30 2f 52 45 43 2d 78 6d 6c 2d 32 30 /2000/REC-xml-20
6f60: 30 30 31 30 30 36 2e 68 74 6d 6c 22 3e 58 4d 4c 001006.html">XML
6f70: 20 31 2e 30 3c 2f 61 3e 0a 72 65 63 6f 6d 6d 65 1.0</a>.recomme
6f80: 6e 64 61 74 69 6f 6e 2e 20 4f 74 68 65 72 77 69 ndation. Otherwi
6f90: 73 65 20 69 74 20 72 65 74 75 72 6e 73 20 30 2e se it returns 0.
6fa0: 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 0a 0a </dd>. ..
6fb0: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
6fc0: 20 20 20 20 20 3c 64 74 3e 0a 3c 62 20 63 6c 61 <dt>.<b cla
6fd0: 73 73 3d 22 63 6d 64 22 3e 64 6f 6d 3c 2f 62 3e ss="cmd">dom</b>
6fe0: 20 3c 62 20 63 6c 61 73 73 3d 22 6d 65 74 68 6f <b class="metho
6ff0: 64 22 3e 66 65 61 74 75 72 65 69 6e 66 6f 3c 2f d">featureinfo</
7000: 62 3e 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e b> <i class="m">
7010: 66 65 61 74 75 72 65 3c 2f 69 3e 0a 3c 2f 64 74 feature</i>.</dt
7020: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 >. <d
7030: 64 3e 54 68 69 73 20 6d 65 74 68 6f 64 20 70 72 d>This method pr
7040: 6f 76 69 64 65 73 20 69 6e 66 6f 72 6d 61 74 69 ovides informati
7050: 6f 6e 20 61 62 6f 75 74 20 74 68 65 20 75 73 65 on about the use
7060: 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 62 75 d. bu
7070: 69 6c 64 20 6f 70 74 69 6f 6e 73 20 61 6e 64 20 ild options and
7080: 74 68 65 20 65 78 70 61 74 20 76 65 72 73 69 6f the expat versio
7090: 6e 2e 20 54 68 65 20 76 61 6c 69 64 20 76 61 6c n. The valid val
70a0: 75 65 73 20 66 6f 72 0a 20 20 20 20 20 20 20 20 ues for.
70b0: 20 20 20 20 74 68 65 20 3c 69 20 63 6c 61 73 73 the <i class
70c0: 3d 22 6d 22 3e 66 65 61 74 75 72 65 3c 2f 69 3e ="m">feature</i>
70d0: 20 61 72 67 75 6d 65 6e 74 20 61 72 65 3a 0a 20 argument are:.
70e0: 20 20 20 20 20 20 20 20 20 20 20 3c 64 6c 20 63 <dl c
70f0: 6c 61 73 73 3d 22 6f 70 74 6c 69 73 74 22 3e 0a lass="optlist">.
7100: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
7110: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
7120: 20 20 20 20 20 3c 64 74 3e 3c 62 3e 65 78 70 61 <dt><b>expa
7130: 74 76 65 72 73 69 6f 6e 3c 2f 62 3e 3c 2f 64 74 tversion</b></dt
7140: 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 >.
7150: 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e <dd>Return
7160: 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 6f 66 s the version of
7170: 20 74 68 65 20 75 6e 64 65 72 6c 79 6c 69 6e 67 the underlyling
7180: 20 65 78 70 61 74 0a 20 20 20 20 20 20 20 20 20 expat.
7190: 20 20 20 20 20 20 20 20 20 20 20 76 65 72 73 69 versi
71a0: 6f 6e 20 61 73 20 73 74 72 69 6e 67 2c 20 73 6f on as string, so
71b0: 6d 65 74 68 69 6e 67 20 6c 69 6b 65 0a 20 20 20 mething like.
71c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
71d0: 20 22 65 78 61 70 74 5f 32 2e 31 2e 30 22 2e 20 "exapt_2.1.0".
71e0: 54 68 69 73 20 69 73 20 77 68 61 74 20 74 68 65 This is what the
71f0: 20 65 78 70 61 74 20 41 50 49 0a 20 20 20 20 20 expat API.
7200: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 f
7210: 75 6e 63 74 69 6f 6e 20 58 4d 4c 5f 45 78 70 61 unction XML_Expa
7220: 74 56 65 72 73 69 6f 6e 28 29 20 72 65 74 75 72 tVersion() retur
7230: 6e 73 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 ns.</dd>.
7240: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
7250: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
7260: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7270: 64 74 3e 3c 62 3e 65 78 70 61 74 6d 61 6a 6f 72 dt><b>expatmajor
7280: 76 65 72 73 69 6f 6e 3c 2f 62 3e 3c 2f 64 74 3e version</b></dt>
7290: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
72a0: 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 <dd>Returns
72b0: 20 74 68 65 20 6d 61 6a 6f 72 20 76 65 72 73 69 the major versi
72c0: 6f 6e 20 6f 66 20 74 68 65 20 75 6e 64 65 72 6c on of the underl
72d0: 79 6c 69 6e 67 0a 20 20 20 20 20 20 20 20 20 20 yling.
72e0: 20 20 20 20 20 20 20 20 20 20 65 78 70 61 74 20 expat
72f0: 76 65 72 73 69 6f 6e 20 61 73 20 69 6e 74 65 67 version as integ
7300: 65 72 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 er.</dd>.
7310: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
7320: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
7330: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7340: 64 74 3e 3c 62 3e 65 78 70 61 74 6d 69 6e 6f 72 dt><b>expatminor
7350: 76 65 72 73 69 6f 6e 3c 2f 62 3e 3c 2f 64 74 3e version</b></dt>
7360: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
7370: 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 <dd>Returns
7380: 20 74 68 65 20 6d 69 6e 6f 72 20 76 65 72 73 69 the minor versi
7390: 6f 6e 20 6f 66 20 74 68 65 20 75 6e 64 65 72 6c on of the underl
73a0: 79 6c 69 6e 67 0a 20 20 20 20 20 20 20 20 20 20 yling.
73b0: 20 20 20 20 20 20 20 20 20 20 65 78 70 61 74 20 expat
73c0: 76 65 72 73 69 6f 6e 20 61 73 20 69 6e 74 65 67 version as integ
73d0: 65 72 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 er.</dd>.
73e0: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
73f0: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
7400: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7410: 64 74 3e 3c 62 3e 65 78 70 61 74 6d 69 63 72 6f dt><b>expatmicro
7420: 76 65 72 73 69 6f 6e 3c 2f 62 3e 3c 2f 64 74 3e version</b></dt>
7430: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
7440: 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 <dd>Returns
7450: 20 74 68 65 20 6d 69 63 72 6f 20 76 65 72 73 69 the micro versi
7460: 6f 6e 20 6f 66 20 74 68 65 20 75 6e 64 65 72 6c on of the underl
7470: 79 6c 69 6e 67 0a 20 20 20 20 20 20 20 20 20 20 yling.
7480: 20 20 20 20 20 20 20 20 20 20 65 78 70 61 74 20 expat
7490: 76 65 72 73 69 6f 6e 20 61 73 20 69 6e 74 65 67 version as integ
74a0: 65 72 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 er.</dd>.
74b0: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
74c0: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
74d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
74e0: 64 74 3e 3c 62 3e 64 74 64 3c 2f 62 3e 3c 2f 64 dt><b>dtd</b></d
74f0: 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 t>.
7500: 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 72 <dd>Retur
7510: 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 20 69 66 ns as boolean if
7520: 20 62 75 69 6c 64 20 77 69 74 68 0a 20 20 20 20 build with.
7530: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
7540: 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 2d 65 <i class="m">--e
7550: 6e 61 62 6c 65 2d 64 74 64 3c 2f 69 3e 2e 3c 2f nable-dtd</i>.</
7560: 64 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 dd>.
7570: 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 .
7580: 20 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 .
7590: 20 20 20 20 20 20 20 20 20 20 3c 64 74 3e 3c 62 <dt><b
75a0: 3e 6e 73 3c 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 >ns</b></dt>.
75b0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
75c0: 20 3c 64 64 3e 52 65 74 75 72 6e 73 20 61 73 20 <dd>Returns as
75d0: 62 6f 6f 6c 65 61 6e 20 69 66 20 62 75 69 6c 64 boolean if build
75e0: 20 77 69 74 68 0a 20 20 20 20 20 20 20 20 20 20 with.
75f0: 20 20 20 20 20 20 20 20 20 20 3c 69 20 63 6c 61 <i cla
7600: 73 73 3d 22 6d 22 3e 2d 2d 65 6e 61 62 6c 65 2d ss="m">--enable-
7610: 6e 73 3c 2f 69 3e 2e 3c 2f 64 64 3e 0a 20 20 20 ns</i>.</dd>.
7620: 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 20 .
7630: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a 20 .
7640: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
7650: 20 20 20 3c 64 74 3e 3c 62 3e 75 6e 6b 6e 6f 77 <dt><b>unknow
7660: 6e 3c 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 n</b></dt>.
7670: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7680: 64 64 3e 52 65 74 75 72 6e 73 20 61 73 20 62 6f dd>Returns as bo
7690: 6f 6c 65 61 6e 20 69 66 20 62 75 69 6c 64 20 77 olean if build w
76a0: 69 74 68 0a 20 20 20 20 20 20 20 20 20 20 20 20 ith.
76b0: 20 20 20 20 20 20 20 20 3c 69 20 63 6c 61 73 73 <i class
76c0: 3d 22 6d 22 3e 2d 2d 65 6e 61 62 6c 65 2d 75 6e ="m">--enable-un
76d0: 6b 6e 6f 77 6e 3c 2f 69 3e 2e 3c 2f 64 64 3e 0a known</i>.</dd>.
76e0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
76f0: 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
7700: 20 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .
7710: 20 20 20 20 20 20 3c 64 74 3e 3c 62 3e 74 64 6f <dt><b>tdo
7720: 6d 61 6c 6c 6f 63 3c 2f 62 3e 3c 2f 64 74 3e 0a malloc</b></dt>.
7730: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
7740: 20 20 20 20 3c 64 64 3e 52 65 74 75 72 6e 73 20 <dd>Returns
7750: 61 73 20 62 6f 6f 6c 65 61 6e 20 69 66 20 62 75 as boolean if bu
7760: 69 6c 64 20 77 69 74 68 0a 20 20 20 20 20 20 20 ild with.
7770: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 69 20 <i
7780: 63 6c 61 73 73 3d 22 6d 22 3e 2d 2d 65 6e 61 62 class="m">--enab
7790: 6c 65 2d 74 64 6f 6d 61 6c 6c 6f 63 3c 2f 69 3e le-tdomalloc</i>
77a0: 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 20 .</dd>.
77b0: 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 20 .
77c0: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
77d0: 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 74 <dt
77e0: 3e 3c 62 3e 6c 65 73 73 6e 73 3c 2f 62 3e 3c 2f ><b>lessns</b></
77f0: 64 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 dt>.
7800: 20 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 75 <dd>Retu
7810: 72 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 20 69 rns as boolean i
7820: 66 20 62 75 69 6c 64 20 77 69 74 68 0a 20 20 20 f build with.
7830: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
7840: 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e 2d 2d <i class="m">--
7850: 65 6e 61 62 6c 65 2d 6c 65 73 73 6e 73 3c 2f 69 enable-lessns</i
7860: 3e 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 20 >.</dd>.
7870: 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 20 .
7880: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
7890: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
78a0: 74 3e 3c 62 3e 54 43 4c 5f 55 54 46 5f 4d 41 58 t><b>TCL_UTF_MAX
78b0: 3c 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 20 </b></dt>.
78c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 <d
78d0: 64 3e 52 65 74 75 72 6e 73 20 74 68 65 20 54 43 d>Returns the TC
78e0: 4c 5f 55 54 46 5f 4d 41 58 20 76 61 6c 75 65 20 L_UTF_MAX value
78f0: 6f 66 20 74 68 65 20 74 63 6c 0a 20 20 20 20 20 of the tcl.
7900: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 c
7910: 6f 72 65 2c 20 74 44 4f 4d 20 77 61 73 20 62 75 ore, tDOM was bu
7920: 69 6c 64 20 77 69 74 68 20 61 73 20 69 6e 74 65 ild with as inte
7930: 67 65 72 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 ger</dd>.
7940: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
7950: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
7960: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7970: 64 74 3e 3c 62 3e 68 74 6d 6c 35 3c 2f 62 3e 3c dt><b>html5</b><
7980: 2f 64 74 3e 0a 20 20 20 20 20 20 20 20 20 20 20 /dt>.
7990: 20 20 20 20 20 20 20 20 20 3c 64 64 3e 52 65 74 <dd>Ret
79a0: 75 72 6e 73 20 61 73 20 62 6f 6f 6c 65 61 6e 2c urns as boolean,
79b0: 20 69 66 20 62 75 69 6c 64 20 77 69 74 68 0a 20 if build with.
79c0: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20
79d0: 20 20 20 3c 69 20 63 6c 61 73 73 3d 22 6d 22 3e <i class="m">
79e0: 2d 2d 65 6e 61 62 6c 65 2d 68 74 6d 6c 35 3c 2f --enable-html5</
79f0: 69 3e 2e 3c 2f 64 64 3e 0a 20 20 20 20 20 20 20 i>.</dd>.
7a00: 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 20 .
7a10: 20 20 20 20 20 20 20 20 20 20 0a 20 20 20 20 20 .
7a20: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7a30: 64 74 3e 3c 62 3e 76 65 72 73 69 6f 6e 68 61 73 dt><b>versionhas
7a40: 68 3c 2f 62 3e 3c 2f 64 74 3e 0a 20 20 20 20 20 h</b></dt>.
7a50: 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c <
7a60: 64 64 3e 52 65 74 75 72 6e 73 20 74 68 65 20 66 dd>Returns the f
7a70: 6f 73 73 69 6c 20 72 65 70 6f 73 69 74 6f 72 79 ossil repository
7a80: 20 76 65 72 73 69 6f 6e 20 68 61 73 68 2e 3c 2f version hash.</
7a90: 64 64 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 dd>.
7aa0: 20 20 20 20 0a 20 20 20 20 20 20 20 20 20 20 20 .
7ab0: 20 3c 2f 64 6c 3e 0a 20 20 20 20 20 20 20 20 20 </dl>.
7ac0: 20 20 20 3c 2f 64 64 3e 20 20 20 0a 20 20 20 20 </dd> .
7ad0: 20 20 20 20 0a 20 20 20 20 3c 2f 64 6c 3e 0a 0a . </dl>..
7ae0: 3c 68 32 3e 3c 61 20 6e 61 6d 65 3d 22 53 45 43 <h2><a name="SEC
7af0: 54 69 64 30 78 31 38 37 39 62 35 30 22 3e 4b 45 Tid0x1879b50">KE
7b00: 59 57 4f 52 44 53 3c 2f 61 3e 3c 2f 68 32 3e 3c YWORDS</a></h2><
7b10: 70 20 63 6c 61 73 73 3d 22 6b 65 79 77 6f 72 64 p class="keyword
7b20: 73 22 3e 0a 3c 61 20 63 6c 61 73 73 3d 22 6b 65 s">.<a class="ke
7b30: 79 77 6f 72 64 22 20 68 72 65 66 3d 22 6b 65 79 yword" href="key
7b40: 77 6f 72 64 2d 69 6e 64 65 78 2e 68 74 6d 6c 23 word-index.html#
7b50: 4b 57 2d 58 4d 4c 22 3e 58 4d 4c 3c 2f 61 3e 2c KW-XML">XML</a>,
7b60: 20 3c 61 20 63 6c 61 73 73 3d 22 6b 65 79 77 6f <a class="keywo
7b70: 72 64 22 20 68 72 65 66 3d 22 6b 65 79 77 6f 72 rd" href="keywor
7b80: 64 2d 69 6e 64 65 78 2e 68 74 6d 6c 23 4b 57 2d d-index.html#KW-
7b90: 44 4f 4d 22 3e 44 4f 4d 3c 2f 61 3e 2c 20 3c 61 DOM">DOM</a>, <a
7ba0: 20 63 6c 61 73 73 3d 22 6b 65 79 77 6f 72 64 22 class="keyword"
7bb0: 20 68 72 65 66 3d 22 6b 65 79 77 6f 72 64 2d 69 href="keyword-i
7bc0: 6e 64 65 78 2e 68 74 6d 6c 23 4b 57 2d 64 6f 63 ndex.html#KW-doc
7bd0: 75 6d 65 6e 74 22 3e 64 6f 63 75 6d 65 6e 74 3c ument">document<
7be0: 2f 61 3e 2c 20 3c 61 20 63 6c 61 73 73 3d 22 6b /a>, <a class="k
7bf0: 65 79 77 6f 72 64 22 20 68 72 65 66 3d 22 6b 65 eyword" href="ke
7c00: 79 77 6f 72 64 2d 69 6e 64 65 78 2e 68 74 6d 6c yword-index.html
7c10: 23 4b 57 2d 6e 6f 64 65 22 3e 6e 6f 64 65 3c 2f #KW-node">node</
7c20: 61 3e 2c 20 3c 61 20 63 6c 61 73 73 3d 22 6b 65 a>, <a class="ke
7c30: 79 77 6f 72 64 22 20 68 72 65 66 3d 22 6b 65 79 yword" href="key
7c40: 77 6f 72 64 2d 69 6e 64 65 78 2e 68 74 6d 6c 23 word-index.html#
7c50: 4b 57 2d 70 61 72 73 69 6e 67 22 3e 70 61 72 73 KW-parsing">pars
7c60: 69 6e 67 3c 2f 61 3e 0a 3c 2f 70 3e 0a 3c 2f 64 ing</a>.</p>.</d
7c70: 69 76 3e 3c 68 72 20 63 6c 61 73 73 3d 22 6e 61 iv><hr class="na
7c80: 76 73 65 70 22 3e 3c 64 69 76 20 63 6c 61 73 73 vsep"><div class
7c90: 3d 22 6e 61 76 62 61 72 22 20 61 6c 69 67 6e 3d ="navbar" align=
7ca0: 22 63 65 6e 74 65 72 22 3e 0a 3c 61 20 63 6c 61 "center">.<a cla
7cb0: 73 73 3d 22 6e 61 76 61 69 64 22 20 68 72 65 66 ss="navaid" href
7cc0: 3d 22 69 6e 64 65 78 2e 68 74 6d 6c 22 3e 43 6f ="index.html">Co
7cd0: 6e 74 65 6e 74 73 3c 2f 61 3e 20 c2 b7 20 3c 61 ntents</a> · <a
7ce0: 20 63 6c 61 73 73 3d 22 6e 61 76 61 69 64 22 20 class="navaid"
7cf0: 68 72 65 66 3d 22 63 61 74 65 67 6f 72 79 2d 69 href="category-i
7d00: 6e 64 65 78 2e 68 74 6d 6c 22 3e 49 6e 64 65 78 ndex.html">Index
7d10: 3c 2f 61 3e 20 c2 b7 20 3c 61 20 63 6c 61 73 73 </a> · <a class
7d20: 3d 22 6e 61 76 61 69 64 22 20 68 72 65 66 3d 22 ="navaid" href="
7d30: 6b 65 79 77 6f 72 64 2d 69 6e 64 65 78 2e 68 74 keyword-index.ht
7d40: 6d 6c 22 3e 4b 65 79 77 6f 72 64 73 3c 2f 61 3e ml">Keywords</a>
7d50: 20 c2 b7 20 3c 61 20 63 6c 61 73 73 3d 22 6e 61 · <a class="na
7d60: 76 61 69 64 22 20 68 72 65 66 3d 22 68 74 74 70 vaid" href="http
7d70: 3a 2f 2f 74 64 6f 6d 2e 6f 72 67 22 3e 52 65 70 ://tdom.org">Rep
7d80: 6f 73 69 74 6f 72 79 3c 2f 61 3e 0a 3c 2f 64 69 ository</a>.</di
7d90: 76 3e 0a 3c 2f 62 6f 64 79 3e 0a 3c 2f 68 74 6d v>.</body>.</htm
7da0: 6c 3e 0a l>.