polyxml 0.23.2__tar.gz → 0.24.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. {polyxml-0.23.2 → polyxml-0.24.0}/Cargo.lock +35 -40
  2. {polyxml-0.23.2 → polyxml-0.24.0}/Cargo.toml +1 -1
  3. {polyxml-0.23.2 → polyxml-0.24.0}/PKG-INFO +26 -1
  4. {polyxml-0.23.2/crates/polyxml-python → polyxml-0.24.0}/README.md +25 -0
  5. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/README.md +15 -12
  6. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/java/mod.rs +8 -8
  7. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/mod.rs +3 -1
  8. polyxml-0.24.0/crates/polyxml-core/src/codegen/python/aot.rs +295 -0
  9. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/python/mod.rs +15 -2
  10. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/rust/mod.rs +260 -2
  11. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_csharp_codegen.rs +8 -0
  12. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_python_codegen.rs +153 -0
  13. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_rust_codegen.rs +2 -0
  14. {polyxml-0.23.2 → polyxml-0.24.0/crates/polyxml-python}/README.md +25 -0
  15. polyxml-0.24.0/crates/polyxml-python/benches/aot_vs_dataclass.py +188 -0
  16. {polyxml-0.23.2 → polyxml-0.24.0}/pyproject.toml +1 -1
  17. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/Cargo.toml +0 -0
  18. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/benches/core_benchmarks.rs +0 -0
  19. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/benches/support/tag_dispatch_fixtures.rs +0 -0
  20. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/benches/tag_dispatch.rs +0 -0
  21. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/cpp/mod.rs +0 -0
  22. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/csharp/mod.rs +0 -0
  23. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/go/mod.rs +0 -0
  24. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/java/codec.rs +0 -0
  25. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/java/models.rs +0 -0
  26. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/codegen/typescript/mod.rs +0 -0
  27. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/converters.rs +0 -0
  28. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/error.rs +0 -0
  29. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/ir/mod.rs +0 -0
  30. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/ir/tarjan.rs +0 -0
  31. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/json.rs +0 -0
  32. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/lib.rs +0 -0
  33. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/parser.rs +0 -0
  34. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/schema.rs +0 -0
  35. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/schema_parser/mod.rs +0 -0
  36. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/serializer.rs +0 -0
  37. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/transcoder.rs +0 -0
  38. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/src/value.rs +0 -0
  39. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_conformance.rs +0 -0
  40. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_core.rs +0 -0
  41. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_cpp_codegen.rs +0 -0
  42. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_go_codegen.rs +0 -0
  43. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_java_codegen.rs +0 -0
  44. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_json.rs +0 -0
  45. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_pattern_codegen.rs +0 -0
  46. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_rust_codecs.rs +0 -0
  47. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_schema_audit.rs +0 -0
  48. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_schema_ir.rs +0 -0
  49. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_security.rs +0 -0
  50. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_transcoder.rs +0 -0
  51. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_ts_codegen.rs +0 -0
  52. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-core/tests/test_xsi_type.rs +0 -0
  53. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/Cargo.toml +0 -0
  54. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/src/lib.rs +0 -0
  55. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/tests/test_conformance.py +0 -0
  56. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/tests/test_generated_models.py +0 -0
  57. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/tests/test_json.py +0 -0
  58. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/tests/test_polyxml.py +0 -0
  59. {polyxml-0.23.2 → polyxml-0.24.0}/crates/polyxml-python/tests/test_xsi_type.py +0 -0
  60. {polyxml-0.23.2 → polyxml-0.24.0}/python/polyxml/AGENT_GUIDE.md +0 -0
  61. {polyxml-0.23.2 → polyxml-0.24.0}/python/polyxml/__init__.py +0 -0
  62. {polyxml-0.23.2 → polyxml-0.24.0}/python/polyxml/compat/__init__.py +0 -0
  63. {polyxml-0.23.2 → polyxml-0.24.0}/python/polyxml/compat/xsdata.py +0 -0
  64. {polyxml-0.23.2 → polyxml-0.24.0}/python/polyxml/py.typed +0 -0
