Method AbstractEinvoice():toZugferd() Professional
Creates a ZUGFeRD XML document.
:toZugferd( [<cProfile>] ) --> cXml
A string with the ZUGFeRD XML document.
Serializes the invoice into a ZUGFeRD 2.x or Factur-X document in CII syntax. This XML document is intended to be embedded into a PDF/A-3 file to create a hybrid invoice.
Before the document is created, the method calls :validate() and performs the checks which are specific to the selected ZUGFeRD profile. If any errors remain, a runtime error is raised which lists all errors. Therefore, :validate() should be called first to determine whether the invoice can be serialized.
The warnings found during the checks can be retrieved via :getLastWarnings().
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.