THPDFFacturXInvoiceInfo 记录
描述已加载文档中内嵌的 Factur-X 或 ZUGFeRD 发票:附件文件名、XMP 元数据值、配置文件标识符、MIME 类型,以及补充的 UBL 和 EDIFACT 表示文件名
声明
THPDFFacturXInvoiceInfo= record
FileName: AnsiString;
XMPDocumentFileName: AnsiString;
XMPNamespaceURI: AnsiString;
DocumentType: AnsiString;
Version: AnsiString;
ConformanceLevel: AnsiString;
GuidelineID: AnsiString;
AFRelationship: AnsiString;
AttachmentMimeType: AnsiString;
// Supplementary UBL representation file name ('factur-xubl.xml') when the
// document embeds a UBL view alongside the primary CII invoice per
// Factur-X 1.09 spec 6.4; empty when no UBL attachment is present. UBL is
// a supplementary representation, never the primary invoice XML
UBLFileName: AnsiString;
// Supplementary EDIFACT representation file name ('factur-xedifact.edi')
// when the document embeds an EDIFACT view alongside the primary CII
// invoice per Factur-X 1.09 spec 6.4; empty when no EDIFACT attachment is
// present. Like UBL it is a supplementary representation, never the
// primary invoice XML
EDIFACTFileName: AnsiString;
end;
单元
HPDFDoc
字段
| 字段 | 用途 |
|---|---|
FileName | 实际找到的内嵌发票附件名:可解析时为 XMP DocumentFileName,否则为 factur-x.xml、xrechnung.xml、zugferd-invoice.xml、ZUGFeRD-invoice.xml 之一 |
XMPDocumentFileName | 从文档 XMP 元数据读取的 fx:DocumentFileName 文本 |
XMPNamespaceURI | XMP 元数据中 DocumentFileName 元素的命名空间 URI |
DocumentType | XMP DocumentType 值;发票文档携带 INVOICE |
Version | Factur-X 配置文件的 XMP Version 值 |
ConformanceLevel | Factur-X 配置文件的 XMP ConformanceLevel 值 |
GuidelineID | 从内嵌 CII XML ExchangedDocumentContext 读取的指南标识符(URN) |
AFRelationship | 发票文件规格的 /AFRelationship 条目,例如 Data 或 Alternative |
AttachmentMimeType | 内嵌发票文件的 MIME 类型 |
UBLFileName | 内嵌补充 UBL 表示时的固定名称 factur-xubl.xml;否则为空 |
EDIFACTFileName | 内嵌补充 EDIFACT 表示时的固定名称 factur-xedifact.edi;否则为空 |
使用说明
- 由
THotPDF.DetectFacturXInvoice填充;字段为空表示对应元素不存在,false结果仍会保留部分元数据供诊断 UBLFileName和EDIFACTFileName只用于报告:它们命名的是补充表示,绝不是主发票 XML- 可将该记录配合
THotPDF.ExtractFacturXXML复用,或交给THotPDF.ValidateFacturXInvoice,后者填充自己的报告并把该记录嵌入Info