This file is indexed.

/usr/share/doc/libxom-java-doc/apidocs/nu/xom/Serializer.html is in libxom-java-doc 1.2.10-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

   1
   2
   3
   4
   5
   6
   7
   8
   9
  10
  11
  12
  13
  14
  15
  16
  17
  18
  19
  20
  21
  22
  23
  24
  25
  26
  27
  28
  29
  30
  31
  32
  33
  34
  35
  36
  37
  38
  39
  40
  41
  42
  43
  44
  45
  46
  47
  48
  49
  50
  51
  52
  53
  54
  55
  56
  57
  58
  59
  60
  61
  62
  63
  64
  65
  66
  67
  68
  69
  70
  71
  72
  73
  74
  75
  76
  77
  78
  79
  80
  81
  82
  83
  84
  85
  86
  87
  88
  89
  90
  91
  92
  93
  94
  95
  96
  97
  98
  99
 100
 101
 102
 103
 104
 105
 106
 107
 108
 109
 110
 111
 112
 113
 114
 115
 116
 117
 118
 119
 120
 121
 122
 123
 124
 125
 126
 127
 128
 129
 130
 131
 132
 133
 134
 135
 136
 137
 138
 139
 140
 141
 142
 143
 144
 145
 146
 147
 148
 149
 150
 151
 152
 153
 154
 155
 156
 157
 158
 159
 160
 161
 162
 163
 164
 165
 166
 167
 168
 169
 170
 171
 172
 173
 174
 175
 176
 177
 178
 179
 180
 181
 182
 183
 184
 185
 186
 187
 188
 189
 190
 191
 192
 193
 194
 195
 196
 197
 198
 199
 200
 201
 202
 203
 204
 205
 206
 207
 208
 209
 210
 211
 212
 213
 214
 215
 216
 217
 218
 219
 220
 221
 222
 223
 224
 225
 226
 227
 228
 229
 230
 231
 232
 233
 234
 235
 236
 237
 238
 239
 240
 241
 242
 243
 244
 245
 246
 247
 248
 249
 250
 251
 252
 253
 254
 255
 256
 257
 258
 259
 260
 261
 262
 263
 264
 265
 266
 267
 268
 269
 270
 271
 272
 273
 274
 275
 276
 277
 278
 279
 280
 281
 282
 283
 284
 285
 286
 287
 288
 289
 290
 291
 292
 293
 294
 295
 296
 297
 298
 299
 300
 301
 302
 303
 304
 305
 306
 307
 308
 309
 310
 311
 312
 313
 314
 315
 316
 317
 318
 319
 320
 321
 322
 323
 324
 325
 326
 327
 328
 329
 330
 331
 332
 333
 334
 335
 336
 337
 338
 339
 340
 341
 342
 343
 344
 345
 346
 347
 348
 349
 350
 351
 352
 353
 354
 355
 356
 357
 358
 359
 360
 361
 362
 363
 364
 365
 366
 367
 368
 369
 370
 371
 372
 373
 374
 375
 376
 377
 378
 379
 380
 381
 382
 383
 384
 385
 386
 387
 388
 389
 390
 391
 392
 393
 394
 395
 396
 397
 398
 399
 400
 401
 402
 403
 404
 405
 406
 407
 408
 409
 410
 411
 412
 413
 414
 415
 416
 417
 418
 419
 420
 421
 422
 423
 424
 425
 426
 427
 428
 429
 430
 431
 432
 433
 434
 435
 436
 437
 438
 439
 440
 441
 442
 443
 444
 445
 446
 447
 448
 449
 450
 451
 452
 453
 454
 455
 456
 457
 458
 459
 460
 461
 462
 463
 464
 465
 466
 467
 468
 469
 470
 471
 472
 473
 474
 475
 476
 477
 478
 479
 480
 481
 482
 483
 484
 485
 486
 487
 488
 489
 490
 491
 492
 493
 494
 495
 496
 497
 498
 499
 500
 501
 502
 503
 504
 505
 506
 507
 508
 509
 510
 511
 512
 513
 514
 515
 516
 517
 518
 519
 520
 521
 522
 523
 524
 525
 526
 527
 528
 529
 530
 531
 532
 533
 534
 535
 536
 537
 538
 539
 540
 541
 542
 543
 544
 545
 546
 547
 548
 549
 550
 551
 552
 553
 554
 555
 556
 557
 558
 559
 560
 561
 562
 563
 564
 565
 566
 567
 568
 569
 570
 571
 572
 573
 574
 575
 576
 577
 578
 579
 580
 581
 582
 583
 584
 585
 586
 587
 588
 589
 590
 591
 592
 593
 594
 595
 596
 597
 598
 599
 600
 601
 602
 603
 604
 605
 606
 607
 608
 609
 610
 611
 612
 613
 614
 615
 616
 617
 618
 619
 620
 621
 622
 623
 624
 625
 626
 627
 628
 629
 630
 631
 632
 633
 634
 635
 636
 637
 638
 639
 640
 641
 642
 643
 644
 645
 646
 647
 648
 649
 650
 651
 652
 653
 654
 655
 656
 657
 658
 659
 660
 661
 662
 663
 664
 665
 666
 667
 668
 669
 670
 671
 672
 673
 674
 675
 676
 677
 678
 679
 680
 681
 682
 683
 684
 685
 686
 687
 688
 689
 690
 691
 692
 693
 694
 695
 696
 697
 698
 699
 700
 701
 702
 703
 704
 705
 706
 707
 708
 709
 710
 711
 712
 713
 714
 715
 716
 717
 718
 719
 720
 721
 722
 723
 724
 725
 726
 727
 728
 729
 730
 731
 732
 733
 734
 735
 736
 737
 738
 739
 740
 741
 742
 743
 744
 745
 746
 747
 748
 749
 750
 751
 752
 753
 754
 755
 756
 757
 758
 759
 760
 761
 762
 763
 764
 765
 766
 767
 768
 769
 770
 771
 772
 773
 774
 775
 776
 777
 778
 779
 780
 781
 782
 783
 784
 785
 786
 787
 788
 789
 790
 791
 792
 793
 794
 795
 796
 797
 798
 799
 800
 801
 802
 803
 804
 805
 806
 807
 808
 809
 810
 811
 812
 813
 814
 815
 816
 817
 818
 819
 820
 821
 822
 823
 824
 825
 826
 827
 828
 829
 830
 831
 832
 833
 834
 835
 836
 837
 838
 839
 840
 841
 842
 843
 844
 845
 846
 847
 848
 849
 850
 851
 852
 853
 854
 855
 856
 857
 858
 859
 860
 861
 862
 863
 864
 865
 866
 867
 868
 869
 870
 871
 872
 873
 874
 875
 876
 877
 878
 879
 880
 881
 882
 883
 884
 885
 886
 887
 888
 889
 890
 891
 892
 893
 894
 895
 896
 897
 898
 899
 900
 901
 902
 903
 904
 905
 906
 907
 908
 909
 910
 911
 912
 913
 914
 915
 916
 917
 918
 919
 920
 921
 922
 923
 924
 925
 926
 927
 928
 929
 930
 931
 932
 933
 934
 935
 936
 937
 938
 939
 940
 941
 942
 943
 944
 945
 946
 947
 948
 949
 950
 951
 952
 953
 954
 955
 956
 957
 958
 959
 960
 961
 962
 963
 964
 965
 966
 967
 968
 969
 970
 971
 972
 973
 974
 975
 976
 977
 978
 979
 980
 981
 982
 983
 984
 985
 986
 987
 988
 989
 990
 991
 992
 993
 994
 995
 996
 997
 998
 999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (version 1.7.0_25) on Thu Jul 25 23:19:28 UTC 2013 -->
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>Serializer (XOM 1.2.10  API)</title>
<meta name="date" content="2013-07-25">
<link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="Serializer (XOM 1.2.10  API)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/Serializer.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../index-files/index-1.html">Index</a></li>
<li><a href="../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../nu/xom/ProcessingInstruction.html" title="class in nu.xom"><span class="strong">Prev Class</span></a></li>
<li><a href="../../nu/xom/Text.html" title="class in nu.xom"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../index.html?nu/xom/Serializer.html" target="_top">Frames</a></li>
<li><a href="Serializer.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">nu.xom</div>
<h2 title="Class Serializer" class="title">Class Serializer</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>nu.xom.Serializer</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public class <span class="strong">Serializer</span>
extends java.lang.Object</pre>
<div class="block"><p>
  Outputs a <code>Document</code> object in a specific encoding using
  various options for controlling white space, normalization,
  indenting, line breaking, and base URIs. However, in general these 
  options do affect the document's infoset. In particular, if you set 
  either the maximum line length or the indent size to a positive  
  value, then the serializer will not respect input white space. It 
  may trim leading and trailing space, condense runs of white 
  space to a single space, convert carriage returns and linefeeds
  to spaces, add extra space where none was present before, 
  and otherwise muck with the document's white space. 
  The defaults, however, preserve all significant white space
  including ignorable white space and boundary white space.
 </p></div>
