facturx 0.2.0 → 1.0.0

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 (47) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -3
  3. data/README.md +40 -8
  4. data/lib/facturx/builders/association.rb +8 -0
  5. data/lib/facturx/builders/base.rb +129 -0
  6. data/lib/facturx/builders/schema.rb +112 -0
  7. data/lib/facturx/builders.rb +25 -0
  8. data/lib/facturx/conformance.rb +163 -0
  9. data/lib/facturx/error.rb +3 -0
  10. data/lib/facturx/format.rb +85 -0
  11. data/lib/facturx/generate.rb +21 -0
  12. data/lib/facturx/profile_resolver.rb +40 -0
  13. data/lib/facturx/reader/semantic_mapper/line_mapping.rb +1 -1
  14. data/lib/facturx/reader/semantic_mapper/line_references.rb +19 -0
  15. data/lib/facturx/reader/semantic_mapper/payment_mapping.rb +48 -11
  16. data/lib/facturx/reader/semantic_mapper.rb +9 -0
  17. data/lib/facturx/reader/term_reader.rb +12 -4
  18. data/lib/facturx/reader.rb +3 -7
  19. data/lib/facturx/version.rb +1 -1
  20. data/lib/facturx/writer/context.rb +53 -0
  21. data/lib/facturx/writer/stage.rb +47 -0
  22. data/lib/facturx/writer/stage_support/contact_details.rb +57 -0
  23. data/lib/facturx/writer/stage_support/emission.rb +78 -0
  24. data/lib/facturx/writer/stage_support/identifiers.rb +129 -0
  25. data/lib/facturx/writer/stage_support/structure.rb +88 -0
  26. data/lib/facturx/writer/stages/document_context.rb +31 -0
  27. data/lib/facturx/writer/stages/exchanged_document.rb +32 -0
  28. data/lib/facturx/writer/stages/trade_agreement/parties.rb +105 -0
  29. data/lib/facturx/writer/stages/trade_agreement/references.rb +92 -0
  30. data/lib/facturx/writer/stages/trade_agreement.rb +45 -0
  31. data/lib/facturx/writer/stages/trade_delivery.rb +77 -0
  32. data/lib/facturx/writer/stages/trade_lines/agreement.rb +92 -0
  33. data/lib/facturx/writer/stages/trade_lines/product.rb +78 -0
  34. data/lib/facturx/writer/stages/trade_lines/quantity.rb +17 -0
  35. data/lib/facturx/writer/stages/trade_lines/settlement.rb +89 -0
  36. data/lib/facturx/writer/stages/trade_lines.rb +67 -0
  37. data/lib/facturx/writer/stages/trade_settlement/parties.rb +33 -0
  38. data/lib/facturx/writer/stages/trade_settlement/payment.rb +97 -0
  39. data/lib/facturx/writer/stages/trade_settlement/summary.rb +88 -0
  40. data/lib/facturx/writer/stages/trade_settlement/taxes.rb +121 -0
  41. data/lib/facturx/writer/stages/trade_settlement.rb +70 -0
  42. data/lib/facturx/writer.rb +68 -0
  43. data/lib/facturx/xml/namespaces.rb +19 -0
  44. data/lib/facturx/xml/profile_detector.rb +2 -4
  45. data/lib/facturx.rb +28 -0
  46. data/rbi/facturx.rbi +1090 -0
  47. metadata +38 -4
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: facturx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - AdVitam
@@ -43,8 +43,8 @@ dependencies:
43
43
  - - "<"
44
44
  - !ruby/object:Gem::Version
45
45
  version: '3'
46
- description: Ruby toolkit for reading and validating Factur-X XML and composing or
47
- extracting PDF/A-3 invoices.
46
+ description: Ruby toolkit for building, reading, and validating Factur-X XML and composing
47
+ or extracting PDF/A-3 invoices.
48
48
  email:
49
49
  - tech@advitam.fr
50
50
  executables: []
@@ -57,6 +57,10 @@ files:
57
57
  - README.md
58
58
  - lib/facturx.rb
59
59
  - lib/facturx/attach.rb
60
+ - lib/facturx/builders.rb
61
+ - lib/facturx/builders/association.rb
62
+ - lib/facturx/builders/base.rb
63
+ - lib/facturx/builders/schema.rb
60
64
  - lib/facturx/coerce.rb
61
65
  - lib/facturx/composers/ghostscript.rb
62
66
  - lib/facturx/composers/ghostscript/defaults.rb
