Class DocTypeHandler

java.lang.Object
org.ofdrw.archive.convert.handler.DocTypeHandler
All Implemented Interfaces:
ArchiveHandler

public class DocTypeHandler extends Object implements ArchiveHandler
处理器 1:设置 DocType = "OFD-A"(GB/T 42133-2022 6.2.1a)

将 OFD.xml 根节点的 DocType 属性修改为 "OFD-A"。

Since:
2.4.0
Author:
权观宇
  • Constructor Details

    • DocTypeHandler

      public DocTypeHandler()
  • Method Details

    • handle

      public void handle(OFDReader reader, org.ofdrw.pkg.container.OFDDir ofdDir) throws IOException
      Description copied from interface: ArchiveHandler
      执行去技术化转换操作,就地修改 OFD 容器

      处理结果直接写入 ofdDir,调用者负责最终持久化和打包。

      Specified by:
      handle in interface ArchiveHandler
      Parameters:
      reader - OFD 阅读器,提供文档结构访问
      ofdDir - OFD 虚拟容器,修改结果写入此处
      Throws:
      IOException - 文件操作异常