-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathpom.xml
More file actions
1159 lines (1071 loc) · 58.7 KB
/
Copy pathpom.xml
File metadata and controls
1159 lines (1071 loc) · 58.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.1.0 http://maven.apache.org/xsd/maven-4.1.0.xsd">
<modelVersion>4.1.0</modelVersion>
<groupId>io.github.easy4j</groupId>
<artifactId>easydoc</artifactId>
<name>${project.groupId}:${project.artifactId}</name>
<url>https://github.com/easy-4-java/${project.artifactId}</url>
<version>${revision}</version>
<description>Building doc documents based on xhtml templates using docx4j</description>
<packaging>pom</packaging>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
</license>
</licenses>
<scm>
<connection>scm:git:https://github.com/easy-4-java/easydoc.git</connection>
<developerConnection>scm:git:https://github.com/easy-4-java/easydoc.git</developerConnection>
<url>https://github.com/easy-4-java/easydoc</url>
<tag>${project.artifactId}</tag>
</scm>
<developers>
<developer>
<name>Loong Wan</name>
<email>hiwepy@gmail.com</email>
<url>https://github.com/loong10k</url>
<roles>
<role>developer</role>
</roles>
<timezone>+8</timezone>
</developer>
</developers>
<!-- 版本属性定义:Java 版本、依赖版本与 Maven 插件版本统一管理 -->
<properties>
<!-- ═══ 第一段: 基础属性(自然排序)═══ -->
<!-- CI-friendly 版本单一来源:发布/发版只改此一处,Maven 4 构建产物自动扁平化 -->
<revision>3.0.x.20261031-SNAPSHOT</revision>
<java.version>21</java.version>
<maven.compiler.release>${java.version}</maven.compiler.release>
<maven.version>4.0.0-rc-5</maven.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<!-- ═══ 第二段: docx4j 全家桶版本 ═══ -->
<!-- docx4j 核心 + JAXB + FOP + ImportXHTML 统一锁定在 17.0.x 系列 -->
<docx4j.version>17.0.3</docx4j.version>
<docx4j-export-fo.version>17.0.3</docx4j-export-fo.version>
<docx4j-importxhtml.version>17.0.2</docx4j-importxhtml.version>
<docx4j-jaxb.version>17.0.3</docx4j-jaxb.version>
<!-- 旧 openxml-objects 模型构件(docx4j 11.5.x 时代)的最终版本:
docx4j 17.0.x 已把模型构件改名为 docx4j-generated-objects,
但为兼容仍引用旧构件的第三方/历史依赖,这里显式锁定其最后版本 -->
<docx4j-openxml.version>11.5.14</docx4j-openxml.version>
<!-- EclipseLink MOXy(docx4j JAXB MOXy 后端的运行时依赖) -->
<persistence.version>2.7.6</persistence.version>
<!-- ═══ 第三段: Jakarta / JAXB / XML 相关 ═══ -->
<jakarta-activation.version>2.1.4</jakarta-activation.version>
<jakarta.servlet-api.version>6.0.0</jakarta.servlet-api.version>
<jaxb-impl.version>4.0.5</jaxb-impl.version>
<javax.mail-api.version>1.6.2</javax.mail-api.version>
<!-- ═══ 第四段: 模板引擎版本 ═══ -->
<beetl.version>3.21.2.RELEASE</beetl.version>
<freemarker.version>2.3.34</freemarker.version>
<httl.version>1.0.12</httl.version>
<jetbrick.version>2.1.10</jetbrick.version>
<rythm.version>1.4.2</rythm.version>
<thymeleaf.version>3.1.5.RELEASE</thymeleaf.version>
<velocity.version>2.4.1</velocity.version>
<velocity-tools.version>3.1</velocity-tools.version>
<webit-script.version>1.5.2</webit-script.version>
<!-- ═══ 第五段: 第三方基础库版本 ═══ -->
<antlr4.version>4.9.3</antlr4.version>
<commons-beanutils.version>1.11.0</commons-beanutils.version>
<commons-io.version>2.22.0</commons-io.version>
<commons-lang3.version>3.20.0</commons-lang3.version>
<commons-logging.version>1.3.6</commons-logging.version>
<!-- Markdown 解析(MD→HTML 渲染,Java 8 兼容) -->
<flexmark.version>0.64.8</flexmark.version>
<jackson-bom.version>3.2.1</jackson-bom.version>
<jsoup.version>1.23.1</jsoup.version>
<!-- fastjson:v1 兼容构建(内核 fastjson2),锁定 rythm-engine 传递依赖 -->
<fastjson.version>2.0.57</fastjson.version>
<ognl.version>3.4.2</ognl.version>
<tomcat-jasper.version>10.1.54</tomcat-jasper.version>
<!-- ═══ 第六段: 测试框架版本 ═══ -->
<!-- JUnit 4 已随 3.0.x 移除:存量 JUnit 4 用例均无 vintage 引擎支撑
(surefire 走 JUnit Platform,不加载 junit:junit),且每个模块
都有语义等价、断言更强的 JUnit Jupiter 用例(Hello/Coverage/
Variants/perf)。详见 refactor/p0-test 分支的删除提交说明 -->
<assertj.version>3.27.7</assertj.version>
<junit-jupiter.version>6.1.0</junit-jupiter.version>
<slf4j.version>2.0.18</slf4j.version>
<lombok.version>1.18.46</lombok.version>
<!-- ═══ 第七段: Maven 插件版本 ═══ -->
<maven-antrun-plugin.version>3.2.0</maven-antrun-plugin.version>
<!-- surefire 的 @{argLine} 晚绑定兜底默认值:无 jacoco(-Djacoco.skip=true)
且未在命令行传 -DargLine 时避免字面量 "@{argLine}" 混入 fork JVM 参数;
jacoco prepare-agent 执行时会以 agent 参数覆盖该工程属性 -->
<maven-assembly-plugin.version>3.8.0</maven-assembly-plugin.version>
<maven-central-publishing-plugin.version>0.11.0</maven-central-publishing-plugin.version>
<maven-clean-plugin.version>3.5.0</maven-clean-plugin.version>
<maven-compiler-plugin.version>3.15.0</maven-compiler-plugin.version>
<maven-dependency-plugin.version>3.11.0</maven-dependency-plugin.version>
<maven-deploy-plugin.version>3.1.4</maven-deploy-plugin.version>
<maven-enforcer-plugin.version>3.6.3</maven-enforcer-plugin.version>
<maven-gpg-plugin.version>3.2.8</maven-gpg-plugin.version>
<maven-install-plugin.version>3.1.4</maven-install-plugin.version>
<maven-jacoco-plugin.version>0.8.15</maven-jacoco-plugin.version>
<maven-jar-plugin.version>3.5.0</maven-jar-plugin.version>
<maven-javadoc-plugin.version>3.12.0</maven-javadoc-plugin.version>
<maven-nexus-staging-plugin.version>1.7.0</maven-nexus-staging-plugin.version>
<maven-release-plugin.version>3.3.1</maven-release-plugin.version>
<maven-resources-plugin.version>3.5.0</maven-resources-plugin.version>
<maven-source-plugin.version>3.4.0</maven-source-plugin.version>
<maven-surefire-plugin.version>3.5.6</maven-surefire-plugin.version>
<!-- 测试进程额外参数默认值(可被命令行 -DargLine=... 覆盖;
与 1.0.x / 2.0.x 分支的 @{argLine} 晚绑定风格保持一致,见审计 #30:
晚绑定才能在同一构建里正确吃到 jacoco prepare-agent 注入的
-javaagent 参数,${argLine} 早绑定会被 pom 构建期求值吞掉) -->
<argLine></argLine>
</properties>
<dependencyManagement>
<dependencies>
<!-- fastjson 2.x(v1 兼容构建,内核为 fastjson2):锁定 rythm-engine 传递依赖。
1.2.x 线已终止维护且存在无修复的 CVE-2026-16723(RCE 家族);
2.0.x 保持 com.alibaba.fastjson v1 包名与 API(rythm 硬编码依赖),
内部实现切换到 fastjson2 内核,彻底脱离受影响的 1.2.x 线 -->
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>fastjson</artifactId>
<version>${fastjson.version}</version>
</dependency>
<!-- ======== 测试框架 ======== -->
<!-- https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter -->
<!-- JUnit 6/Jupiter(聚合构件,包含 api + engine + params);
JUnit 4 已移除:无 vintage 引擎时 surefire(JUnit Platform)
本就不会执行任何 org.junit.Test 用例,保留 junit:junit 只会
伪装成"测试在跑" -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${junit-jupiter.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api -->
<!-- JUnit 5 API(编写测试用例的注解与断言) -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>${junit-jupiter.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.assertj/assertj-core -->
<!-- AssertJ(流式断言库,测试代码使用) -->
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<version>${assertj.version}</version>
</dependency>
<!-- jakarta.servlet-api / tomcat-jasper 已从全局 dependencyManagement 移除:
这两个 Servlet 构件只被 easydoc-jsp 使用,由该模块自行声明
(版本属性 ${jakarta.servlet-api.version} / ${tomcat-jasper.version}
仍由此处统一管理)。这样以本 pom 为 parent 的下游项目不会在它们的
dependencyManagement 里继承到 Servlet 相关条目;
旧 javax.servlet-api 已随 3.0.x 的 Jakarta 迁移(easydoc-core/
easydoc-xhtml 均无 servlet 引用)从全仓库移除 -->
<!-- ======== 日志 ======== -->
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-api -->
<!-- SLF4J 日志门面(所有模块统一日志接口) -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.slf4j/slf4j-simple -->
<!-- SLF4J 简单实现(test scope 日志绑定,避免测试时 NOP logger) -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>${slf4j.version}</version>
</dependency>
<!-- ======== Apache Commons ======== -->
<!-- https://mvnrepository.com/artifact/commons-beanutils/commons-beanutils -->
<!-- BeanUtils(JavaBean 属性拷贝与反射工具) -->
<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
<version>${commons-beanutils.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3 -->
<!-- Commons Lang3(字符串、Object、枚举等通用工具类) -->
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>${commons-lang3.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/commons-io/commons-io -->
<!-- Commons IO(IO 流工具类,文件复制/过滤等) -->
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>${commons-io.version}</version>
</dependency>
<!-- ======== HTML / CSS 解析 ======== -->
<!-- https://mvnrepository.com/artifact/org.jsoup/jsoup -->
<!-- Jsoup(HTML 解析与 DOM 操作,easydoc-xhtml 使用) -->
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>${jsoup.version}</version>
</dependency>
<!-- ======== Markdown 解析 ======== -->
<!-- https://mvnrepository.com/artifact/com.vladsch.flexmark/flexmark-all -->
<!-- flexmark 聚合构件(Markdown → HTML,含 GFM 表格/删除线/自动链接扩展,easydoc-xhtml 使用) -->
<dependency>
<groupId>com.vladsch.flexmark</groupId>
<artifactId>flexmark-all</artifactId>
<version>${flexmark.version}</version>
</dependency>
<!-- ======== docx4j 核心全家桶 ======== -->
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-core -->
<!-- docx4j 核心(Word/Excel/PPT 的 OOXML 读写引擎);
排除旧版日志桥接,由 SLF4J 2.x 统一管理 -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-core</artifactId>
<version>${docx4j.version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-export-fo -->
<!-- docx4j FOP 导出(PDF/HTML 渲染核心) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-export-fo</artifactId>
<version>${docx4j-export-fo.version}</version>
</dependency>
<!-- docx4j-export-fo fonts 子模块(11.5.3 起独立发布),
PDF/HTML 渲染需要的 Symbol/Cross-core/Cross-extra 字体集 -->
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-export-fo-fonts-symbol -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-export-fo-fonts-symbol</artifactId>
<version>${docx4j-export-fo.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-export-fo-fonts-croscore -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-export-fo-fonts-croscore</artifactId>
<version>${docx4j-export-fo.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-export-fo-fonts-crosextra -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-export-fo-fonts-crosextra</artifactId>
<version>${docx4j-export-fo.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-docx-anon -->
<!-- docx4j 匿名化工具(去除文档中的作者/修订信息) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-docx-anon</artifactId>
<version>${docx4j.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-diffx -->
<!-- docx4j DiffX(XML 文档差异比较) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-diffx</artifactId>
<version>${docx4j.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-ImportXHTML-core -->
<!-- docx4j ImportXHTML(XHTML 转 docx 的核心引擎) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-ImportXHTML-core</artifactId>
<version>${docx4j-importxhtml.version}</version>
</dependency>
<!-- openhtmltopdf(docx4j-ImportXHTML 的传递依赖,XHTML 解析核心):
全部 8 个构件统一锁定到 1.1.75(Maven Central 最新版)。
openhtmltopdf 在 JDK 解析器上 setProperty(ACCESS_EXTERNAL_DTD)
失败会打 SEVERE 警告:XXE 防护由 XHTMLImporterUtils.handle()
的 JAXP 系统属性兜底,与本版本无关 -->
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-core -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-core</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-pdfbox -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-pdfbox</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-objects -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-objects</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-latex-support -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-latex-support</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-slf4j -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-slf4j</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-rtl-support -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-rtl-support</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-mathml-support -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-mathml-support</artifactId>
<version>1.1.75</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.github.openhtmltopdf/openhtmltopdf-svg-support -->
<dependency>
<groupId>io.github.openhtmltopdf</groupId>
<artifactId>openhtmltopdf-svg-support</artifactId>
<version>1.1.75</version>
</dependency>
<!-- ======== JAXB 实现 ======== -->
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-JAXB-MOXy -->
<!-- docx4j JAXB MOXy 后端(EclipseLink 实现,JDK 21 + jakarta 4.x 已不可用) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-JAXB-MOXy</artifactId>
<version>${docx4j-jaxb.version}</version>
</dependency>
<!-- ======== EclipseLink(MOXy 运行时依赖) ======== -->
<!-- https://mvnrepository.com/artifact/org.eclipse.persistence/eclipselink -->
<!-- EclipseLink 核心(MOXy JAXB 实现的运行时依赖) -->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>eclipselink</artifactId>
<version>${persistence.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.eclipse.persistence/org.eclipse.persistence.asm -->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.asm</artifactId>
<version>${persistence.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.eclipse.persistence/org.eclipse.persistence.core -->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.core</artifactId>
<version>${persistence.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.eclipse.persistence/org.eclipse.persistence.moxy -->
<!-- EclipseLink MOXy(JAXB 对象/XML 绑定实现) -->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.moxy</artifactId>
<version>${persistence.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-JAXB-ReferenceImpl -->
<!-- docx4j JAXB ReferenceImpl(Glassfish 实现,JDK 21 推荐使用) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-JAXB-ReferenceImpl</artifactId>
<version>${docx4j-jaxb.version}</version>
</dependency>
<!-- ======== Jakarta XML Bind / Activation ======== -->
<!-- https://mvnrepository.com/artifact/org.glassfish.jaxb/jaxb-runtime -->
<!-- Glassfish JAXB 4.x 运行时(docx4j 静态初始化需要的 JAXB provider) -->
<dependency>
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId>
<version>4.0.6</version>
</dependency>
<!-- https://mvnrepository.com/artifact/jakarta.xml.bind/jakarta.xml.bind-api -->
<!-- Jakarta XML Bind API 4.x(JAXB 4 的 jakarta 命名空间接口) -->
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
<version>4.0.4</version>
</dependency>
<!-- https://mvnrepository.com/artifact/jakarta.activation/jakarta.activation-api -->
<!-- Jakarta Activation API(MIME 类型处理,JAXB 运行时依赖) -->
<dependency>
<groupId>jakarta.activation</groupId>
<artifactId>jakarta.activation-api</artifactId>
<version>${jakarta-activation.version}</version>
</dependency>
<!-- ======== docx4j 生成模型 ======== -->
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-generated-objects -->
<!-- docx4j 17.0.x 生成的 OOXML 模型类(替代旧 openxml-objects) -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-generated-objects</artifactId>
<version>${docx4j.version}</version>
</dependency>
<!-- 旧 openxml-objects 模型构件(docx4j 11.5.x 时代,最终版 11.5.14);
仅当外部依赖显式引用时生效,docx4j 17.0.x 树内不再使用 -->
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-openxml-objects -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-openxml-objects</artifactId>
<version>${docx4j-openxml.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.docx4j/docx4j-openxml-objects-pml -->
<dependency>
<groupId>org.docx4j</groupId>
<artifactId>docx4j-openxml-objects-pml</artifactId>
<version>${docx4j-openxml.version}</version>
</dependency>
<!-- ======== OGNL 表达式引擎 ======== -->
<!-- https://mvnrepository.com/artifact/ognl/ognl -->
<!-- OGNL(对象图导航语言,docx4j 模板变量表达式求值) -->
<dependency>
<groupId>ognl</groupId>
<artifactId>ognl</artifactId>
<version>${ognl.version}</version>
</dependency>
<!-- ======== 模板引擎 ======== -->
<!-- https://mvnrepository.com/artifact/com.ibeetl/beetl -->
<!-- Beetl 模板引擎(easydoc-beetl 模块使用) -->
<dependency>
<groupId>com.ibeetl</groupId>
<artifactId>beetl</artifactId>
<version>${beetl.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.freemarker/freemarker -->
<!-- FreeMarker 模板引擎(easydoc-freemarker 模块使用) -->
<dependency>
<groupId>org.freemarker</groupId>
<artifactId>freemarker</artifactId>
<version>${freemarker.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.perfcake/httl -->
<!-- HTTL 模板引擎(easydoc-httl 模块使用) -->
<dependency>
<groupId>org.perfcake</groupId>
<artifactId>httl</artifactId>
<version>${httl.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.github.subchen/jetbrick-template -->
<!-- Jetbrick Template 模板引擎(easydoc-jetbrick 模块使用) -->
<dependency>
<groupId>com.github.subchen</groupId>
<artifactId>jetbrick-template</artifactId>
<version>${jetbrick.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.antlr/antlr4-runtime -->
<!-- ANTLR4 运行时(Beetl/Jetbrick 等模板引擎的解析器依赖) -->
<dependency>
<groupId>org.antlr</groupId>
<artifactId>antlr4-runtime</artifactId>
<version>${antlr4.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.rythmengine/rythm-engine -->
<!-- Rythm 模板引擎(easydoc-rythm 模块使用) -->
<dependency>
<groupId>org.rythmengine</groupId>
<artifactId>rythm-engine</artifactId>
<version>${rythm.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.thymeleaf/thymeleaf -->
<!-- Thymeleaf 模板引擎(easydoc-thymeleaf 模块使用) -->
<dependency>
<groupId>org.thymeleaf</groupId>
<artifactId>thymeleaf</artifactId>
<version>${thymeleaf.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.velocity/velocity-engine-core -->
<!-- Velocity 引擎核心(easydoc-velocity 模块使用) -->
<dependency>
<groupId>org.apache.velocity</groupId>
<artifactId>velocity-engine-core</artifactId>
<version>${velocity.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.velocity/velocity-engine-scripting -->
<!-- Velocity Scripting(JSR 223 脚本引擎支持) -->
<dependency>
<groupId>org.apache.velocity</groupId>
<artifactId>velocity-engine-scripting</artifactId>
<version>${velocity.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.apache.velocity.tools/velocity-tools-generic -->
<!-- Velocity Tools Generic(3.x 拆分后的通用工具集,含 DateTool;不再依赖 Struts) -->
<dependency>
<groupId>org.apache.velocity.tools</groupId>
<artifactId>velocity-tools-generic</artifactId>
<version>${velocity-tools.version}</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.github.zqq90.webit-script/webit-script -->
<!-- Webit Script 模板引擎(easydoc-webit 模块使用) -->
<dependency>
<groupId>com.github.zqq90.webit-script</groupId>
<artifactId>webit-script</artifactId>
<version>${webit-script.version}</version>
</dependency>
<!-- ======== 开发工具 ======== -->
<!-- https://mvnrepository.com/artifact/org.projectlombok/lombok -->
<!-- Lombok(编译期注解处理器,简化 JavaBean 代码) -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
<scope>provided</scope>
</dependency>
<!-- ======== Jackson BOM(统一管理 Jackson 3.x 版本) ======== -->
<!-- https://mvnrepository.com/artifact/tools.jackson/jackson-bom -->
<!-- Jackson 3.x 使用新坐标 tools.jackson,BOM 导入统一锁定版本 -->
<dependency>
<groupId>tools.jackson</groupId>
<artifactId>jackson-bom</artifactId>
<version>${jackson-bom.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<!-- For Slf4j -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<!-- ======== Test ======== -->
<!-- JUnit Jupiter(聚合构件,唯一测试框架;JUnit 4 已随死用例一并移除) -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
<!-- AssertJ(流式断言) -->
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
<!-- For Lombok -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<scope>provided</scope>
</dependency>
</dependencies>
<distributionManagement>
<repository>
<id>2624322-release-6F6h6R</id>
<url>https://packages.aliyun.com/6927b116e6c3e0425dbdf60d/maven/2624322-release-6f6h6r</url>
</repository>
<snapshotRepository>
<id>2624322-snapshot-3EoOv3</id>
<url>https://packages.aliyun.com/6927b116e6c3e0425dbdf60d/maven/2624322-snapshot-3eoov3</url>
</snapshotRepository>
</distributionManagement>
<!-- Maven 4 (POM 4.1.0) 聚合标签:modules 已改名为 subprojects,子项用 subproject -->
<subprojects>
<subproject>easydoc-beetl</subproject>
<subproject>easydoc-bom</subproject>
<subproject>easydoc-core</subproject>
<subproject>easydoc-freemarker</subproject>
<subproject>easydoc-httl</subproject>
<subproject>easydoc-jetbrick</subproject>
<subproject>easydoc-jsp</subproject>
<subproject>easydoc-rythm</subproject>
<subproject>easydoc-thymeleaf</subproject>
<subproject>easydoc-velocity</subproject>
<subproject>easydoc-webit</subproject>
<subproject>easydoc-xhtml</subproject>
</subprojects>
<build>
<pluginManagement>
<plugins>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-clean-plugin -->
<!-- Maven Clean(清理 target 目录) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<version>${maven-clean-plugin.version}</version>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-compiler-plugin -->
<!-- Maven Compiler(Java 编译,配置 release / encoding / 内存) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<configuration>
<release>${java.version}</release>
<encoding>${project.build.sourceEncoding}</encoding>
<maxmem>512M</maxmem>
</configuration>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-deploy-plugin -->
<!-- Maven Deploy(部署构件到远程仓库) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>${maven-deploy-plugin.version}</version>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-enforcer-plugin -->
<!-- Maven Enforcer(构建护栏:强制 Maven/Java 版本 + 禁止旧 docx4j 构件) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>${maven-enforcer-plugin.version}</version>
<executions>
<execution>
<id>default-cli</id>
<goals>
<goal>enforce</goal>
</goals>
<phase>validate</phase>
<configuration>
<rules>
<requireMavenVersion>
<message>
<![CDATA[You are running an older version of Maven. This application requires at least Maven 4 (4.0.0-rc-6 or newer; note that in Maven version ordering 4.0.0-rc-N is LOWER than 4.0.0, so the range starts at the rc).]]></message>
<version>[4.0.0-rc-6,)</version>
</requireMavenVersion>
<requireJavaVersion>
<message>
You are running an older version of Java. This application requires at least
JDK ${java.version}.
</message>
<version>[${java.version}.0,)</version>
</requireJavaVersion>
<!-- 护栏:禁止任何模块直接声明 11.5.x 时代的 OOXML 模型构件。
这三个构件与 docx4j-generated-objects 17.0.3 同 FQN,谁先进类路径谁生效;
任何直接声明都依赖 Maven 解析顺序,会丢失 17.0.x 新增 schema 类。
如确实需要旧版本模型,单独提 issue 评估:是否升级到 17.0.x 的新构件名 -->
<bannedDependencies>
<message><![CDATA[禁止直接声明 docx4j-openxml-objects/-pml/-sml(11.5.x 时代的 OOXML 模型构件)。
该构件与 docx4j-generated-objects 17.0.3 同 FQN,运行时依赖 Maven 解析顺序决定谁遮蔽谁,
会被 17.0.3 反遮蔽而丢失新 schema 类,或反过来遮蔽 17.0.3 同样丢类。
运行时所需的 jakarta 模型由 docx4j-core 17.0.3 的传递依赖 docx4j-generated-objects 17.0.3 自动提供,
无需也无法直接声明。如有 11.5.x 兼容需求,请单独开 issue 评估迁移方案。]]></message>
<excludes>
<exclude>org.docx4j:docx4j-openxml-objects</exclude>
<exclude>org.docx4j:docx4j-openxml-objects-pml</exclude>
<exclude>org.docx4j:docx4j-openxml-objects-sml</exclude>
</excludes>
<searchTransitive>false</searchTransitive>
</bannedDependencies>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-gpg-plugin -->
<!-- Maven GPG(release 时对构件进行 GPG 签名) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>${maven-gpg-plugin.version}</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-install-plugin -->
<!-- Maven Install(将构件安装到本地仓库) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>${maven-install-plugin.version}</version>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-resources-plugin -->
<!-- Maven Resources(处理资源文件的过滤与复制) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>${maven-resources-plugin.version}</version>
<configuration>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-release-plugin -->
<!-- Maven Release(版本发布自动化:打 tag、升版本、部署) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>${maven-release-plugin.version}</version>
<configuration>
<tagNameFormat>v@{project.version}</tagNameFormat>
<autoVersionSubmodules>true</autoVersionSubmodules>
<useReleaseProfile>false</useReleaseProfile>
<releaseProfiles>release</releaseProfiles>
<goals>deploy</goals>
</configuration>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-source-plugin -->
<!-- Maven Source(生成源码 jar 并附加到构件) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>${maven-source-plugin.version}</version>
<configuration>
<attach>true</attach>
</configuration>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-surefire-plugin -->
<!-- Maven Surefire(执行单元测试) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
<configuration>
<skip>false</skip>
<skipTests>false</skipTests>
<!-- @{argLine} 为 surefire 3.x 晚绑定写法(与 1.0.x/2.0.x 统一):
运行期才求值,能取到 jacoco prepare-agent 注入的 -javaagent;
早绑定 ${argLine} 在 pom 构建期展开,jacoco 的注入会丢失 -->
<!--suppress UnresolvedMavenProperty -->
<argLine>@{argLine} -Xmx1024m -Dfile.encoding=UTF-8</argLine>
<additionalClasspathElements>
<additionalClasspathElement>${basedir}/target/test-classes</additionalClasspathElement>
</additionalClasspathElements>
<includes>
<include>**/*Test.java</include>
</includes>
<excludes>
<exclude>**/TestBean.java</exclude>
</excludes>
</configuration>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-jar-plugin -->
<!-- Maven Jar(打包 jar,含 manifest 信息) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>${maven-jar-plugin.version}</version>
<configuration>
<skipIfEmpty>true</skipIfEmpty>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
</manifest>
</archive>
</configuration>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-javadoc-plugin -->
<!-- Maven Javadoc(生成 javadoc jar);
doclint=none:历史上 disable-javadoc-doclint profile 通过
additionalparam 传 -Xdoclint:none,但 javadoc-plugin 3.x 已
移除该参数(改名 additionalJOption),导致配置从未生效、
release profile 的 javadoc jar 在存量中文注释上 80+ 报错。
在此处用插件原生 doclint 属性恢复原意 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>${maven-javadoc-plugin.version}</version>
<configuration>
<charset>${project.build.sourceEncoding}</charset>
<encoding>${project.build.sourceEncoding}</encoding>
<docencoding>${project.build.sourceEncoding}</docencoding>
<doclint>none</doclint>
</configuration>
<executions>
<execution>
<id>attach-javadocs</id>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- https://mvnrepository.com/artifact/org.sonatype.plugins/nexus-staging-maven-plugin -->
<!-- Nexus Staging(OSSRH 仓库发布暂存与自动释放) -->
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>${maven-nexus-staging-plugin.version}</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>false</autoReleaseAfterClose>
<stagingProgressPauseDurationSeconds>60</stagingProgressPauseDurationSeconds>
<stagingProgressTimeoutMinutes>20</stagingProgressTimeoutMinutes>
<detectBuildFailures>true</detectBuildFailures>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<!-- https://mvnrepository.com/artifact/org.jacoco/jacoco-maven-plugin -->
<!-- JaCoCo(代码覆盖率:prepare-agent + report + check)。
双层门槛(审计 #18):
1) BUNDLE 级 LINE ≥ 0.92:v20260830 基线(原 0.90 名义门槛实际全模块 91.45%~100%);
2) PACKAGE 级 LINE ≥ 0.85:此前 BUNDLE 汇总掩盖了子包短板
(easydoc-core/io.github.easy4j.doc.handler 曾仅 84.34%、
easydoc-xhtml/io.github.easy4j.doc.xhtml.markdown 曾为 88.99%),
先以 VariableReplaceGuardsPathTest / DocxStructureExtractorExtendedTest
抬升至 91.57% / 91.04%,再启用包级硬门。
棘轮计划:后续每次发版将两级下限各收紧约 5~10 个百分点,向 1.00 渐进 -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${maven-jacoco-plugin.version}</version>
<executions>
<execution>
<id>prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>verify</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
<execution>
<id>check</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
<configuration>
<haltOnFailure>true</haltOnFailure>
<rules>
<rule>
<element>BUNDLE</element>
<limits>
<limit>
<counter>LINE</counter>
<value>COVEREDRATIO</value>
<minimum>0.92</minimum>
</limit>
</limits>
</rule>
<!-- 包级硬门:VM 记法包名(见 jacoco check 规则的 element-name 匹配) -->
<rule>
<element>PACKAGE</element>
<includes>
<include>io/github/easy4j/doc/handler</include>
</includes>
<limits>
<limit>
<counter>LINE</counter>
<value>COVEREDRATIO</value>
<minimum>0.85</minimum>
</limit>
</limits>
</rule>
<rule>
<element>PACKAGE</element>
<includes>
<include>io/github/easy4j/doc/xhtml/markdown</include>
</includes>
<limits>
<limit>
<counter>LINE</counter>
<value>COVEREDRATIO</value>
<minimum>0.85</minimum>
</limit>
</limits>
</rule>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-compiler-plugin -->
<!-- Maven Compiler(全局编译配置,含 Lombok 注解处理器路径) -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<configuration>
<release>${java.version}</release>
<parameters>true</parameters>
<encoding>${project.build.sourceEncoding}</encoding>
<maxmem>512M</maxmem>
<annotationProcessorPaths>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
</path>
</annotationProcessorPaths>
</configuration>
</plugin>
<!-- 继承式 enforcer 绑定:pluginManagement 里的 execution 不会自动跑,
必须在这里显式 enable。规则来自根 pom pluginManagement 的
maven-enforcer-plugin(requireMavenVersion / requireJavaVersion
+ bannedDependencies 三个旧 docx4j-openxml-objects* 构件)。
所有 easydoc-* 子模块都会执行 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>