import { PdfDocument } from './../pdf-document';
import { _XmlWriter } from './xml-writer';
import { _ExportHelper } from './xfdf-document';
/**
 * Provides XML document handling for importing and exporting PDF form fields with support for both
 * Acrobat-compatible and standard XML formats.
 *
 * @private
 */
export declare class _XmlDocument extends _ExportHelper {
    /**
     * Initializes a new instance of the _XmlDocument class with an optional file name.
     *
     * @private
     * @param {string} [fileName] Optional file name to associate with the XML document.
     * @returns {void}
     */
    constructor(fileName?: string);
    /**
     * Exports all annotations from the PDF document into a serialized byte array.
     *
     * @private
     * @throws {Error} Indicates that the method is not implemented.
     * @returns {Uint8Array} as annotation. // eslint-disable-line
     */
    _exportAnnotations(): Uint8Array;
    /**
     * Exports form fields from the PDF document and returns the serialized data.
     *
     * @private
     * @param {PdfDocument} document The PDF document to export form fields from.
     * @returns {Uint8Array} The exported form fields as a byte array.
     */
    _exportFormFields(document: PdfDocument): Uint8Array;
    /**
     * Saves the XML document and returns the serialized byte array.
     *
     * @private
     * @returns {Uint8Array} The saved XML document as a byte array.
     */
    _save(): Uint8Array;
    /**
     * Writes form field data to the XML writer honoring the specified format.
     *
     * @private
     * @param {_XmlWriter} writer The XML writer to write field data to.
     * @param {boolean} [isAcrobat=false] Whether to use Acrobat-compatible format with attributes.
     * @returns {void}
     */
    _writeFormFieldData(writer: _XmlWriter, isAcrobat?: boolean): void;
    /**
     * Imports form field data from an XML byte array into the PDF document.
     *
     * @private
     * @param {PdfDocument} document The PDF document to import form data into.
     * @param {Uint8Array} data The XML data containing form field values.
     * @returns {void}
     */
    _importFormData(document: PdfDocument, data: Uint8Array): void;
    /**
     * Parses form field data from the XML document root element.
     *
     * @private
     * @param {HTMLElement} root The root element of the XML document to parse.
     * @returns {void}
     */
    _parseFormData(root: HTMLElement): void;
    /**
     * Imports form field values into the PDF document's form fields using the internal table data.
     *
     * @private
     * @returns {void}
     */
    _importField(): void;
    /**
     * Validates the XML document for parsing errors.
     *
     * @private
     * @param {Document} xmlDocument The XML document to validate.
     * @returns {void}
     * @throws {Error} Throws an error if the XML document contains parser errors.
     */
    _checkXml(xmlDocument: Document): void;
}
