Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add WP_XML_Tag_Processor and WP_XML_Processor #6713

Open
wants to merge 62 commits into
base: trunk
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
9e69192
XML Processor: First stab
adamziel Jun 3, 2024
00a63ae
Don't update state in parse_name();
adamziel Jun 3, 2024
c9f3450
Use NameCharacters to parse tag names
adamziel Jun 3, 2024
3f645db
Support CData and processing instructions
adamziel Jun 3, 2024
323d065
Support stack of open elements
adamziel Jun 3, 2024
63ae575
Support breadcrumbs
adamziel Jun 3, 2024
9558db1
implement 2.11 End-of-Line Handling
adamziel Jun 3, 2024
40df7a6
Clean up comments
adamziel Jun 3, 2024
6bbe94e
Only support UTF-8
adamziel Jun 3, 2024
087dc96
Uncomment more tests
adamziel Jun 3, 2024
91310c5
Uncomment more tests
adamziel Jun 3, 2024
ecb0347
Restrict what's accepted after the root element is closed
adamziel Jun 3, 2024
7ae34bf
formalize parsing prolog, element, and misc
adamziel Jun 3, 2024
28e91d8
Remove the concept of a comment type
adamziel Jun 3, 2024
a3b5e93
Remove COMMENT_AS_XML_COMMENT
adamziel Jun 3, 2024
7285cd0
Validate whether the root closer was found
adamziel Jun 3, 2024
a6958c9
Pause when root isn't closed
adamziel Jun 3, 2024
43149aa
Remove references to html spec
adamziel Jun 3, 2024
3df4a19
Class-level comment
adamziel Jun 3, 2024
6c15968
Document parsing_stage
adamziel Jun 3, 2024
13ba001
Support PCData
adamziel Jun 3, 2024
ae87c69
Decode attributes values
adamziel Jun 3, 2024
c96bc74
Document the class a bit more
adamziel Jun 3, 2024
00448b0
Support entity decoding
adamziel Jun 3, 2024
aef3baa
Document more and replace HTML tags with XML-lookalikes
adamziel Jun 3, 2024
e5f3d35
Add a step() function to decouple the high-level structure from low-l…
adamziel Jun 3, 2024
be70441
Refactor to separate the higher-order state even more
adamziel Jun 3, 2024
b6261f3
Port matches_breadcrumbs
adamziel Jun 3, 2024
4d43efc
Separate WP_XML_Processor from WP_XML_Tag_Processor
adamziel Jun 3, 2024
6274923
Unit test breadcrumbs query
adamziel Jun 3, 2024
c702221
Add get_inner_text() method
adamziel Jun 4, 2024
9baff6e
Test get_inner_text for cdata
adamziel Jun 4, 2024
5b723e6
Further document get_inner_text
adamziel Jun 4, 2024
e0219cf
Remove test.php
adamziel Jun 4, 2024
dc717e8
Update class-wp-html-decoder.php
adamziel Jun 4, 2024
88261c8
Update class-wp-html-decoder.php
adamziel Jun 4, 2024
e2716bf
Make inner text an integral part of PCData elements to enable streaming
adamziel Jun 4, 2024
2f42035
PHPCS
adamziel Jun 4, 2024
b420b8b
Clerikal updates
adamziel Jun 4, 2024
1d4026b
Only decode the five mandatory entities plus numeric references
adamziel Jun 4, 2024
d614bfd
Streaming improvements
adamziel Jun 4, 2024
dfe8489
Include WP_XML_Processor
adamziel Jun 4, 2024
04d167e
Remove ?> from HEREDOC as it derailed PHP7
adamziel Jun 4, 2024
c2d46a0
Stop using <<<XML syntax entirely
adamziel Jun 4, 2024
5a65ecc
Pause on incomplete attribute
adamziel Jun 4, 2024
8a96804
PHPCBF
adamziel Jun 4, 2024
dd9f580
Expect error notices
adamziel Jun 4, 2024
436c3cd
Declare setExpectedIncorrectUsage at the beginning of eadh test
adamziel Jun 4, 2024
5401798
Use @expectedDeprecated annotation
adamziel Jun 4, 2024
5b2f879
PHP CBF
adamziel Jun 4, 2024
91b2f57
Use `@expectedIncorrectUsage`
adamziel Jun 4, 2024
e5b7cac
Try to calm down phpunit _doing_it_wrong detection
adamziel Jun 4, 2024
faeac14
Move expectedIncorrectUsage up
adamziel Jun 4, 2024
d792a6a
Tweak PHPUnit setup
adamziel Jun 4, 2024
1274876
Don't short-circuit matching breadcrumbs in text nodes
adamziel Jun 4, 2024
9ad4b9a
PHPCS
adamziel Jun 4, 2024
8c7888c
Remove get_inner_text
adamziel Jun 4, 2024
f06b8f8
Make text nodes incomplete until the next tag is available, except in…
adamziel Jun 6, 2024
9922153
Move into separate XML directories.
dmsnell Jun 8, 2024
9917ef3
Much around with the XML decoder.
dmsnell Jun 8, 2024
a905009
Add link to XML spec in class package docs.
dmsnell Jun 8, 2024
3e7b817
More stewing on the decoder and name/attribute value parsers
dmsnell Jun 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading
Loading