import { CIIBaseEncoder } from '../cii.encoder.js'; import type { TCreditNote, TDebitNote } from '../../../interfaces/common.js'; /** * Encoder for Factur-X invoice format */ export declare class FacturXEncoder extends CIIBaseEncoder { /** * Encodes a TCreditNote object into Factur-X XML * @param creditNote TCreditNote object to encode * @returns Factur-X XML string */ protected encodeCreditNote(creditNote: TCreditNote): Promise; /** * Encodes a TDebitNote object into Factur-X XML * @param debitNote TDebitNote object to encode * @returns Factur-X XML string */ protected encodeDebitNote(debitNote: TDebitNote): Promise; /** * Creates a base Factur-X XML document * @returns XML document with basic structure */ private createBaseXml; /** * Adds Factur-X profile information to the XML document * @param doc XML document */ private addProfile; /** * Sets the document type code in the XML document * @param doc XML document * @param typeCode Document type code (380 for invoice, 381 for credit note) */ private setDocumentTypeCode; /** * Adds common invoice data to the XML document * @param doc XML document * @param invoice Invoice data */ private addCommonInvoiceData; /** * Adds agreement section with seller and buyer information * @param doc XML document * @param transactionElement Transaction element * @param invoice Invoice data */ private addAgreementSection; /** * Adds party information to an element * @param doc XML document * @param partyElement Party element * @param party Party data */ private addPartyInfo; /** * Adds delivery section with delivery information * @param doc XML document * @param transactionElement Transaction element * @param invoice Invoice data */ private addDeliverySection; /** * Adds settlement section with payment terms and totals * @param doc XML document * @param transactionElement Transaction element * @param invoice Invoice data */ private addSettlementSection; /** * Adds line items to the XML document * @param doc XML document * @param transactionElement Transaction element * @param invoice Invoice data */ private addLineItems; /** * Formats a date as YYYYMMDD * @param timestamp Timestamp to format * @returns Formatted date string */ private formatDateYYYYMMDD; }