-
Notifications
You must be signed in to change notification settings - Fork 2.2k
/
CHANGES
1268 lines (859 loc) · 59.5 KB
/
CHANGES
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
jsoup changelog
*** Release 1.13.1 [2020-Feb-29]
* Improvement: added Element#closest(selector), which walks up the tree to find the nearest element matching the
selector.
<https://github.com/jhy/jsoup/issues/1326>
* Improvement: memory optimizations, reducing the retained size of a Document by ~ 39%, and allocations by ~ 9%:
1. Attributes holder in Elements is only created if the element has attributes
2. Only track the baseUri in an element when it is set via DOM to a new value for a given tree
3. After parsing, do not retain the input character reader (and associated buffers) in the Document#parser
* Improvement: substantial parse speed improvements vs 1.12.x (bringing back to par with previous releases).
<https://github.com/jhy/jsoup/issues/1327>
* Improvement: when pretty-printing, comments in inline tags are not pushed to a newline
* Improvement: added Attributes#hasDeclaredValueForKey(key) and Attribute#hasDeclaredValueForKeyIgnoreCase(), to check
if an attribute is set but has no value. Useful in place of the deprecated and removed BooleanAttribute class and
instanceof test.
* Improvement: removed old methods and classes that were marked deprecated in previous releases.
* Improvement: added Element#select(Evaluator) and Element#selectFirst(Evaluator), to allow re-use of a parsed CSS
selector if using the same evaluator many times.
<https://github.com/jhy/jsoup/issues/1319>
* Improvement: added Elements#forms(), Elements#textNodes(), Elements#dataNodes(), and Elements#comments(), as a
convenient way to get access to these node types directly from an element selection.
* Improvement: preserve whitespace before html and head tag, if pretty-printing is off.
* Bugfix: in a <select> tag, a second <optgroup> would not automatically close an earlier open <optgroup>
<https://github.com/jhy/jsoup/issues/1313>
* Bugfix: in CharacterReader when parsing an input stream, could throw a Mark Invalid exception if the reader was
marked, a bufferUp occurred, and then the reader was rewound.
<https://github.com/jhy/jsoup/issues/1324>
* Bugfix: empty tags and form tags did not have their attributes normalized (lower-cased by default)
<https://github.com/jhy/jsoup/pull/1323>
* Bugfix: when preserve case was set to on, the HTML pretty-print formatter didn't indent capitalized tags correctly.
* Bugfix: ensure that script and style contents are parsed into DataNodes, not TextNodes, when in case-sensitive
parse mode.
**** Release 1.12.2 [2020-Feb-08]
* Improvement: the :has() selector now supports relative selectors. For example, the query
"div:has(> a)" will select all "div" elements that have at least one direct child "a" element.
<https://github.com/jhy/jsoup/pull/1214>
* Improvement: added Element chaining methods for various overridden methods on Node.
<https://github.com/jhy/jsoup/issues/1193>
* Improvement: ensure HTTP keepalives work when fetching content via body() and bodyAsBytes().
<https://github.com/jhy/jsoup/issues/1232>
* Improvement: set the default max body size in Jsoup.Connection to 2MB (up from 1MB) so fewer people get trimmed
content if they have not set it, but still in sensible bounds. Also updated the default user-agent to improve
default compatibility.
* Improvement: dramatic speed improvement when bulk inserting child nodes into an element (wrapping contents).
<https://github.com/jhy/jsoup/issues/1281>
* Improvement: added Element#childrenSize() as a convenience to get the size of an element's element children.
<https://github.com/jhy/jsoup/pull/1291>
* Improvement: in W3CDom.asString, allow the output mode to be specified as HTML or as XML. It will default to
checking the content, and automatically selecting.
* Improvement: added a Document#documentType() method, to get a doc's doctype.
* Improvement: To DocumentType, added #name(), #publicID(), and #systemId() methods to fetch those fields.
* Improvement: in W3CDom conversions from jsoup documents, retain the DocumentType, and be able to serialize it.
<https://github.com/jhy/jsoup/issues/1183>
* Bugfix: on pages fetch by Jsoup.Connection, a "Mark Invalid" exception might be incorrectly thrown, or the page may
miss some data. This occurred on larger pages when the file transfer was chunked, and an invalid HTML entity
happened to cross a chunk boundary.
<https://github.com/jhy/jsoup/issues/1218>
* Bugfix: if duplicate attributes in an element exist, retain the first vs the last attribute with the same name. Case
aware (HTML case-insensitive names, XML are case-sensitive).
<https://github.com/jhy/jsoup/issues/1219>
* Bugfix: don't submit input type=button form elements.
<https://github.com/jhy/jsoup/issues/1231>
* Bugfix: handle error position reporting correctly and don't blow up in some edge cases.
<https://github.com/jhy/jsoup/issues/1251>
<https://github.com/jhy/jsoup/pull/1253>
* Bugfix: handle the ^= (starts with) selector correctly when the prefix starts with a space.
<https://github.com/jhy/jsoup/pull/1280>
* Bugfix: don't strip out zero-width-joiners (or zero-width-non-joiners) when normalizing text. That breaks combined
emoji (and other text semantics). 🤦♂️
<https://github.com/jhy/jsoup/issues/1269>
* Bugfix: Evaluator.TagEndsWith (namespaced elements) and Tag disagreed in case-sensitivity. Now correctly matches
case-insensitively.
<https://github.com/jhy/jsoup/issues/1257>
* Bugfix: Don't throw an exception if a selector ends in a space, just trim it.
<https://github.com/jhy/jsoup/issues/1274>
* Bugfix: HTML parser adds redundant text when parsing self-closing textarea.
<https://github.com/jhy/jsoup/issues/1220>
* Bugfix: Don't add spurious whitespace or newlines to HTML or text for inline tags.
<https://github.com/jhy/jsoup/issues/1305>
<https://github.com/jhy/jsoup/issues/731>
* Bugfix: TextNode.outerHtml() wouldn't normalize correctly without a parent.
<https://github.com/jhy/jsoup/issues/1309>
* Bugfix: Removed binary input detection as it was causing too many false positives.
<https://github.com/jhy/jsoup/issues/1250>
* Bugfix: when cloning a TextNode, if .attributes() was hit before the clone() method, the text value would only be a
shallow clone.
<https://github.com/jhy/jsoup/issues/1176>
* Various code hygiene updates.
**** Release 1.12.1 [2019-May-12]
* Change: removed deprecated method to disable TLS cert checking Connection.validateTLSCertificates().
* Change: some internal methods have been rearranged; if you extended any of the Jsoup internals you may need to make
updates.
* Improvement: documents now remember their parser, so when later manipulating them, the correct HTML or XML tree
builder is reused, as are the parser settings like case preservation.
<https://github.com/jhy/jsoup/issues/769>
* Improvement: Jsoup now detects the character set of the input if specified in an XML Declaration, when using the
HTML parser. Previously that only happened when the XML parser was specified.
<https://github.com/jhy/jsoup/issues/1009>
* Improvement: if the document's input character set does not support encoding, flip it to one that does.
<https://github.com/jhy/jsoup/issues/1007>
* Improvement: if a start tag is missing a > and a new tag is seen with a <, treat that as a new tag. (This differs
from the HTML5 spec, which would make at attribute with a name beginning with <, but in practice this impacts too
many pages.
<https://github.com/jhy/jsoup/issues/797>
* Improvement: performance tweaks when parsing start tags, data, tables.
* Improvement: added Element.nextElementSiblings() and Element.previousElementSiblings()
<https://github.com/jhy/jsoup/pull/1054>
* Improvement: treat center tags as block tags.
<https://github.com/jhy/jsoup/pull/1113>
* Improvement: allow forms to be submitted with Content-Type=multipart/form-data without requiring a file upload;
automatically set the mime boundary.
<https://github.com/jhy/jsoup/pull/1058>
* Improvement: Jsoup will now detect if an input file or URL is binary, and will refuse to attempt to parse it, with
an IO exception. This prevents runaway processing time and wasted effort creating meaningless parsed DOM trees.
<https://github.com/jhy/jsoup/issues/1192>
* Bugfix: when using the tag case preserving parsing settings, certain HTML tree building rules where not followed
for upper case tags.
<https://github.com/jhy/jsoup/issues/1149>
* Bugfix: when converting a Jsoup document to a W3C DOM, if an element is namespaced but not in a defined namespace,
set it to the global namespace.
<https://github.com/jhy/jsoup/issues/848>
* Bugfix: attributes created with the Attribute constructor with just spaces for names would incorrectly pass
validation.
<https://github.com/jhy/jsoup/issues/1159>
* Bugfix: some pseudo XML Declarations were incorrectly handled when using the XML Parser, leading to an IOOB
exception when parsing.
<https://github.com/jhy/jsoup/issues/1139>
* Bugfix: when parsing URL parameter names in an attribute that is not correctly HTML encoded, and near the end of the
current buffer, those parameters may be incorrectly dropped. (Improved CharacterReader mark/reset support.)
<https://github.com/jhy/jsoup/pull/1154>
* Bugfix: boolean attribute values would be returned as null, vs an empty string, when accessed via the
Attribute#getValue() method.
<https://github.com/jhy/jsoup/issues/1065>
* Bugix: orphan Attribute objects (i.e. created outside of a parse or an Element) would throw an NPE on
Attribute#setValue(val)
<https://github.com/jhy/jsoup/issues/1107>
* Bugfix: Element.shallowClone() was not making a clone of its attributes.
<https://github.com/jhy/jsoup/issues/1201>
* Bugfix: fixed an ArrayIndexOutOfBoundsException in HttpConnection.looksLikeUtf8 when testing small strings in
specific ranges.
<https://github.com/jhy/jsoup/issues/1172>
* Updated jetty-server (which is used for integration tests) to latest 9.2 series (9.2.28).
*** Release 1.11.3 [2018-Apr-15]
* Improvement: CDATA sections are now treated as whitespace preserving (regardless of the containing element), and are
round-tripped into output HTML.
<https://github.com/jhy/jsoup/issues/406>
<https://github.com/jhy/jsoup/issues/965>
* Improvement: added support for Deflate encoding.
<https://github.com/jhy/jsoup/pull/982>
* Improvement: when parsing <pre> tags, skip the first newline if present.
<https://github.com/jhy/jsoup/issues/825>
* Improvement: support nested quotes for attribute selection queries.
<https://github.com/jhy/jsoup/pull/988>
* Improvement: character references from Windows-1252 that are not valid Unicode are mapped to the appropriate
Unicode replacement.
<https://github.com/jhy/jsoup/pull/1046>
* Improvement: accept a custom SSL socket factory in Jsoup.Connection.
<https://github.com/jhy/jsoup/pull/1038>
* Bugfix: "Mark has been invalidated" exception was thrown when parsing some URLs on Android <= 6.
<https://github.com/jhy/jsoup/issues/990>
* Bugfix: The Element.text() for <div>One</div>Two was "OneTwo", not "One Two".
<https://github.com/jhy/jsoup/issues/812>
* Bugfix: boolean attributes with empty string values were not collapsing in HTML output.
<https://github.com/jhy/jsoup/issues/985>
* Bugfix: when using the XML Parser set to lowercase normalize tags, uppercase closing tags were not correctly
handled.
<https://github.com/jhy/jsoup/issues/998>
* Bugfix: when parsing from a URL, an end tag could be read incorrectly if it started on a buffer boundary.
<https://github.com/jhy/jsoup/issues/995>
* Bugfix: when parsing from a URL, if the remote server failed to complete its write (i.e. it writes less than the
Content Length header promised on a gzipped stream), the parse method would incorrectly throw an unchecked
exception. It now throws the declared IOException.
<https://github.com/jhy/jsoup/issues/980>
* Bugfix: leaf nodes (such as text nodes) where throwing an unsupported operation exception on childNodes(), instead
of just returning an empty list.
<https://github.com/jhy/jsoup/issues/1032>
* Bugfix: documents with a leading UTF-8 BOM did not have that BOM consumed, so it acted as a zero width no-break
space, which could impact the parse tree.
<https://github.com/jhy/jsoup/issues/1003>
* Bugfix: when parsing an invalid XML declaration, the parse would fail.
<https://github.com/jhy/jsoup/issues/1015>
*** Release 1.11.2 [2017-Nov-19]
* Improvement: added a new pseudo selector :matchText, which allows text nodes to match as if they were elements.
This enables finding text that is only marked by a "br" tag, for example.
<https://github.com/jhy/jsoup/issues/550>
* Change: marked Connection.validateTLSCertificates() as deprecated.
* Improvement: normalize invisible characters (like soft-hyphens) in Element.text().
<https://github.com/jhy/jsoup/issues/978>
* Improvement: added Element.wholeText(), to easily get the un-normalized text value of an element and its children.
<https://github.com/jhy/jsoup/pull/564>
* Bugfix: in a deep DOM stack, a StackOverFlow exception could occur when generating implied end tags.
<https://github.com/jhy/jsoup/issues/966>
* Bugfix: when parsing attribute values that happened to cross a buffer boundary, a character was dropped.
<https://github.com/jhy/jsoup/issues/967>
* Bugfix: fixed an issue that prevented using infinite timeouts in Jsoup.Connection.
<https://github.com/jhy/jsoup/issues/968>
* Bugfix: whitespace preserving tags were not honoured when nested deeper than two levels deep.
<https://github.com/jhy/jsoup/issues/722>
* Bugfix: an unterminated comment token at the end of the HTML input would cause an out of bounds exception.
<https://github.com/jhy/jsoup/issues/972>
* Bugfix: an NPE in the Cleaner which would occur if an <a href> attribute value was missing.
<https://github.com/jhy/jsoup/issues/973>
* Bugfix: when serializing the same document in a multiple threads, on Android, with a character set that is not ascii
or UTF-8, an encoding exception could occur.
<https://github.com/jhy/jsoup/issues/970>
* Bugfix: removing a form value from the DOM would not remove it from FormData.
<https://github.com/jhy/jsoup/pull/969>
* Bugfix: in the W3CDom transformer, siblings were incorrectly inheriting namespaces defined on previous siblings.
<https://github.com/jhy/jsoup/issues/977>
*** Release 1.11.1 [2017-Nov-06]
* Updated language level to Java 7 from Java 5. To maintain Android support (of minversion 8), try-with-resources are
not used.
<https://github.com/jhy/jsoup/issues/899>
* When loading content from a URL or a file, the content is now parsed as it streams in from the network or disk,
rather than being fully buffered before parsing. This substantially reduces memory consumption & large garbage
objects when loading large files. Note that this change means that a response, once parsed, may not be parsed
again from the same response object unless you call response.bufferUp() first, which will buffer the full response
into memory.
<https://github.com/jhy/jsoup/issues/904>
* Added Connection.Response.bodyStream(), a method to get the response body as an input stream. This is useful for
saving a large response straight to a file, without buffering fully into memory first.
* Performance improvements in text and HTML generation (through less GC).
* Reduced memory consumption of text, scripts, and comments in the DOM by 40%, by refactoring the node
hierarchy to not track childnodes or attributes by default for lead nodes. For the average document, that's about a
30% memory reduction.
<https://github.com/jhy/jsoup/issues/911>
* Reduced memory consumption of Elements by refactoring their Attributes to be a simple pair of arrays, vs a
LinkedHashSet.
<https://github.com/jhy/jsoup/issues/911>
* Added support for Element.selectFirst(query), to efficiently find the first matching element.
* Added Element.appendTo(parent) to simplify slinging elements about.
<https://github.com/jhy/jsoup/pull/662>
* Added support for multiple headers with the same name in Jsoup.Connect
* Added Element.shallowClone() and Node.shallowClone(), to allow cloning nodes without getting all their children.
<https://github.com/jhy/jsoup/issues/900>
* Updated Element.text() and the :contains(text) selector to consider character as spaces.
* Updated Jsoup.connect().timeout() to implement a total connect + combined read timeout. Previously it specified
connect and buffer read times only, so to implement a combined total timeout, you had to have another thread send
an interupt.
* Improved performance of Node.addChildren (was quadratic)
<https://github.com/jhy/jsoup/pull/930>
* Added missing support for template tags in tables
<https://github.com/jhy/jsoup/pull/901>
* In Jsoup.connect file uploads, added the ability to set the uploaded files' mimetype.
<https://github.com/jhy/jsoup/issues/936>
* Improved Node traversal, including less object creation, and partial and filtering traversor support.
<https://github.com/jhy/jsoup/pull/849>
* Bugfix: if a document was was redecoded after character set detection, the HTML parser was not reset correctly,
which could lead to an incorrect DOM.
<https://github.com/jhy/jsoup/issues/877>
* Bugfix: attributes with the same name but different case would be incorrectly treated as different attributes.
<https://github.com/jhy/jsoup/pull/903>
* Bugfix: self-closing tags for known empty elements were incorrectly treated as errors.
<https://github.com/jhy/jsoup/issues/868>
* Bugfix: fixed an issue where a self-closing title, noframes, or style tag would cause the rest of the page to be
incorrectly parsed as data or text.
<https://github.com/jhy/jsoup/issues/906>
* Bugfix: fixed an issue with unknown mixed-case tags
<https://github.com/jhy/jsoup/pull/942>
* Bugfix: fixed an issue where the entity resources were left open after startup, causing a warning.
<https://github.com/jhy/jsoup/pull/928>
* Bugfix: fixed an issue where Element.getElementsByIndexLessThan(index) would incorrectly provide the root element
<https://github.com/jhy/jsoup/pull/918>
* Improved parse time for pages with exceptionally deeply nested tags.
<https://github.com/jhy/jsoup/issues/955>
* Improvement / workaround: modified the Entities implementation to load its data from a .class vs from a jar resource.
Faster, and safer on Android.
<https://github.com/jhy/jsoup/issues/959>
*** Release 1.10.3 [2017-Jun-11]
* Added Elements.eachText() and Elements.eachAttr(name), which return a list of Element's text or attribute values,
respectively. This makes it simpler to for example get a list of each URL on a page:
List<String> urls = doc.select("a").eachAttr("abs:href"");
* Improved selector validation for :contains(...) with unbalanced quotes.
<https://github.com/jhy/jsoup/issues/803>
* Improved the speed of index based CSS selectors and other methods that use elementSiblingIndex, by a factor of 34x.
<https://github.com/jhy/jsoup/pull/862>
* Added Node.clearAttributes(), to simplify removing of all attributes of a Node / Element.
<https://github.com/jhy/jsoup/issues/829>
* Bugfix: if an attribute name started or ended with a control character, the parse would fail with a validation
exception.
<https://github.com/jhy/jsoup/issues/793>
* Bugfix: Element.hasClass() and the ".classname" selector would not find the class attribute case-insensitively.
<https://github.com/jhy/jsoup/issues/814>
* Bugfix: In Jsoup.Connection, if a redirect contained a query string with %xx escapes, they would be double escaped
before the redirect was followed, leading to fetching an incorrect location.
* Bugfix: In Jsoup.Connection, if a request body was set and the connection was redirected, the body would incorrectly
still be sent.
<https://github.com/jhy/jsoup/pull/881>
* Bugfix: In DataUtil when detecting the character set from meta data, and there are two Content-Types defined, use
the one that defines a character set.
<https://github.com/jhy/jsoup/pull/835>
* Bugfix: when parsing unknown tags in case-sensitive HTML mode, end tags would not close scope correctly.
<https://github.com/jhy/jsoup/issues/819>
* In Jsoup.Connection, ensure there is no Content-Type set when being redirected to a GET.
<https://github.com/jhy/jsoup/pull/895>
* Bugfix: in certain locales (Turkey specifically), lowercasing and case insensitivity could fail for specific items.
<https://github.com/jhy/jsoup/pull/820>
* Bugfix: after an element was cloned, changes to its child list where not notifying the element correctly.
<https://github.com/jhy/jsoup/issues/951>
*** Release 1.10.2 [2017-Jan-02]
* Improved startup time, particularly on Android, by reducing garbage generation and CPU execution time when loading
the HTML entity files. About 1.72x faster in this area.
* Added Element.is(query) to check if an element matches this CSS query.
* Added new methods to Elements: next(query), nextAll(query), prev(query), prevAll(query) to select next and previous
element siblings from a current selection, with optional selectors.
* Added Node.root() to get the topmost ancestor of a Node.
* Added the new selector :containsData(), to find elements that hold data, like script and style tags.
* Changed Jsoup.isValid(bodyHtml) to validate that the input contains only body HTML that is safe according to the
whitelist, and does not include HTML errors. And in the Jsoup.Cleaner.isValid(Document) method, make sure the doc
only includes body HTML.
<https://github.com/jhy/jsoup/issues/245>
<https://github.com/jhy/jsoup/issues/632>
* In Whitelists, validate that a removed protocol exists before removing said protocol.
* Allow the Jsoup.Connect thread to be interrupted when reading the input stream; helps when reading from a long stream
of data that doesn't read timeout.
<https://github.com/jhy/jsoup/pull/712>
* Jsoup.Connect now uses a desktop user agent by default. Many developers were getting caught by not specifying the
user agent, and sending the default 'Java'. That causes many servers to return different content than what they would
to a desktop browser, and what the developer was expecting.
* Increased the default connect/read timeout in Jsoup.Connect to 30 seconds.
* Jsoup.Connect now detects if a header value is actually in UTF-8 vs the HTTP spec of ISO-8859, and converts
the header value appropriately. This improves compatibility with servers that are configured incorrectly.
* Bugfix: in Jsoup.Connect, URLs containing non-URL-safe characters were not encoded to URL safe correctly.
<https://github.com/jhy/jsoup/issues/706>
* Bugfix: a "SYSTEM" flag in doctype tags would be incorrectly removed.
<https://github.com/jhy/jsoup/issues/408>
* Bugfix: removing attributes from an Element with removeAttr() would cause a ConcurrentModificationException.
* Bugfix: the contents of Comment nodes were not returned by Element.data()
* Bugfix: if source checked out on Windows with git autocrlf=true, Entities.load would fail because of the \r char.
*** Release 1.10.1 [2016-Oct-23]
* New feature: added the option to preserve case for tags and/or attributes, with ParseSettings. By default, the HTML
parser will continue to normalize tag names and attribute names to lower case, and the XML parser will now preserve
case, according to the relevant spec. The CSS selectors for tags and attributes remain case insensitive, per the CSS
spec.
* Improved support for extended HTML entities, including supplemental characters and multiple character references.
Also reduced memory consumption of the entity tables.
<https://github.com/jhy/jsoup/issues/602>
<https://github.com/jhy/jsoup/issues/603>
* Added support for *|E wildcard namespace selectors.
<https://github.com/jhy/jsoup/pull/724>
* Added support for setting multiple connection headers at once with Connection.headers(Map)
<https://github.com/jhy/jsoup/pull/725>
* Added support for setting/overriding the response character set in Connection.Response, for cases where the charset
is not defined by the server, or is defined incorrectly.
<https://github.com/jhy/jsoup/issues/743>
* Improved performance of class selectors by reducing memory allocation and garbase collection.
<https://github.com/jhy/jsoup/pull/753>
* Improved performance of HTML output by reducing the creation of temporary attribute list iterators.
<https://github.com/jhy/jsoup/pull/755>
* Fixed an issue when converting to the W3CDom XML, where valid (but ugly) HTML attribute names containing characters
like '"' could not be converted into valid XML attribute names. These attribute names are now normalized if possible,
or not added to the XML DOM.
<https://github.com/jhy/jsoup/issues/721>
* Fixed an OOB exception when loading an empty-body URL and parsing with the XML parser.
<https://github.com/jhy/jsoup/issues/727>
* Fixed an issue where attribute names starting with a slash would be parsed incorrectly.
<https://github.com/jhy/jsoup/pull/748>
* Don't reuse charset encoders from OutputSettings, to make threadsafe.
<https://github.com/jhy/jsoup/issues/740>
* Fixed an issue in connections with a requestBody where a custom content-type header could be ignored.
<https://github.com/jhy/jsoup/issues/756>
*** Release 1.9.2 [2016-May-17]
* Fixed an issue where tag names that contained non-ascii characters but started with an ascii character
would cause the parser to get stuck in an infinite loop.
<https://github.com/jhy/jsoup/issues/704>
* In XML documents, detect the charset from the XML prolog - <?xml encoding="UTF-8"?>
<https://github.com/jhy/jsoup/issues/701>
* Fixed an issue where created XML documents would have an incorrect prolog.
<https://github.com/jhy/jsoup/issues/652>
* Fixed an issue where you could not use an attribute selector to find values containing unbalanced braces or
parentheses.
<https://github.com/jhy/jsoup/issues/611>
* Fixed an issue where namespaced tags (like <fb:comment>) would cause Element.cssSelector() to fail.
<https://github.com/jhy/jsoup/pull/677>
*** Release 1.9.1 [2016-Apr-16]
* Added support for HTTP and SOCKS request proxies, specifiable per connection.
<https://github.com/jhy/jsoup/pull/570>
* Added support for sending plain HTTP request bodies in POST and PUT requests, with Connection.requestBody(String).
* Added support in Jsoup.Connect for HEAD, OPTIONS, TRACE.
<https://github.com/jhy/jsoup/issues/613>
* Added support for HTTP 307 Temporary Redirect (replays posts, if applicable).
<https://github.com/jhy/jsoup/pull/666>
* Performance improvements when parsing HTML, particularly for Android Dalvik.
* Added support for writing HTML into Appendable objects (like OutputStreamWriter), to enable stream serialization.
<https://github.com/jhy/jsoup/pull/470/>
* Added support for XML namespaces when converting jsoup documents to W3C documents.
<https://github.com/jhy/jsoup/pull/672>
* Added support for UTF-16 and UTF-32 character set detection from byte-order-marks (BOM).
<https://github.com/jhy/jsoup/issues/695>
* Added support for tags with non-ascii (unicode) letters.
<https://github.com/jhy/jsoup/issues/667>
* Added Connection.data(key) to retrieve a data KeyVal by its key. Useful to update form data before submission.
* Fixed an issue in the Parent selector where it would not match against the root element it was applied to.
<https://github.com/jhy/jsoup/pull/619>
* Fix an issue where elements.select(query) would not return every matching element if they had the same content.
<https://github.com/jhy/jsoup/issues/614>
* Added not-null validators to Element.appendText() and Element.prependText()
<https://github.com/jhy/jsoup/issues/690>
* Fixed an issue when moving moving nodes using Element.insert(index, children) where the sibling index would be set
incorrectly, leading to the original loads being lost.
<https://github.com/jhy/jsoup/issues/689>
* Reverted Node.equals() and Node.hashCode() back to identity (object) comparisons, as deep content inspection
had negative performance impacts and hashkey stability problems. Functionality replaced with Node.hasSameContent().
<https://github.com/jhy/jsoup/issues/688>
* In Jsoup.Connect, if the same header key is seen multiple times, combine their values with a comma per the HTTP RFC,
instead of keeping just one value. Also fixes an issue where header values could be out of order.
<https://github.com/jhy/jsoup/issues/618>
*** Release 1.8.3 [2015-Aug-02]
* Added support for custom boolean attributes.
<https://github.com/jhy/jsoup/pull/555>
* When fetching XML URLs, automatically switch to the XML parser instead of the HTML parser.
<https://github.com/jhy/jsoup/pull/574>
* Performance improvement on parsing larger HTML pages. On Android KitKat, around 1.7x times faster. On Android
Lollipop, ~ 1.3x faster. Improvements largely from re-ordering the HtmlTreeBuilder methods based on analysis of
various websites; also from further memory reduction for nodes with no children, and other tweaks.
* Fixed an issue in Element.getElementSiblingIndex (and related methods) where sibling elements with the same content
would incorrectly have the same sibling index.
<https://github.com/jhy/jsoup/issues/554>
* Fixed an issue where unexpected elements in a badly nested table could be moved to the wrong location in the
document.
<https://github.com/jhy/jsoup/issues/552>
* Fixed an issue where a table nested within a TH cell would parse to an incorrect tree.
<https://github.com/jhy/jsoup/issues/575>
* When serializing a document using the XHTML encoding entities, if the character set did not support chars
(such as Shift_JIS), the character would be skipped. For visibility, will now always output &xa0; when using XHTML
encoding entities (as is not defined), regardless of the output character set.
<https://github.com/jhy/jsoup/issues/523>
* Fixed an issue when resolving URLs, if the absolute URL had no path, the relative URL was not normalized correctly.
Also fixed an issue where connections that were redirected to a relative URL did not have the same normalization
rules as a URL read from Nodes.absUrl(String).
<https://github.com/jhy/jsoup/issues/585>
* When serialising XML, ensure that '<' characters in attributes are escaped, per spec. Not required in HTML.
<https://github.com/jhy/jsoup/issues/528>
*** Release 1.8.2 [2015-Apr-13]
* Performance improvements for parsing HTML on Android, of 1.5x to 1.9x, with larger parses getting a bigger
speed increase. For non-Android JREs, around 1.1x to 1.2x.
* Dramatic performance improvement in HTML serialization on Android (KitKat and later), of 115x. Improvement by working
around a character set encoding speed regression in Android.
<https://github.com/jhy/jsoup/issues/383>
* Performance improvement for the class name selector on Android (.class) of 2.5x to 14x. Around 1.2x
on non-Android JREs.
* File upload support. Added the ability to specify input streams for POST data, which will upload content in
MIME multipart/form-data encoding.
* Add a meta-charset element to documents when setting the character set, so that the document's charset is
unambiguous.
<https://github.com/jhy/jsoup/pull/486>
* Added ability to disable TLS (SSL) certificate validation. Helpful if you're hitting a host with a bad cert,
or your JDK doesn't support SNI.
<https://github.com/jhy/jsoup/pull/343>
* Added ability to further tweak the canned Cleaner Whitelists by removing existing settings.
<https://github.com/jhy/jsoup/pull/449>
* Added option in Cleaner Whitelist to allow linking to in-page anchors (#)
<https://github.com/jhy/jsoup/pull/441>
* Use a lowercase doctype tag for HTML5 documents.
* Add support for 201 Created with redirect, and other status codes. Treats any HTTP status code 2xx or 3xx as an OK
response, and follow redirects whenever there is a Location header.
<https://github.com/jhy/jsoup/issues/312>
* Added support for HTTP method verbs PUT, DELETE, and PATCH.
* Added support for overriding the default POST character of UTF-8
<https://github.com/jhy/jsoup/pull/491>
* W3C DOM support: added ability to convert from a jsoup document to a W3C document, with the W3Dom helper class.
* In the HtmlToPlainText example program, added the ability to filter using a CSS selector. Also clarified
the usage documentation.
* Fixed validation of cookie names in HttpConnection cookie methods.
<https://github.com/jhy/jsoup/pull/377>
* Fixed an issue where <option> tags would be missed when preparing a form for submission if missing a selected
attribute.
* Fixed an issue where submitting a form would incorrectly include radio and checkbox values without the checked
attribute.
* Fixed an issue where Element.classNames() would return a set containing an empty class; and may have extraneous
whitespace.
<https://github.com/jhy/jsoup/pull/469>
* Fixed an issue where attributes selected by value were not correctly space normalized.
<https://github.com/jhy/jsoup/pull/526>
* In head+noscript elements, treat content as character data, instead of jumping out of head parsing.
<https://github.com/jhy/jsoup/pull/540>
* Fixed performance issue when parsing HTML with elements with many children that need re-parenting.
<https://github.com/jhy/jsoup/pull/506>
* Fixed an issue where a server returning an unsupport character set response would cause a runtime
UnsupportedCharsetException, instead of falling back to the default UTF-8 charset.
<https://github.com/jhy/jsoup/pull/509>
* Fixed an issue where Jsoup.Connection would throw an IO Exception when reading a page with zero content-length.
<https://github.com/jhy/jsoup/issues/538>
* Improved the equals() and hashcode() methods in Node, to consider all their child content, for DOM tree comparisons.
<https://github.com/jhy/jsoup/issues/537>
* Improved performance in Selector when searching multiple roots.
<https://github.com/jhy/jsoup/issues/518>
*** Release 1.8.1 [2014-Sep-27]
* Introduced the ability to chose between HTML and XML output, and made HTML the default. This means img tags are
output as <img>, not <img />. XML is the default when using the XmlTreeBuilder. Control this with the
Document.OutputSettings.syntax() method.
* Improved the performance of Element.text() by 3.2x
* Improved the performance of Element.html() by 1.7x
* Improved file read time by 2x, giving around a 10% speed improvement to file parses.
<https://github.com/jhy/jsoup/issues/248>
* Tightened the scope of what characters are escaped in attributes and textnodes, to align with the spec. Also, when
using the extended escape entities map, only escape a character if the current output charset does not support it.
This produces smaller, more legible HTML, with greater control over the output (by setting charset and escape mode).
* If pretty-print is disabled, don't trim outer whitespace in Element.html()
<https://github.com/jhy/jsoup/issues/368>
* In the HTML Cleaner, allow span tags in the basic whitelist, and span and div tags in the relaxed whitelist.
* Added Element.cssSelector(), which returns a unique CSS selector/path for an element.
<https://github.com/jhy/jsoup/pull/459>
* Fixed an issue where <svg><img/></svg> was parsed as <svg><image/></svg>
<https://github.com/jhy/jsoup/issues/364>
* Fixed an issue where a UTF-8 BOM character was not detected if the HTTP response did not specify a charset, and
the HTML body did, leading to the head contents incorrectly being parsed into the body. Changed the behavior so that
when the UTF-8 BOM is detected, it will take precedence for determining the charset to decode with.
<https://github.com/jhy/jsoup/issues/348>
* Relaxed doctype validation, allowing doctypes to not specify a name.
<https://github.com/jhy/jsoup/issues/460>
* Fixed an issue in parsing a base URI when loading a URL containing a http-equiv element.
<https://github.com/jhy/jsoup/issues/440>
* Fixed an issue for Java 1.5 / Android 2.2 compatibility, and verify it doesn't regress.
<https://github.com/jhy/jsoup/issues/375>
<https://github.com/jhy/jsoup/pull/403>
* Fixed an issue that would throw an NPE when trying to set invalid HTML into a title element.
<https://github.com/jhy/jsoup/pull/410>
* Added support for quoted attribute values in CSS Selectors
<https://github.com/jhy/jsoup/pull/400>
* Fixed support for nth-of-type selectors with unknown tags.
<https://github.com/jhy/jsoup/pull/402>
* Added support for 'application/*+xml' mimetypes.
<https://github.com/jhy/jsoup/pull/444>
* Fixed support for allowing script tags in cleaner whitelists.
<https://github.com/jhy/jsoup/issues/299>
<https://github.com/jhy/jsoup/issues/388>
* In FormElements, don't submit disabled inputs, and use 'on' as checkbox value default.
<https://github.com/jhy/jsoup/issues/489>
*** Release 1.7.3 [2013-Nov-10]
* Introduced FormElement, providing easy access to form controls and their data, and the ability to submit forms
with Jsoup.Connect.
* Reduced GC impact during HTML parsing, with 17% fewer objects created, and 3% faster parses.
* Reduced CSS selection time by 26% for common queries.
* Improved HTTP character set detection.
<https://github.com/jhy/jsoup/pull/325> <https://github.com/jhy/jsoup/issues/321>
* Added Document.location, to get the URL the document was retrieved from. Helpful if connection was redirected.
<https://github.com/jhy/jsoup/pull/306>
* Fixed support for self-closing script tags.
<https://github.com/jhy/jsoup/issues/305>
* Fixed a crash when reading an unterminated CDATA section.
<https://github.com/jhy/jsoup/issues/349>
* Fixed an issue where elements added via the adoption agency algorithm did not preserve their attributes.
<https://github.com/jhy/jsoup/issues/313>
* Fixed an issue when cloning a document with extremely nested elements that could cause a stack-overflow.
<https://github.com/jhy/jsoup/issues/290>
* Fixed an issue when connecting or redirecting to a URL that contains a space.
<https://github.com/jhy/jsoup/pull/354> <https://github.com/jhy/jsoup/issues/114>
* Added support for the HTTP/1.1 Temporary Redirect (307) status code.
<https://github.com/jhy/jsoup/issues/452>
*** Release 1.7.2 [2013-Jan-27]
* Added support for supplementary characters outside of the Basic Multilingual Plane.
<https://github.com/jhy/jsoup/issues/288> <https://github.com/jhy/jsoup/pull/289>
* Added support for structural pseudo CSS selectors, including :first-child, :last-child, :nth-child, :nth-last-child,
:first-of-type, :last-of-type, :nth-of-type, :nth-last-of-type, :only-child, :only-of-type, :empty, and :root
<https://github.com/jhy/jsoup/pull/208>
* Added a maximum body response size to Jsoup.Connection, to prevent running out of memory when trying to read
extremely large documents. The default is 1MB.
* Refactored the Cleaner to traverse rather than recurse child nodes, to avoid the risk of overflowing the stack.
<https://github.com/jhy/jsoup/issues/246>
* Added Element.insertChildren(), to easily insert a list of child nodes at a specific index.
<https://github.com/jhy/jsoup/issues/239>
* Added Node.childNodesCopy(), to create an independent copy of a Node's children.
* When parsing in XML mode, preserve XML declarations (<?xml ... ?>).
<https://github.com/jhy/jsoup/issues/242>
* Introduced Parser.parseXmlFragment(), to allow easy parsing of XML fragments.
<https://github.com/jhy/jsoup/issues/279>
* Allow Whitelist test methods to be extended
<https://github.com/jhy/jsoup/issues/85>
* Added Document.OutputSettings.outline mode, to aid HTML debugging by printing out in outline mode, similar to
browser HTML inspectors.
<https://github.com/jhy/jsoup/issues/273>
* When parsing, allow all tags to self-close. Tags that aren't expected to self-close will get an end tag.
<https://github.com/jhy/jsoup/issues/258>
* Fixed an issue when parsing <textarea>/RCData tags containing unescaped closing tags that would drop the traling >.
* Corrected the javadoc for Element#child() to note that it throws IndexOutOfBounds.
<https://github.com/jhy/jsoup/issues/277>
* When cloning an Element, reset the classnames set so as not to hold a pointer to the source's.
<https://github.com/jhy/jsoup/issues/278>
* Limit how far up the stack the formatting adoption agency algorithm will travel, to prevent the chance of a run-away
parse when the HTML stack is hopelessly deep.
<https://github.com/jhy/jsoup/issues/234>
* Modified Element.text() to build text by traversing child nodes rather than recursing. This avoids stack-overflow
errors when the DOM is very deep and the VM stack-size is low.
<https://github.com/jhy/jsoup/issues/271>
*** Release 1.7.1 [2012-Sep-23]
* Improved parse time, now 2.3x faster than previous release, with lower memory consumption.
* Reduced memory consumption when selecting elements.
* Introduced finer granularity of exceptions in Jsoup.connect, including HttpStatusException and
UnsupportedMimeTypeException.
<https://github.com/jhy/jsoup/issues/229>
* Fixed an issue when determining the Windows-1254 character-set from a meta tag when run in the Turkish locale.
<https://github.com/jhy/jsoup/issues/191>
* Fixed whitespace preservation in <textarea> tags.
<https://github.com/jhy/jsoup/issues/167>
* In jsoup.connect, fail faster if the return content type is not supported.
<https://github.com/jhy/jsoup/issues/153>
* In jsoup.clean, allow custom OutputSettings, to control pretty printing, character set, and entity escaping.
<https://github.com/jhy/jsoup/issues/148>
* Fixed an issue that prevented frameset documents to be cleaned by the Cleaner.
<https://github.com/jhy/jsoup/issues/154>
* Fixed an issue when normalising whitespace for strings containing high-surrogate characters.
<https://github.com/jhy/jsoup/issues/214>
* If a server doesn't specify a content-type header, treat that as OK.
<https://github.com/jhy/jsoup/issues/213>
* If a server returns an unsupported character-set header, attempt to decode the content with the default charset
(UTF8), instead of bailing with an unsupported charset exception.
<https://github.com/jhy/jsoup/issues/215>
* Removed an unnecessary synchronisation in Tag.valueOf, allowing multi-threaded parsing to run faster.
<https://github.com/jhy/jsoup/issues/238>
* Made entity decoding less greedy, so that non-entities are less likely to be incorrectly treated as entities.
<https://github.com/jhy/jsoup/issues/224>
* Whitespace normalise document.title() output.
<https://github.com/jhy/jsoup/issues/168>
* In Jsoup.connection, enforce a connection disconnect after every connect. This precludes keep-alive connections to
the same host, but in practise many implementations will leak connections, particularly on error.
*** Release 1.6.3 [2012-May-28]
* Fixed parsing of group-or commas in CSS selectors, to correctly handle sub-queries containing commas.
<https://github.com/jhy/jsoup/issues/179>
* If a node has no parent, return null on previousSibling and nextSibling instead of throwing a null pointer exception.
<https://github.com/jhy/jsoup/issues/184>
* Updated Node.siblingNodes() and Element.siblingElements() to exclude the current node (a node is not its own sibling).
* Fixed HTML entity parser to correctly parse entities like frac14 (letter + number combo).
<https://github.com/jhy/jsoup/issues/145>
* Fixed issue where contents of a script tag within a comment could be incorrectly parsed.
<https://github.com/jhy/jsoup/issues/115>
* Fixed GAE support: load HTML entities from a file on startup, instead of embedding in the class.
* Fixed NPE when HTML fragment parsing a <style> tag
<https://github.com/jhy/jsoup/issues/189>
* Fixed issue with :all pseudo-tag in HTML sanitizer when cleaning tags previously defined in whitelist
<https://github.com/jhy/jsoup/issues/156>
* Fixed NPE in Parser.parseFragment() when context parameter is null.
<https://github.com/jhy/jsoup/issues/195>
* In HTML whitelists, when defining allowed attributes for a tag, automatically add the tag to the allowed list.
*** Release 1.6.2 [2012-Mar-27]
* Added a simplified XML parsing mode, which can usefully parse valid and invalid XML, but does not enforce any HTML
document structure or special tag behaviour.
* Added the optional ability to track errors when tokenising and parsing.
* Added jsoup.connect.cookies(Map) method, to set multiple cookies at once, possibly from a prior request.
* Added Element.textNodes() and Element.dataNodes(), to easily access an element's children text nodes and data nodes.
* Added an example program that demonstrates how to format HTML as plain-text, and the use of the NodeVisitor interface.
* Added Node.traverse() and Elements.traverse() methods, to iterate through a node's descendants.
* Updated jsoup.connect so that when requests made as POSTs are redirected, the redirect is followed as a GET.
<https://github.com/jhy/jsoup/issues/120>
* Updated the Cleaner and whitelists to optionally preserve related links in elements, instead of converting them
to absolute links.
* Updated the Cleaner to support custom allowed protocols such as "cid:" and "data:".
<https://github.com/jhy/jsoup/issues/127>
* Updated handling of <base href> tags, to act on only the first one seen when parsing, to align with modern browsers.
* Updated Node.setBaseUri(), to recursively set on all the node's descendants.
* Fixed handling of null characters within comments.
<https://github.com/jhy/jsoup/issues/121>
* Tweaked escaped entity detection in attributes to not treat &entity_... as an entity form.
<https://github.com/jhy/jsoup/issues/129>
* Fixed doctype tokeniser to allow whitespace between name and public identifier.
* Fixed issue where comments within a table tag would be duplicate-fostered into body.
<https://github.com/jhy/jsoup/pull/165>
* Fixed an issue where a spurious byte-order-mark at the start of a document would cause the parser to miss head
contents.
<https://github.com/jhy/jsoup/issues/134>
* Fixed an issue where content after a frameset could cause a NPE crash. Now correctly implements spec and ignores
the trailing content.
<https://github.com/jhy/jsoup/issues/162>
* Tweaked whitespace checks to align with HTML spec
<https://github.com/jhy/jsoup/pull/175>
* Tweaked HTML output of closing script and style tags to not add an extraneous newline when pretty-printing.
* Substantially reduced default memory allocation within Node.outerHtml, to reduce memory pressure when serialising
smaller DOMs.
<https://github.com/jhy/jsoup/issues/143>
*** Release 1.6.1 [2011-Jul-02]
* Fixed Java 1.5 compatibility.
<https://github.com/jhy/jsoup/issues/103>
* Fixed an issue when parsing <script> tags in body where the tokeniser wouldn't switch to the InScript state, which
meant that data wasn't parsed correctly.
<https://github.com/jhy/jsoup/issues/104>
* Fixed an issue with a missing quote when serialising DocumentType nodes.
<https://github.com/jhy/jsoup/issues/109>
* Fixed issue where a single 0 character was lexed incorrectly as a null character.
<https://github.com/jhy/jsoup/issues/107>
* Fixed normalisation of carriage returns to newlines on input HTML.
<https://github.com/jhy/jsoup/issues/110>
* Disabled memory mapped files when loading files from disk, to improve compatibility in Windows environments.
*** Release 1.6.0 [2011-Jun-13]
* HTML5 conformant parser. Complete reimplementation of HTML tokenisation and parsing, to implement the
http://whatwg.org/html spec. This ensures jsoup parses HTML identically to current modern browsers.
* When parsing files from disk, files are loaded via memory mapping, to increase parse speed.
* Reduced memory overhead and lowered garbage collector pressure with Attribute, Node and Element model optimisations.
* Improved "abs:" absolute URL handling in Elements.attr("abs:href") and Node.hasAttr("abs:href").
<https://github.com/jhy/jsoup/issues/97>