<dl><dt><span class="strong">Version:</span></dt>
  <dd>1.2d1</dd>
<dt><span class="strong">Author:</span></dt>
  <dd>Elliotte Rusty Harold</dd></dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../nu/xom/Serializer.html#Serializer(java.io.OutputStream)">Serializer</a></strong>(java.io.OutputStream&nbsp;out)</code>
<div class="block">
 Create a new serializer that uses the UTF-8 encoding.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colOne"><code><strong><a href="../../nu/xom/Serializer.html#Serializer(java.io.OutputStream, java.lang.String)">Serializer</a></strong>(java.io.OutputStream&nbsp;out,
          java.lang.String&nbsp;encoding)</code>
<div class="block">
 Create a new serializer that uses the specified encoding.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#breakLine()">breakLine</a></strong>()</code>
<div class="block">
   Writes the current line break string
   onto the underlying output stream and indents
   as specified by the current level and the indent property.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#flush()">flush</a></strong>()</code>
<div class="block">
 Flushes the data onto the output stream.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected int</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getColumnNumber()">getColumnNumber</a></strong>()</code>
<div class="block">
   Returns the current column number of the output stream.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getEncoding()">getEncoding</a></strong>()</code>
<div class="block">
   Returns the name of the character encoding used by 
   this serializer.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getIndent()">getIndent</a></strong>()</code>
