avrotize 2.18.2__py3-none-any.whl → 2.20.0__py3-none-any.whl

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 (39) hide show
  1. avrotize/_version.py +2 -2
  2. avrotize/avrotocsharp/project.csproj.jinja +7 -7
  3. avrotize/avrotocsharp/testproject.csproj.jinja +3 -3
  4. avrotize/avrotocsharp.py +21 -2
  5. avrotize/avrotojava/testproject.pom.jinja +4 -3
  6. avrotize/avrotojava.py +16 -6
  7. avrotize/avrotots/class_core.ts.jinja +12 -0
  8. avrotize/avrotots/class_test.ts.jinja +77 -0
  9. avrotize/avrotots.py +96 -0
  10. avrotize/cddltostructure.py +1841 -0
  11. avrotize/commands.json +226 -0
  12. avrotize/constants.py +71 -4
  13. avrotize/dependencies/cpp/vcpkg/vcpkg.json +19 -0
  14. avrotize/dependencies/cs/net90/dependencies.csproj +27 -0
  15. avrotize/dependencies/go/go121/go.mod +6 -0
  16. avrotize/dependencies/java/jdk21/pom.xml +91 -0
  17. avrotize/dependencies/python/py312/requirements.txt +13 -0
  18. avrotize/dependencies/rust/stable/Cargo.toml +17 -0
  19. avrotize/dependencies/typescript/node22/package.json +16 -0
  20. avrotize/dependency_version.py +432 -0
  21. avrotize/structuretocddl.py +597 -0
  22. avrotize/structuretocsharp/dataclass_core.jinja +6 -1
  23. avrotize/structuretocsharp/json_structure_converters.cs.jinja +399 -0
  24. avrotize/structuretocsharp/program.cs.jinja +11 -6
  25. avrotize/structuretocsharp/project.csproj.jinja +4 -3
  26. avrotize/structuretocsharp/testproject.csproj.jinja +4 -3
  27. avrotize/structuretocsharp.py +311 -21
  28. avrotize/structuretojava/choice_core.jinja +34 -0
  29. avrotize/structuretojava/class_core.jinja +23 -0
  30. avrotize/structuretojava/enum_core.jinja +18 -0
  31. avrotize/structuretojava/equals_hashcode.jinja +30 -0
  32. avrotize/structuretojava/pom.xml.jinja +26 -0
  33. avrotize/structuretojava/tuple_core.jinja +49 -0
  34. avrotize/structuretojava.py +853 -0
  35. {avrotize-2.18.2.dist-info → avrotize-2.20.0.dist-info}/METADATA +29 -2
  36. {avrotize-2.18.2.dist-info → avrotize-2.20.0.dist-info}/RECORD +39 -20
  37. {avrotize-2.18.2.dist-info → avrotize-2.20.0.dist-info}/WHEEL +0 -0
  38. {avrotize-2.18.2.dist-info → avrotize-2.20.0.dist-info}/entry_points.txt +0 -0
  39. {avrotize-2.18.2.dist-info → avrotize-2.20.0.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,49 @@
1
+ /** {{ docstring }} */
2
+ /** JSON Structure tuple type - serializes as JSON array */
3
+ {%- if deprecated %}
4
+ @Deprecated
5
+ {%- endif %}
6
+ {%- if jackson_annotation %}
7
+ @JsonFormat(shape = JsonFormat.Shape.ARRAY)
8
+ {%- endif %}
9
+ public class {{ class_name }} {
10
+ {%- for element in elements %}
11
+
12
+ /** {{ element.docstring }} */
13
+ private {{ element.type }} {{ element.name }};
14
+ {%- endfor %}
15
+
16
+ public {{ class_name }}() {}
17
+
18
+ public {{ class_name }}({% for element in elements %}{{ element.type }} {{ element.name }}{% if not loop.last %}, {% endif %}{% endfor %}) {
19
+ {%- for element in elements %}
20
+ this.{{ element.name }} = {{ element.name }};
21
+ {%- endfor %}
22
+ }
23
+
24
+ {%- for element in elements %}
25
+
26
+ public {{ element.type }} get{{ element.name|pascal }}() { return {{ element.name }}; }
27
+ public void set{{ element.name|pascal }}({{ element.type }} {{ element.name }}) { this.{{ element.name }} = {{ element.name }}; }
28
+ {%- endfor %}
29
+
30
+ {%- if jackson_annotation %}
31
+
32
+ @JsonCreator
33
+ public static {{ class_name }} fromArray(Object[] array) {
34
+ if (array == null || array.length != {{ elements|length }}) {
35
+ throw new IllegalArgumentException("Array must have exactly {{ elements|length }} elements");
36
+ }
37
+ {{ class_name }} tuple = new {{ class_name }}();
38
+ {%- for element in elements %}
39
+ tuple.{{ element.name }} = ({{ element.type }}) array[{{ loop.index0 }}];
40
+ {%- endfor %}
41
+ return tuple;
42
+ }
43
+
44
+ @JsonValue
45
+ public Object[] toArray() {
46
+ return new Object[] { {% for element in elements %}{{ element.name }}{% if not loop.last %}, {% endif %}{% endfor %} };
47
+ }
48
+ {%- endif %}
49
+ }