@@ -145,9 +145,9 @@ dependencies = [
145
145
 
146
146
  [[package]]
147
147
  name = "clap"
148
- version = "4.6.6"
148
+ version = "4.6.7"
149
149
  source = "registry+https://github.com/rust-lang/crates.io-index"
150
- checksum = "473c7e07f409a8d772161724aa8db6a765a2532a70f9667eeb7b49d3d02fbdca"
150
+ checksum = "aa8876b300ab35ba921adea3dfd70157a46249b33f95c9084ae5709785478946"
151
151
  dependencies = [
152
152
  "clap_builder",
153
153
  "clap_derive",
@@ -155,9 +155,9 @@ dependencies = [
155
155
 
156
156
  [[package]]
157
157
  name = "clap_builder"
158
- version = "4.6.6"
158
+ version = "4.6.7"
159
159
  source = "registry+https://github.com/rust-lang/crates.io-index"
160
- checksum = "7b48fea5a88e9ae728a2dcbedbfc0e730f7d60da42e1cb049a83c9fb8b789889"
160
+ checksum = "ec0797fb7aeb1406c84efac526901f7ec3ead2124f946b494e72879d4b54704d"
161
161
  dependencies = [
162
162
  "anstream",
163
163
  "anstyle",
@@ -167,9 +167,9 @@ dependencies = [
167
167
 
168
168
  [[package]]
169
169
  name = "clap_derive"
170
- version = "4.6.4"
170
+ version = "4.6.7"
171
171
  source = "registry+https://github.com/rust-lang/crates.io-index"
172
- checksum = "d012d2b9d65aca7f18f4d9878a045bc17899bba951561ba5ec3c2ba1eed9a061"
172
+ checksum = "f9c751b79415d4e559e3d1fcf128e09e720eb673a06d26cf6f392d37d75b66e0"
173
173
  dependencies = [
174
174
  "heck",
175
175
  "proc-macro2",
@@ -474,9 +474,9 @@ dependencies = [
474
474
 
475
475
  [[package]]
476
476
  name = "napi-build"
477
- version = "2.4.2"
477
+ version = "2.5.0"
478
478
  source = "registry+https://github.com/rust-lang/crates.io-index"
479
- checksum = "860e7c40864f95cfb83cde99f9ebadd88ef3d9bdccd7dd2cee0cc96a2dd4ffa7"
479
+ checksum = "0941983559cd62bfa7f04646a16428967a847365adeef27711e4e3927046bbed"
480
480
 
481
481
  [[package]]
482
482
  name = "napi-derive"
@@ -608,7 +608,7 @@ dependencies = [
608
608
 
609
609
  [[package]]
610
610
  name = "polyxml"
611
- version = "0.23.2"
611
+ version = "0.24.0"
612
612
  dependencies = [
613
613
  "criterion",
614
614
  "heck",
@@ -628,14 +628,14 @@ dependencies = [
628
628
 
629
629
  [[package]]
630
630
  name = "polyxml-c"
631
- version = "0.23.2"
631
+ version = "0.24.0"
632
632
  dependencies = [
633
633
  "polyxml",
634
634
  ]
635
635
 
636
636
  [[package]]
637
637
  name = "polyxml-cli"
638
- version = "0.23.2"
638
+ version = "0.24.0"
639
639
  dependencies = [
640
640
  "clap",
641
641
  "glob",
@@ -649,7 +649,7 @@ dependencies = [
649
649
 
650
650
  [[package]]
651
651
  name = "polyxml-js"
652
- version = "0.23.2"
652
+ version = "0.24.0"
653
653
  dependencies = [
654
654
  "napi",
655
655
  "napi-build",
@@ -659,7 +659,7 @@ dependencies = [
659
659
 
660
660
  [[package]]
661
661
  name = "polyxml-python"
662
- version = "0.23.2"
662
+ version = "0.24.0"
663
663
  dependencies = [
664
664
  "lexical-core",
665
665
  "polyxml",
@@ -669,7 +669,7 @@ dependencies = [
669
669
 
670
670
  [[package]]
671
671
  name = "polyxml-wasm"
672
- version = "0.23.2"
672
+ version = "0.24.0"
673
673
  dependencies = [
674
674
  "polyxml",
675
675
  "quick-xml",
@@ -891,11 +891,11 @@ dependencies = [
891
891
 
892
892
  [[package]]
893
893
  name = "serde_spanned"
894
- version = "0.6.9"
894
+ version = "1.1.1"
895
895
  source = "registry+https://github.com/rust-lang/crates.io-index"
896
- checksum = "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3"
896
+ checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26"
897
897
  dependencies = [
898
- "serde",
898
+ "serde_core",
899
899
  ]
900
900
 
901
901
  [[package]]
@@ -995,44 +995,42 @@ dependencies = [
995
995
 
996
996
  [[package]]
997
997
  name = "toml"
998
- version = "0.8.23"
998
+ version = "1.1.6+spec-1.1.0"
999
999
  source = "registry+https://github.com/rust-lang/crates.io-index"
1000
- checksum = "dc1beb996b9d83529a9e75c17a1686767d148d70663143c7854d8b4a09ced362"
1000
+ checksum = "920602543f0911ab71da12c50d59701da54c196d1a2bf5cb4b75667f137a406a"
1001
1001
  dependencies = [
1002
- "serde",
1002
+ "indexmap",
1003
+ "serde_core",
1003
1004
  "serde_spanned",
1004
1005
  "toml_datetime",
1005
- "toml_edit",
1006
+ "toml_parser",
1007
+ "toml_writer",
1008
+ "winnow",
1006
1009
  ]
1007
1010
 
1008
1011
  [[package]]
1009
1012
  name = "toml_datetime"
1010
- version = "0.6.11"
1013
+ version = "1.1.1+spec-1.1.0"
1011
1014
  source = "registry+https://github.com/rust-lang/crates.io-index"
1012
- checksum = "22cddaf88f4fbc13c51aebbf5f8eceb5c7c5a9da2ac40a13519eb5b0a0e8f11c"
1015
+ checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7"
1013
1016
  dependencies = [
1014
- "serde",
1017
+ "serde_core",
1015
1018
  ]
1016
1019
 
1017
1020
  [[package]]
1018
- name = "toml_edit"
1019
- version = "0.22.27"
1021
+ name = "toml_parser"
1022
+ version = "1.1.3+spec-1.1.0"
1020
1023
  source = "registry+https://github.com/rust-lang/crates.io-index"
1021
- checksum = "41fe8c660ae4257887cf66394862d21dbca4a6ddd26f04a3560410406a2f819a"
1024
+ checksum = "1d38ac1cf9b95face32296c0a3ede1fdc270627c9d9c02a7274dd6d960dc4d56"
1022
1025
  dependencies = [
1023
- "indexmap",
1024
- "serde",
1025
- "serde_spanned",
1026
- "toml_datetime",
1027
- "toml_write",
1028
1026
  "winnow",
1029
1027
  ]
1030
1028
 
1031
1029
  [[package]]
1032
- name = "toml_write"
1033
- version = "0.1.2"
1030
+ name = "toml_writer"
1031
+ version = "1.1.2+spec-1.1.0"
1034
1032
  source = "registry+https://github.com/rust-lang/crates.io-index"
1035
- checksum = "5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801"
1033
+ checksum = "7d56353a2a665ad0f41a421187180aab746c8c325620617ad883a99a1cbe66d2"
1036
1034
 
1037
1035
  [[package]]
1038
1036
  name = "unicode-ident"
@@ -1155,12 +1153,9 @@ dependencies = [
1155
1153
 
1156
1154
  [[package]]
1157
1155
  name = "winnow"
1158
- version = "0.7.15"
1156
+ version = "1.0.4"
1159
1157
  source = "registry+https://github.com/rust-lang/crates.io-index"
1160
- checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945"
1161
- dependencies = [
1162
- "memchr",
1163
- ]
1158
+ checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81"
1164
1159
 
1165
1160
  [[package]]
1166
1161
  name = "yansi"
@@ -3,7 +3,7 @@ resolver = "2"
3
3
  members = ["crates/polyxml-core", "crates/polyxml-python"]
4
4
 
5
5
  [workspace.package]
6
- version = "0.23.2"
6
+ version = "0.24.0"
7
7
  edition = "2021"
8
8
  rust-version = "1.80"
9
9
  license = "MIT"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: polyxml
3
- Version: 0.23.2
3
+ Version: 0.24.0
4
4
  Classifier: Development Status :: 4 - Beta
5
5
  Classifier: Intended Audience :: Developers
6
6
  Classifier: License :: OSI Approved :: MIT License
@@ -31,12 +31,35 @@ Project-URL: Homepage, https://github.com/polyxml/PolyXML
31
31
  Project-URL: Issues, https://github.com/polyxml/PolyXML/issues
32
32
  Project-URL: Repository, https://github.com/polyxml/PolyXML
33
33
 
34
+ <p align="center">
35
+ <a href="https://github.com/polyxml/PolyXML">
36
+ <img src="https://raw.githubusercontent.com/polyxml/PolyXML/main/docs/assets/brand/logo_polyxml_banner.png" alt="PolyXML" width="800">
37
+ </a>
38
+ </p>
39
+
34
40
  # PolyXML Python Bindings
35
41
 
42
+ <p align="center">
43
+ <a href="https://pypi.org/project/polyxml/"><img src="https://img.shields.io/pypi/v/polyxml.svg?logo=pypi&label=PyPI" alt="PyPI"></a>
44
+ <a href="https://www.python.org"><img src="https://img.shields.io/badge/Python-3.12%20%7C%203.13%20%7C%203.14%20%7C%203.15-3776AB.svg?logo=python&logoColor=white" alt="Python: 3.12+"></a>
45
+ <a href="https://polyxml.github.io/PolyXML/languages/python/"><img src="https://img.shields.io/badge/docs-zensical-blue.svg" alt="Documentation"></a>
46
+ <a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT"></a>
47
+ </p>
48
+
36
49
  High-performance native XML data-binding engine for Python dataclasses and Pydantic models.
37
50
 
38
51
  Powered by `polyxml-core` written in Rust and PyO3 (`abi3-py312`).
39
52
 
53
+ ---
54
+
55
+ ## Installation
56
+
57
+ ```bash
58
+ pip install polyxml
59
+ ```
60
+
61
+ ---
62
+
40
63
  ## Features
41
64
 
42
65
  - **⚡ Blazing Fast**: 16x faster deserialization and 38x faster serialization than standard Python tools.
@@ -44,6 +67,8 @@ Powered by `polyxml-core` written in Rust and PyO3 (`abi3-py312`).
44
67
  - **📦 Zero-GIL Binary Serialization**: Native `dumps_binary()` and `loads_binary()` using MessagePack (`msgspec`), up to 12.4x faster than pickle.
45
68
  - **🎯 Full Type Support**: Dataclasses and Pydantic v2 models with zero boilerplate.
46
69
 
70
+ ---
71
+
47
72
  ## Quickstart
48
73
 
49
74
  ```python
@@ -1,9 +1,32 @@
1
+ <p align="center">
2
+ <a href="https://github.com/polyxml/PolyXML">
3
+ <img src="https://raw.githubusercontent.com/polyxml/PolyXML/main/docs/assets/brand/logo_polyxml_banner.png" alt="PolyXML" width="800">
4
+ </a>
5
+ </p>
6
+
1
7
  # PolyXML Python Bindings
2
8
 
9
+ <p align="center">
10
+ <a href="https://pypi.org/project/polyxml/"><img src="https://img.shields.io/pypi/v/polyxml.svg?logo=pypi&label=PyPI" alt="PyPI"></a>
11
+ <a href="https://www.python.org"><img src="https://img.shields.io/badge/Python-3.12%20%7C%203.13%20%7C%203.14%20%7C%203.15-3776AB.svg?logo=python&logoColor=white" alt="Python: 3.12+"></a>
12
+ <a href="https://polyxml.github.io/PolyXML/languages/python/"><img src="https://img.shields.io/badge/docs-zensical-blue.svg" alt="Documentation"></a>
13
+ <a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT"></a>
14
+ </p>
15
+
3
16
  High-performance native XML data-binding engine for Python dataclasses and Pydantic models.
4
17
 
5
18
  Powered by `polyxml-core` written in Rust and PyO3 (`abi3-py312`).
6
19
 
20
+ ---
21
+
22
+ ## Installation
23
+
24
+ ```bash
25
+ pip install polyxml
26
+ ```
27
+
28
+ ---
29
+
7
30
  ## Features
8
31
 
9
32
  - **⚡ Blazing Fast**: 16x faster deserialization and 38x faster serialization than standard Python tools.
@@ -11,6 +34,8 @@ Powered by `polyxml-core` written in Rust and PyO3 (`abi3-py312`).
11
34
  - **📦 Zero-GIL Binary Serialization**: Native `dumps_binary()` and `loads_binary()` using MessagePack (`msgspec`), up to 12.4x faster than pickle.
12
35
  - **🎯 Full Type Support**: Dataclasses and Pydantic v2 models with zero boilerplate.
13
36
 
37
+ ---
38
+
14
39
  ## Quickstart
15
40
 
16
41
  ```python
@@ -1,8 +1,17 @@
1
+ <p align="center">
2
+ <a href="https://github.com/polyxml/PolyXML">
3
+ <img src="https://raw.githubusercontent.com/polyxml/PolyXML/main/docs/assets/brand/logo_polyxml_banner.png" alt="PolyXML" width="800">
4
+ </a>
5
+ </p>
6
+
1
7
  # polyxml
2
8
 
3
- [![Crates.io](https://img.shields.io/crates/v/polyxml.svg)](https://crates.io/crates/polyxml)
4
- [![Docs.rs](https://docs.rs/polyxml/badge.svg)](https://docs.rs/polyxml)
5
- [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/polyxml/PolyXML/blob/main/LICENSE)
9
+ <p align="center">
10
+ <a href="https://crates.io/crates/polyxml"><img src="https://img.shields.io/crates/v/polyxml.svg?logo=rust&label=crates.io" alt="Crates.io"></a>
11
+ <a href="https://docs.rs/polyxml"><img src="https://docs.rs/polyxml/badge.svg" alt="Docs.rs"></a>
12
+ <a href="https://polyxml.github.io/PolyXML/"><img src="https://img.shields.io/badge/docs-zensical-blue.svg" alt="Documentation"></a>
13
+ <a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT"></a>
14
+ </p>
6
15
 
7
16
  **PolyXML** is a high-performance streaming XML data-binding engine and polyglot schema compiler built in Rust. It serves as the foundational native core powering the `polyxml` CLI and language bindings across Python, C/C++, Java, TypeScript, Go, and C#.
8
17
 
@@ -14,7 +23,7 @@
14
23
  - **Pure-Rust XSD 1.0 & 1.1 Schema Parser**: Parses complex schemas with full support for includes, imports, redefines, choice groups, and restriction facets with zero C dependencies.
15
24
  - **Language-Agnostic Schema IR**: Normalizes XML Schema constructs into an actionable, unified Intermediate Representation (`SchemaIR`).
16
25
  - **Tarjan SCC Cycle Analysis**: Automatically breaks recursive and mutually cyclic type references with minimal cut points (`Box<T>`, pointers, `std::unique_ptr`, `z.lazy`).
17
- - **7-Target Code Generator**: Emits idiomatic models and streaming codecs for **Rust**, **Python** (dataclasses & Pydantic v2), **C++20**, **Java 21+**, **TypeScript 5+**, **Go 1.22+**, and **C# 12 / .NET 8+**.
26
+ - **7-Target Code Generator**: Emits idiomatic models and streaming codecs for **Rust**, **Python** (dataclasses & Pydantic v2), **C++20**, **Java 22+**, **TypeScript 5+**, **Go 1.22+**, and **C# 12 / .NET 8+**.
18
27
  - **Bidirectional Streaming Codecs**: Fast streaming deserialization and serialization with optional indentation formatting and namespace mapping.
19
28
  - **Security Hardened**: Built-in recursion depth limits protect against XML entity expansion and deeply nested denial-of-service (Billion Laughs) attacks.
20
29
  - **Zero Heavy Allocations**: Uses `smallvec` and slice lookups to minimize intermediate heap allocations.
@@ -23,19 +32,13 @@
23
32
 
24
33
  ## Installation
25
34
 
26
- Add `polyxml` to your `Cargo.toml`:
27
-
28
- ```toml
29
- [dependencies]
30
- polyxml = "0.1.0"
31
- ```
32
-
33
- Or run:
35
+ Add `polyxml` to your Rust project:
34
36
 
35
37
  ```bash
36
38
  cargo add polyxml
37
39
  ```
38
40
 
41
+
39
42
  ---
40
43
 
41
44
  ## Quickstart
@@ -18,7 +18,7 @@ use crate::ir::{
18
18
  /// Target backend for Java code emission.
19
19
  #[derive(Debug, Clone, Copy, PartialEq, Eq, Default, Serialize, Deserialize)]
20
20
  pub enum JavaBackend {
21
- /// Zero-dependency Java 21+ records (default).
21
+ /// Zero-dependency Java 22+ records (default).
22
22
  #[default]
23
23
  Standard,
24
24
  /// Jackson-annotated records for Spring Boot / enterprise JSON+XML binding.
@@ -39,14 +39,14 @@ impl JavaBackend {
39
39
  }
40
40
  }
41
41
 
42
- /// Options configuring Java 21+ code generation.
42
+ /// Options configuring Java 22+ code generation.
43
43
  #[derive(Debug, Clone, Serialize, Deserialize)]
44
44
  pub struct JavaOptions {
45
45
  /// Java package declaration for generated types (default: "generated.models")
46
46
  pub package_name: String,
47
47
  /// Target serialization backend (default: Standard / zero-dependency).
48
48
  pub backend: JavaBackend,
49
- /// Use Java 21 `record` instead of traditional classes (default: true)
49
+ /// Use Java 22 `record` instead of traditional classes (default: true)
50
50
  pub use_records: bool,
51
51
  /// Emit fluent builders for model types.
52
52
  #[serde(default)]
@@ -77,7 +77,7 @@ impl Default for JavaOptions {
77
77
  }
78
78
  }
79
79
 
80
- /// Language context adapter for Java 21+.
80
+ /// Language context adapter for Java 22+.
81
81
  pub struct JavaLanguageContext;
82
82
 
83
83
  impl LanguageContext for JavaLanguageContext {
@@ -226,7 +226,7 @@ pub fn to_java_enum_constant(name: &str) -> String {
226
226
  sanitize_keyword(&sanitized, "java")
227
227
  }
228
228
 
229
- /// Code generator producing Java 21+ records or mutable classes, choices, and enums.
229
+ /// Code generator producing Java 22+ records or mutable classes, choices, and enums.
230
230
  pub struct JavaCodegen {
231
231
  pub options: JavaOptions,
232
232
  pub context: JavaLanguageContext,
@@ -325,11 +325,11 @@ impl JavaCodegen {
325
325
  }
326
326
  out.push_str("// @generated by PolyXML Compiler (https://github.com/polyxml/PolyXML)\n");
327
327
  if !self.options.use_records {
328
- out.push_str("// Target: Java 21+ (Mutable JavaBeans)\n\n");
328
+ out.push_str("// Target: Java 22+ (Mutable JavaBeans)\n\n");
329
329
  } else if self.options.backend.is_jackson() {
330
- out.push_str("// Target: Java 21+ (Records, Jackson XML/JSON Annotations)\n\n");
330
+ out.push_str("// Target: Java 22+ (Records, Jackson XML/JSON Annotations)\n\n");
331
331
  } else {
332
- out.push_str("// Target: Java 21+ (Records, Sealed Interfaces, Pattern Matching)\n\n");
332
+ out.push_str("// Target: Java 22+ (Records, Sealed Interfaces, Pattern Matching)\n\n");
333
333
  }
334
334
 
335
335
  if !self.options.package_name.is_empty() {
@@ -18,7 +18,9 @@ pub use cpp::{CppBackend, CppCodegen, CppMode, CppOptions};
18
18
  pub use csharp::{CSharpCodegen, CSharpOptions, CSharpRecordKind};
19
19
  pub use go::{GoBackend, GoCodegen, GoOptions};
20
20
  pub use java::{JavaBackend, JavaCodegen, JavaOptions};
21
- pub use python::{PythonBackend, PythonCodegen, PythonOptions};
21
+ pub use python::{
22
+ PythonAotCodegen, PythonAotCrate, PythonAotOptions, PythonBackend, PythonCodegen, PythonOptions,
23
+ };
22
24
  pub use rust::{RustCodegen, RustOptions};
23
25
  pub use typescript::{TypeScriptBackend, TypeScriptCodegen, TypeScriptOptions};
24
26