<div class="block">
 Returns the number of spaces this serializer indents.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getLineSeparator()">getLineSeparator</a></strong>()</code>
<div class="block">
 Returns the string used as a line separator.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getMaxLength()">getMaxLength</a></strong>()</code>
<div class="block">
 Returns the preferred maximum line length.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getPreserveBaseURI()">getPreserveBaseURI</a></strong>()</code>
<div class="block">
 Returns true if this serializer preserves the original
 base URIs by inserting extra <code>xml:base</code> attributes.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#getUnicodeNormalizationFormC()">getUnicodeNormalizationFormC</a></strong>()</code>
<div class="block">
   Indicates whether serialization will
   perform Unicode normalization on all data using normalization
   form C (NFC).</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setIndent(int)">setIndent</a></strong>(int&nbsp;indent)</code>
<div class="block">
 Sets the number of additional spaces to add to each successive
 level in the hierarchy.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setLineSeparator(java.lang.String)">setLineSeparator</a></strong>(java.lang.String&nbsp;lineSeparator)</code>
<div class="block">
 Sets the line separator.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setMaxLength(int)">setMaxLength</a></strong>(int&nbsp;maxLength)</code>
<div class="block">
 Sets the suggested maximum line length for this serializer.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setOutputStream(java.io.OutputStream)">setOutputStream</a></strong>(java.io.OutputStream&nbsp;out)</code>
<div class="block">
 Flushes the previous output stream and 
 redirects further output to the new output stream.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setPreserveBaseURI(boolean)">setPreserveBaseURI</a></strong>(boolean&nbsp;preserve)</code>
<div class="block">
 Determines whether this serializer inserts
 extra <code>xml:base</code> attributes to attempt to 
 preserve base URI information from the document.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#setUnicodeNormalizationFormC(boolean)">setUnicodeNormalizationFormC</a></strong>(boolean&nbsp;normalize)</code>
<div class="block">
   If true, this property indicates serialization will
   perform Unicode normalization on all data using normalization
   form C (NFC).</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.Attribute)">write</a></strong>(<a href="../../nu/xom/Attribute.html" title="class in nu.xom">Attribute</a>&nbsp;attribute)</code>
<div class="block">
   Writes an attribute in the form 
   <code><i>name</i>="<i>value</i>"</code>.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.Comment)">write</a></strong>(<a href="../../nu/xom/Comment.html" title="class in nu.xom">Comment</a>&nbsp;comment)</code>
<div class="block">
 Writes a comment onto the output stream using the current 
 options.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.DocType)">write</a></strong>(<a href="../../nu/xom/DocType.html" title="class in nu.xom">DocType</a>&nbsp;doctype)</code>
<div class="block">
 Writes a <code>DocType</code> object
 onto the output stream using the current options.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.Document)">write</a></strong>(<a href="../../nu/xom/Document.html" title="class in nu.xom">Document</a>&nbsp;doc)</code>
<div class="block">
 Serializes a document onto the output 
 stream using the current options.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.Element)">write</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
 Serializes an element onto the output stream using the current
 options.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.ProcessingInstruction)">write</a></strong>(<a href="../../nu/xom/ProcessingInstruction.html" title="class in nu.xom">ProcessingInstruction</a>&nbsp;instruction)</code>
<div class="block">
 Writes a processing instruction
 onto the output stream using the current options.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#write(nu.xom.Text)">write</a></strong>(<a href="../../nu/xom/Text.html" title="class in nu.xom">Text</a>&nbsp;text)</code>
<div class="block">
 Writes a <code>Text</code> object
 onto the output stream using the current options.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeAttributes(nu.xom.Element)">writeAttributes</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
   Writes all the attributes of the specified
   element onto the output stream, one at a time, separated
   by white space.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeAttributeValue(java.lang.String)">writeAttributeValue</a></strong>(java.lang.String&nbsp;value)</code>
<div class="block">
   Writes a string onto the underlying output stream.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeChild(nu.xom.Node)">writeChild</a></strong>(<a href="../../nu/xom/Node.html" title="class in nu.xom">Node</a>&nbsp;node)</code>
<div class="block">
 Writes a child node onto the output stream using the  
 current options.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeEmptyElementTag(nu.xom.Element)">writeEmptyElementTag</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
  Writes an empty-element tag for the element 
  including all its namespace declarations and attributes.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeEndTag(nu.xom.Element)">writeEndTag</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
   Writes the end-tag for an element in the form
   <code>&lt;/<i>name</i>&gt;</code>.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeEscaped(java.lang.String)">writeEscaped</a></strong>(java.lang.String&nbsp;text)</code>
<div class="block">
 Writes a string onto the underlying output stream.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeNamespaceDeclaration(java.lang.String, java.lang.String)">writeNamespaceDeclaration</a></strong>(java.lang.String&nbsp;prefix,
                         java.lang.String&nbsp;uri)</code>
<div class="block">
   Writes a namespace declaration in the form
   <code>xmlns:<i>prefix</i>="<i>uri</i>"</code> or 
   <code>xmlns="<i>uri</i>"</code>.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeNamespaceDeclarations(nu.xom.Element)">writeNamespaceDeclarations</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
   Writes all the namespace declaration
   attributes of the specified element onto the output stream,
   one at a time, separated by white space.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeRaw(java.lang.String)">writeRaw</a></strong>(java.lang.String&nbsp;text)</code>