@@ -64,10 +68,13 @@ files:
64
68
  - lib/facturx/composers/ghostscript/output_capture.rb
65
69
  - lib/facturx/composers/ghostscript/runner.rb
66
70
  - lib/facturx/composers/ghostscript/version_probe.rb
71
+ - lib/facturx/conformance.rb
67
72
  - lib/facturx/diagnostic.rb
68
73
  - lib/facturx/document.rb
69
74
  - lib/facturx/embedding.rb
70
75
  - lib/facturx/error.rb
76
+ - lib/facturx/format.rb
77
+ - lib/facturx/generate.rb
71
78
  - lib/facturx/group.rb
72
79
  - lib/facturx/model.rb
73
80
  - lib/facturx/model/common.rb
@@ -83,6 +90,7 @@ files:
83
90
  - lib/facturx/pdf/name_tree.rb
84
91
  - lib/facturx/pdf/verifier.rb
85
92
  - lib/facturx/profile.rb
93
+ - lib/facturx/profile_resolver.rb
86
94
  - lib/facturx/profiles.rb
87
95
  - lib/facturx/reader.rb
88
96
  - lib/facturx/reader/semantic_mapper.rb
@@ -90,6 +98,7 @@ files:
90
98
  - lib/facturx/reader/semantic_mapper/document_mapping.rb
91
99
  - lib/facturx/reader/semantic_mapper/helpers.rb
92
100
  - lib/facturx/reader/semantic_mapper/line_mapping.rb
101
+ - lib/facturx/reader/semantic_mapper/line_references.rb
93
102
  - lib/facturx/reader/semantic_mapper/party_mapping.rb
94
103
  - lib/facturx/reader/semantic_mapper/payment_mapping.rb
95
104
  - lib/facturx/reader/semantic_mapper/trade_mapping.rb
@@ -137,10 +146,35 @@ files:
137
146
  - lib/facturx/terms/declarations/totals.rb
138
147
  - lib/facturx/terms/reference.rb
139
148
  - lib/facturx/version.rb
149
+ - lib/facturx/writer.rb
150
+ - lib/facturx/writer/context.rb
151
+ - lib/facturx/writer/stage.rb
152
+ - lib/facturx/writer/stage_support/contact_details.rb
153
+ - lib/facturx/writer/stage_support/emission.rb
154
+ - lib/facturx/writer/stage_support/identifiers.rb
155
+ - lib/facturx/writer/stage_support/structure.rb
156
+ - lib/facturx/writer/stages/document_context.rb
157
+ - lib/facturx/writer/stages/exchanged_document.rb
158
+ - lib/facturx/writer/stages/trade_agreement.rb
159
+ - lib/facturx/writer/stages/trade_agreement/parties.rb
160
+ - lib/facturx/writer/stages/trade_agreement/references.rb
161
+ - lib/facturx/writer/stages/trade_delivery.rb
162
+ - lib/facturx/writer/stages/trade_lines.rb
163
+ - lib/facturx/writer/stages/trade_lines/agreement.rb
164
+ - lib/facturx/writer/stages/trade_lines/product.rb
165
+ - lib/facturx/writer/stages/trade_lines/quantity.rb
166
+ - lib/facturx/writer/stages/trade_lines/settlement.rb
167
+ - lib/facturx/writer/stages/trade_settlement.rb
168
+ - lib/facturx/writer/stages/trade_settlement/parties.rb
169
+ - lib/facturx/writer/stages/trade_settlement/payment.rb
170
+ - lib/facturx/writer/stages/trade_settlement/summary.rb
171
+ - lib/facturx/writer/stages/trade_settlement/taxes.rb
172
+ - lib/facturx/xml/namespaces.rb
140
173
  - lib/facturx/xml/parser.rb
141
174
  - lib/facturx/xml/profile_detector.rb
142
175
  - lib/facturx/xml/schema_validator.rb
143
176
  - lib/facturx/xml/verifier.rb
177
+ - rbi/facturx.rbi
144
178
  homepage: https://github.com/AdVitam/facturx
145
179
  licenses:
146
180
  - MIT
@@ -167,5 +201,5 @@ required_rubygems_version: !ruby/object:Gem::Requirement
167
201
  requirements: []
168
202
  rubygems_version: 4.0.16
169
203
  specification_version: 4
170
- summary: Read, validate, compose, and extract Factur-X invoices
204
+ summary: Build, read, validate, compose, and extract Factur-X invoices
171
205
  test_files: []