<div class="block">
   Writes a string onto the underlying output stream.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeStartTag(nu.xom.Element)">writeStartTag</a></strong>(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)</code>
<div class="block">
  Writes the start-tag for the element including
  all its namespace declarations and attributes.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><strong><a href="../../nu/xom/Serializer.html#writeXMLDeclaration()">writeXMLDeclaration</a></strong>()</code>
<div class="block">
 Writes the XML declaration onto the output stream,
 followed by a line break.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="Serializer(java.io.OutputStream)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>Serializer</h4>
<pre>public&nbsp;Serializer(java.io.OutputStream&nbsp;out)</pre>
<div class="block"><p>
 Create a new serializer that uses the UTF-8 encoding.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>out</code> - the output stream to write the document on</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.lang.NullPointerException</code> - if <code>out</code> is null</dd></dl>
</li>
</ul>
<a name="Serializer(java.io.OutputStream, java.lang.String)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>Serializer</h4>
<pre>public&nbsp;Serializer(java.io.OutputStream&nbsp;out,
          java.lang.String&nbsp;encoding)
           throws java.io.UnsupportedEncodingException</pre>
<div class="block"><p>
 Create a new serializer that uses the specified encoding.
 The encoding must be recognized by the Java virtual machine. If 
 you attempt to use an encoding that the local Java virtual 
 machine does not support, the constructor will throw an 
 <code>UnsupportedEncodingException</code>.
 Currently the following encodings are recognized by XOM:
 </p>
 
 <ul>
   <li>UTF-8</li>
   <li>UTF-16</li>
   <li>UTF-16BE</li>
   <li>UTF-16LE</li>
   <li>ISO-10646-UCS-2</li>
   <li>ISO-8859-1</li>
   <li>ISO-8859-2</li>
   <li>ISO-8859-3</li>
   <li>ISO-8859-4</li>
   <li>ISO-8859-5</li>
   <li>ISO-8859-6</li>
   <li>ISO-8859-7</li>
   <li>ISO-8859-8</li>
   <li>ISO-8859-9</li>
   <li>ISO-8859-10</li>
   <li>ISO-8859-11 (a.k.a. TIS-620)</li>
   <li>ISO-8859-13</li>
   <li>ISO-8859-14</li>
   <li>ISO-8859-15</li>
   <li>ISO-8859-16</li>
   <li>IBM037 (a.k.a. CP037, EBCDIC-CP-US, EBCDIC-CP-CA, 
         EBCDIC-CP-WA, EBCDIC-CP-NL, and CSIBM037)</li>
   <li>GB18030</li>
 </ul>
 
 <p>
 You can use encodings not in this list if the virtual
 machine supports them. However, they may be
 significantly slower than the encodings in this list.
 </p>
 
 <p>
 I've noticed Java has significant bugs in its handling of some
 of these encodings. In some cases such as 0x80 in Big5, XOM
 will escape a character that should not need to be escaped
 because Java can't output that character in the specified 
 encoding, even though the output character set does contain it.
 :-(
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>out</code> - the output stream to write the document on</dd><dd><code>encoding</code> - the character encoding for the serialization</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.lang.NullPointerException</code> - if <code>out</code> 
     or <code>encoding</code> is null</dd>
<dd><code>java.io.UnsupportedEncodingException</code> - if the VM does not 
     support the requested encoding</dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="setOutputStream(java.io.OutputStream)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setOutputStream</h4>
<pre>public&nbsp;void&nbsp;setOutputStream(java.io.OutputStream&nbsp;out)
                     throws java.io.IOException</pre>
<div class="block"><p>
 Flushes the previous output stream and 
 redirects further output to the new output stream.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>out</code> - the output stream to write the document on</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.lang.NullPointerException</code> - if <code>out</code> is null</dd>
<dd><code>java.io.IOException</code> - if the previous output stream 
     encounters an I/O error when flushed</dd></dl>
</li>
</ul>
<a name="write(nu.xom.Document)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>public&nbsp;void&nbsp;write(<a href="../../nu/xom/Document.html" title="class in nu.xom">Document</a>&nbsp;doc)
           throws java.io.IOException</pre>
<div class="block"><p>
 Serializes a document onto the output 
 stream using the current options.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>doc</code> - the <code>Document</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
      encounters an I/O error</dd>
<dd><code>java.lang.NullPointerException</code> - if <code>doc</code> is null</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the document contains 
     an unescapable character (e.g. in an element name) that is 
     not available in the current encoding</dd></dl>
</li>
</ul>
<a name="writeXMLDeclaration()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeXMLDeclaration</h4>
<pre>protected&nbsp;void&nbsp;writeXMLDeclaration()
                            throws java.io.IOException</pre>
<div class="block"><p>
 Writes the XML declaration onto the output stream,
 followed by a line break.
 </p></div>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
      encounters an I/O error</dd></dl>
</li>
</ul>
<a name="write(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
              throws java.io.IOException</pre>
<div class="block"><p>
 Serializes an element onto the output stream using the current
 options. The result is guaranteed to be well-formed.
 </p>
 
 <p>
 If the element is empty, this method invokes 
 <code>writeEmptyElementTag</code>. If the element is not 
 empty, then: 
 </p>
 
 <ol>
   <li>It calls <code>writeStartTag</code>.</li>
   <li>It passes each of the element's children to 
       <code>writeChild</code> in order.</li>
   <li>It calls <code>writeEndTag</code>.</li>
 </ol>
 
 <p>
 It may break lines or add white space if the serializer has
 been configured to indent or use a maximum line length.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the <code>Element</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the element name   
     contains a character that is not available in the 
     current encoding</dd></dl>
</li>
</ul>
<a name="writeEndTag(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeEndTag</h4>
<pre>protected&nbsp;void&nbsp;writeEndTag(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
                    throws java.io.IOException</pre>
<div class="block"><p>
   Writes the end-tag for an element in the form
   <code>&lt;/<i>name</i>&gt;</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the element whose end-tag is written</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd></dl>
</li>
</ul>
<a name="writeStartTag(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeStartTag</h4>
<pre>protected&nbsp;void&nbsp;writeStartTag(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
                      throws java.io.IOException</pre>
<div class="block"><p>
  Writes the start-tag for the element including
  all its namespace declarations and attributes.
 </p>
 
 <p>
   The <code>writeAttributes</code> method is called to write
   all the non-namespace-declaration attributes. 
   The <code>writeNamespaceDeclarations</code> method
   is called to write all the namespace declaration attributes.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the element whose start-tag is written</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the name of the element
     or the name of any of its attributes contains a character  
     that is not available in the current encoding</dd></dl>
</li>
</ul>
<a name="writeEmptyElementTag(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeEmptyElementTag</h4>
<pre>protected&nbsp;void&nbsp;writeEmptyElementTag(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
                             throws java.io.IOException</pre>
<div class="block"><p>
  Writes an empty-element tag for the element 
  including all its namespace declarations and attributes.
 </p>
 
 <p>
   The <code>writeAttributes</code> method is called to write
   all the non-namespace-declaration attributes. 
   The <code>writeNamespaceDeclarations</code> method
   is called to write all the namespace declaration attributes.
 </p>
 
 <p>
   If subclasses don't wish empty-element tags to be used,
   they can override this method to simply invoke 
   <code>writeStartTag</code> followed by 
   <code>writeEndTag</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the element whose empty-element tag is written</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the name of the element or the name of
     any of its attributes contains a character that is not 
     available in the current encoding</dd></dl>
</li>
</ul>
<a name="writeAttributes(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeAttributes</h4>
<pre>protected&nbsp;void&nbsp;writeAttributes(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
                        throws java.io.IOException</pre>
<div class="block"><p>
   Writes all the attributes of the specified
   element onto the output stream, one at a time, separated
   by white space. If preserveBaseURI is true, and it is
   necessary to add an <code>xml:base</code> attribute
   to the element in order to preserve the base URI, then 
   that attribute is also written here.
   Each individual attribute is written by invoking
   <code>write(Attribute)</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the <code>Element</code> whose attributes are 
     written</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the name of any of
     the element's attributes contains a character that is not 
     available in the current encoding</dd></dl>
</li>
</ul>
<a name="writeNamespaceDeclarations(nu.xom.Element)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeNamespaceDeclarations</h4>
<pre>protected&nbsp;void&nbsp;writeNamespaceDeclarations(<a href="../../nu/xom/Element.html" title="class in nu.xom">Element</a>&nbsp;element)
                                   throws java.io.IOException</pre>
<div class="block"><p>
   Writes all the namespace declaration
   attributes of the specified element onto the output stream,
   one at a time, separated by white space. Each individual 
   declaration is written by invoking 
   <code>writeNamespaceDeclaration</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>element</code> - the <code>Element</code> whose namespace
     declarations are written</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if any of the element's 
     namespace prefixes contains a character that is not 
     available in the current encoding</dd></dl>
</li>
</ul>
<a name="writeNamespaceDeclaration(java.lang.String, java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeNamespaceDeclaration</h4>
<pre>protected&nbsp;void&nbsp;writeNamespaceDeclaration(java.lang.String&nbsp;prefix,
                             java.lang.String&nbsp;uri)
                                  throws java.io.IOException</pre>
<div class="block"><p>
   Writes a namespace declaration in the form
   <code>xmlns:<i>prefix</i>="<i>uri</i>"</code> or 
   <code>xmlns="<i>uri</i>"</code>. It does not write
   the spaces on either side of the namespace declaration.
   These are written by <code>writeNamespaceDeclarations</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>prefix</code> - the namespace prefix; the empty string for the
     default namespace</dd><dd><code>uri</code> - the namespace URI</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the namespace prefix contains a 
     character that is not available in the current encoding</dd></dl>
</li>
</ul>
<a name="write(nu.xom.Attribute)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/Attribute.html" title="class in nu.xom">Attribute</a>&nbsp;attribute)
              throws java.io.IOException</pre>
<div class="block"><p>
   Writes an attribute in the form 
   <code><i>name</i>="<i>value</i>"</code>.
   Characters in the attribute value are escaped as necessary.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>attribute</code> - the <code>Attribute</code> to write</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the attribute name contains a character 
     that is not available in the current encoding</dd></dl>
</li>
</ul>
<a name="write(nu.xom.Comment)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/Comment.html" title="class in nu.xom">Comment</a>&nbsp;comment)
              throws java.io.IOException</pre>
<div class="block"><p>
 Writes a comment onto the output stream using the current 
 options. Since character and entity references are not resolved
 in comments, comments can only be serialized when all
 characters they contain are available in the current 
 encoding.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>comment</code> - the <code>Comment</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream 
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the comment contains a 
     character that is not available in the current encoding</dd></dl>
</li>
</ul>
<a name="write(nu.xom.ProcessingInstruction)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/ProcessingInstruction.html" title="class in nu.xom">ProcessingInstruction</a>&nbsp;instruction)
              throws java.io.IOException</pre>
<div class="block"><p>
 Writes a processing instruction
 onto the output stream using the current options.
 Since character and entity references are not resolved
 in processing instructions, processing instructions
 can only be serialized when all
 characters they contain are available in the current 
 encoding.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>instruction</code> - the <code>ProcessingInstruction</code> 
     to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the comment contains a 
     character that is not available in the current encoding</dd></dl>
</li>
</ul>
<a name="write(nu.xom.Text)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/Text.html" title="class in nu.xom">Text</a>&nbsp;text)
              throws java.io.IOException</pre>
<div class="block"><p>
 Writes a <code>Text</code> object
 onto the output stream using the current options.
 Reserved characters such as &lt;, &gt; and "
 are escaped using the standard entity references 
 such as <code>&amp;lt;</code>, <code>&amp;gt;</code>, 
 and <code>&amp;quot;</code>.
 </p>
 
 <p>
 Characters which cannot be encoded in the current character set
 (for example, &Omega; in ISO-8859-1) are encoded using 
 character references. 
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>text</code> - the <code>Text</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd></dl>
</li>
</ul>
<a name="write(nu.xom.DocType)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>write</h4>
<pre>protected&nbsp;void&nbsp;write(<a href="../../nu/xom/DocType.html" title="class in nu.xom">DocType</a>&nbsp;doctype)
              throws java.io.IOException</pre>
<div class="block"><p>
 Writes a <code>DocType</code> object
 onto the output stream using the current options.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>doctype</code> - the document type declaration to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying 
     output stream encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/UnavailableCharacterException.html" title="class in nu.xom">UnavailableCharacterException</a></code> - if the document type   
     declaration contains a character that is not available 
     in the current encoding</dd></dl>
</li>
</ul>
<a name="writeChild(nu.xom.Node)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeChild</h4>
<pre>protected&nbsp;void&nbsp;writeChild(<a href="../../nu/xom/Node.html" title="class in nu.xom">Node</a>&nbsp;node)
                   throws java.io.IOException</pre>
<div class="block"><p>
 Writes a child node onto the output stream using the  
 current options. It is invoked when walking the tree to
 serialize the entire document. It is not called, and indeed
 should not be called, for either the <code>Document</code> 
 node or for attributes. 
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>node</code> - the <code>Node</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error</dd>
<dd><code><a href="../../nu/xom/XMLException.html" title="class in nu.xom">XMLException</a></code> - if an <code>Attribute</code>, a 
     <code>Document</code>, or <code>Namespace</code>
     is passed to this method</dd></dl>
</li>
</ul>
<a name="writeEscaped(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeEscaped</h4>
<pre>protected final&nbsp;void&nbsp;writeEscaped(java.lang.String&nbsp;text)
                           throws java.io.IOException</pre>
<div class="block"><p>
 Writes a string onto the underlying output stream.
 Non-ASCII characters that are not available in the
 current character set are encoded with numeric character
 references. The three reserved characters &lt;, &gt;, and &amp; 
 are escaped using the standard entity references 
 <code>&amp;lt;</code>, <code>&amp;gt;</code>, 
 and <code>&amp;amp;</code>.
 Double and single quotes are not escaped.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>text</code> - the parsed character data to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream 
     encounters an I/O error</dd></dl>
</li>
</ul>
<a name="writeAttributeValue(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeAttributeValue</h4>
<pre>protected final&nbsp;void&nbsp;writeAttributeValue(java.lang.String&nbsp;value)
                                  throws java.io.IOException</pre>
<div class="block"><p>
   Writes a string onto the underlying output stream.
   Non-ASCII characters that are not available in the
   current character set are escaped using hexadecimal numeric
   character references. Carriage returns, line feeds, and tabs
   are also escaped using hexadecimal numeric character 
   references in order to ensure their preservation on a round
   trip. The four reserved characters &lt;, &gt;, &amp;,  
   and &quot; are escaped using the standard entity references 
   <code>&amp;lt;</code>, <code>&amp;gt;</code>, 
   <code>&amp;amp;</code>, and <code>&amp;quot;</code>. 
   The single quote is not escaped. 
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>value</code> - the attribute value to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream 
     encounters an I/O error</dd></dl>
</li>
</ul>
<a name="writeRaw(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeRaw</h4>
<pre>protected final&nbsp;void&nbsp;writeRaw(java.lang.String&nbsp;text)
                       throws java.io.IOException</pre>
<div class="block"><p>
   Writes a string onto the underlying output stream.
   without escaping any characters.
   Non-ASCII characters that are not available in the
   current character set cause an <code>IOException</code>.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>text</code> - the <code>String</code> to serialize</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream
     encounters an I/O error or <code>text</code> contains 
     characters not available in the current character set</dd></dl>
</li>
</ul>
<a name="breakLine()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>breakLine</h4>
<pre>protected final&nbsp;void&nbsp;breakLine()
                        throws java.io.IOException</pre>
<div class="block"><p>
   Writes the current line break string
   onto the underlying output stream and indents
   as specified by the current level and the indent property.
 </p></div>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying output stream 
     encounters an I/O error</dd></dl>
</li>
</ul>
<a name="flush()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>flush</h4>
<pre>public&nbsp;void&nbsp;flush()
           throws java.io.IOException</pre>
<div class="block"><p>
 Flushes the data onto the output stream.
 It is not enough to flush the output stream.
 You must flush the serializer object itself because it
 uses some internal buffering.
 The serializer will flush the underlying output stream.
 </p></div>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if the underlying  
     output stream encounters an I/O error</dd></dl>
</li>
</ul>
<a name="getIndent()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getIndent</h4>
<pre>public&nbsp;int&nbsp;getIndent()</pre>
<div class="block"><p>
 Returns the number of spaces this serializer indents.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the number of spaces this serializer indents
     each successive level beyond the previous one</dd></dl>
</li>
</ul>
<a name="setIndent(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setIndent</h4>
<pre>public&nbsp;void&nbsp;setIndent(int&nbsp;indent)</pre>
<div class="block"><p>
 Sets the number of additional spaces to add to each successive
 level in the hierarchy. Use 0 for no extra indenting. The 
 maximum indentation is in limited to approximately half the
 maximum line length. The serializer will not indent further 
 than that no matter how many levels deep the hierarchy is.
 </p>
 
 <p>
   When this variable is set to a value greater than 0,
   the serializer does not preserve white space. Spaces,
   tabs, carriage returns, and line feeds can all be 
   interchanged at the serializer's discretion, and additional
   white space may be added before and after tags.
   Carriage returns, line feeds, and tabs will not be 
   escaped with numeric character references.
 </p>
 
 <p>
   Inside elements with an <code>xml:space="preserve"</code> 
   attribute, white space is preserved and no indenting 
   takes place, regardless of the setting of the indent
   property, unless, of course, an 
   <code>xml:space="default"</code> attribute overrides the
   <code>xml:space="preserve"</code> attribute.
 </p>
 
 <p>
   The default value for indent is 0; that is, the default is
   not to add or subtract any white space from the source
   document.  
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>indent</code> - the number of spaces to indent 
      each successive level of the hierarchy</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.lang.IllegalArgumentException</code> - if indent is less than zero</dd></dl>
</li>
</ul>
<a name="getLineSeparator()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLineSeparator</h4>
<pre>public&nbsp;java.lang.String&nbsp;getLineSeparator()</pre>
<div class="block"><p>
 Returns the string used as a line separator.
 This is always <code>"\n"</code>, <code>"\r"</code>, 
 or <code>"\r\n"</code>.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the line separator</dd></dl>
</li>
</ul>
<a name="setLineSeparator(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setLineSeparator</h4>
<pre>public&nbsp;void&nbsp;setLineSeparator(java.lang.String&nbsp;lineSeparator)</pre>
<div class="block"><p>
 Sets the line separator. This can only be one of the 
 three strings <code>"\n"</code>, <code>"\r"</code>, 
 or <code>"\r\n"</code>. All other values are forbidden.
 If this method is invoked, then 
 line separators in the character data will be changed to this
 string. Line separators in attribute values will be changed
 to the hexadecimal numeric character references corresponding
 to this string.
 </p>
 
 <p>
  The default line separator is <code>"\r\n"</code>. However, 
  line separators in character data and attribute values are not 
  changed to this string, unless this method is called first.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>lineSeparator</code> - the line separator to set</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.lang.IllegalArgumentException</code> - if you attempt to use any line
    separator other than <code>"\n"</code>, <code>"\r"</code>, 
    or <code>"\r\n"</code>.</dd></dl>
</li>
</ul>
<a name="getMaxLength()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxLength</h4>
<pre>public&nbsp;int&nbsp;getMaxLength()</pre>
<div class="block"><p>
 Returns the preferred maximum line length.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the preferred maximum line length.</dd></dl>
</li>
</ul>
<a name="setMaxLength(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setMaxLength</h4>
<pre>public&nbsp;void&nbsp;setMaxLength(int&nbsp;maxLength)</pre>
<div class="block"><p>
 Sets the suggested maximum line length for this serializer.
 Setting this to 0 indicates that no automatic wrapping is to be
 performed. When a line approaches this length, the serializer 
 begins looking for opportunities to break the line. Generally 
 it will break on any ASCII white space character (tab, carriage 
 return, linefeed, and space). In some circumstances the 
 serializer may not be able to break the line before the maximum
 length is reached. For instance, if an element name is longer 
 than the maximum line length the only way to correctly 
 serialize it is to exceed the maximum line length. In this case,
  the serializer will exceed the maximum line length.
 </p>
 
 <p>
 The default value for maximum line length is 0, which is  
 interpreted as no maximum line length. 
 Setting this to a negative value just sets it to 0. 
 </p>
 
 <p>
   When this variable is set to a value greater than 0,
   the serializer does not preserve white space. Spaces,
   tabs, carriage returns, and line feeds can all be 
   interchanged at the serializer's discretion.
   Carriage returns, line feeds, and tabs will not be 
   escaped with numeric character references.
 </p>
 
 <p>
   Inside elements with an <code>xml:space="preserve"</code> 
   attribute, the maximum line length is not enforced, 
   regardless of the setting of the this property, unless,  
   of course, an <code>xml:space="default"</code> attribute 
   overrides the <code>xml:space="preserve"</code> attribute.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>maxLength</code> - the preferred maximum line length</dd></dl>
</li>
</ul>
<a name="getPreserveBaseURI()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPreserveBaseURI</h4>
<pre>public&nbsp;boolean&nbsp;getPreserveBaseURI()</pre>
<div class="block"><p>
 Returns true if this serializer preserves the original
 base URIs by inserting extra <code>xml:base</code> attributes.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>true if this <code>Serializer</code> inserts
    extra <code>xml:base</code> attributes to attempt to 
    preserve base URI information from the document.</dd></dl>
</li>
</ul>
<a name="setPreserveBaseURI(boolean)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setPreserveBaseURI</h4>
<pre>public&nbsp;void&nbsp;setPreserveBaseURI(boolean&nbsp;preserve)</pre>
<div class="block"><p>
 Determines whether this serializer inserts
 extra <code>xml:base</code> attributes to attempt to 
 preserve base URI information from the document.
 The default is false, do not preserve base URI information.
 <code>xml:base</code> attributes that have been explicitly
 added to an element are always output. This property only  
 determines whether or not extra <code>xml:base</code> 
 attributes are added.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>preserve</code> - true if <code>xml:base</code> 
     attributes should be added as necessary
     to preserve base URI information</dd></dl>
</li>
</ul>
<a name="getEncoding()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getEncoding</h4>
<pre>public&nbsp;java.lang.String&nbsp;getEncoding()</pre>
<div class="block"><p>
   Returns the name of the character encoding used by 
   this serializer.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the encoding used for the output document</dd></dl>
</li>
</ul>
<a name="setUnicodeNormalizationFormC(boolean)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setUnicodeNormalizationFormC</h4>
<pre>public&nbsp;void&nbsp;setUnicodeNormalizationFormC(boolean&nbsp;normalize)</pre>
<div class="block"><p>
   If true, this property indicates serialization will
   perform Unicode normalization on all data using normalization
   form C (NFC). Performing Unicode normalization may change the
   document's infoset. The default is false; do not normalize.
   This version is based on Unicode 4.0. 
 </p>
 
 <p>
   This feature has not yet been benchmarked or optimized.
   It may result in substantially slower code. 
 </p>
 
 <p>
   If all your data is in the first 256 code points of Unicode
   (i.e. the ISO-8859-1, Latin-1 character set), then it's 
   already in normalization form C and normalizing won't change
   anything.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>normalize</code> - true if normalization is performed; 
     false if it isn't</dd></dl>
</li>
</ul>
<a name="getUnicodeNormalizationFormC()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getUnicodeNormalizationFormC</h4>
<pre>public&nbsp;boolean&nbsp;getUnicodeNormalizationFormC()</pre>
<div class="block"><p>
   Indicates whether serialization will
   perform Unicode normalization on all data using normalization
   form C (NFC). The default is false; do not normalize.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>true if this serializer performs Unicode 
     normalization; false if it doesn't</dd></dl>
</li>
</ul>
<a name="getColumnNumber()">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getColumnNumber</h4>
<pre>protected final&nbsp;int&nbsp;getColumnNumber()</pre>
<div class="block"><p>
   Returns the current column number of the output stream. This 
   method useful for subclasses that implement their own pretty
   printing strategies by inserting white space and line breaks 
   at appropriate points.
 </p>
 
 <p>
   Columns are counted based on Unicode characters, not Java
   chars. A surrogate pair counts as one character in this 
   context, not two. However, a character followed by a 
   combining character (e.g. e followed by combining accent
   acute) counts as two characters. This latter choice
   (treating combining characters like regular characters)
   is under review, and may change in the future if it's not
   too big a performance hit.
 </p></div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the current column number</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/Serializer.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../index-files/index-1.html">Index</a></li>
<li><a href="../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../nu/xom/ProcessingInstruction.html" title="class in nu.xom"><span class="strong">Prev Class</span></a></li>
<li><a href="../../nu/xom/Text.html" title="class in nu.xom"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../index.html?nu/xom/Serializer.html" target="_top">Frames</a></li>
<li><a href="Serializer.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright 2002-2013 <a href='http://www.elharo.com/'>Elliotte Rusty Harold</a>     <br /> <a href='mailto:elharo%40ibiblio%2Eorg?Subject=XOM'>elharo@ibiblio.org</a></small></p>
</body>
</html>