当前位置:网站首页>Using POI TL to insert multiple pictures and the same data of multiple rows of cells into the table cells of word template at one time, it is a functional component for automatic merging
Using POI TL to insert multiple pictures and the same data of multiple rows of cells into the table cells of word template at one time, it is a functional component for automatic merging
2022-07-29 05:32:00 【crystal lattices 】
One 、 How to insert multiple pictures
1) Use blocks provided in the document to insert multiple pictures
Use of blocks : stay word Use in templates :
{ {?images}}
{ {url}}
{ {/images}}
After defining the template in this way , The structure of the data model is as follows :
data.put("items", new ArrayList<JSONObject>(){
{
add(new JSONObject().fluentPut("url", " Picture links 1"));
add(new JSONObject().fluentPut("url", " Picture links 2"));
add(new JSONObject().fluentPut("url", " Picture links 3"));
}});The above picture links can also be through Pictures.ofUrl().create() structure PictureRenderData Use .
2) Customize the plug-in to insert multiple pictures
When inserting multiple pictures according to the method , You must use a list of objects , That is to say, it must be in items List add contains url Object of property ; We want to make it easier to insert multiple graphs , Use '&' Character as the prefix of the custom plug-in .
The plug-in code for inserting multiple pictures is as follows :
package com.fight.strive.sys.modules.poi_tl;
import com.deepoove.poi.data.PictureRenderData;
import com.deepoove.poi.policy.AbstractRenderPolicy;
imp边栏推荐
- 水一篇图的拓扑排序
- 适创科技以云仿真平台,支持“中国智造”升级
- 阿里云联合鼎捷软件发布云上数字工厂解决方案,实现云MES系统本地化部署
- End of document
- 抽象类与接口
- 【C语言系列】—深度解剖数据在内存中的存储(一) 暑假开篇
- Come on! See how Clickhouse, which has risen 16 places a year, can be implemented in jd.com
- 串口通讯部分详解
- During the appointment, the 2022 JD cloud industrial integration new product launch was launched online
- 321,京东言犀×NLPCC 2022挑战赛开赛!
猜你喜欢

Container security open source detection tool - veinmind (mirror backdoor, malicious samples, sensitive information, weak password, etc.)

More than 200 ISVs have settled in! The first anniversary of Alibaba cloud computing nest

Helm chart for Kubernetes

京东云联合Forrester咨询发布混合云报告 云原生成为驱动产业发展新引擎

预约中,2022京东云产业融合新品发布会线上开启

【C语言系列】— 字符串+部分转义字符详解+注释小技巧

Day 1

Alibaba cloud architect details nine trends in the game industry

Best practices for elastic computing in the game industry

Alibaba cloud architect Liang Xu: MES on cloud box helps customers quickly build digital factories
随机推荐
直播预告|如何通过“智能边缘安全”提升企业免疫力?
直播预告:京东云DevOps与JFrog制品库的融合
哈夫曼树以及哈夫曼编码在文件压缩上的应用
【C语言系列】— 把同学弄糊涂的 “常量” 与 “变量”
EXIT中断详解
【赛事预告】云上开发,高效智能——第二届阿里云ECS CloudBuild开发者大赛即将启动
阿里云架构师细说游戏行业九大趋势
牛客网编程题—【WY22 Fibonacci数列】和【替换空格】详解
数组学习之入门简单题 两数之和
365 day challenge leetcode1000 question - distance between bus stops on day 038 + time-based key value storage + array closest to the target value after transforming the array and + maximum value at t
Day 3
利用Poi-tl在word模板表格单元格内一次插入多张图片和多行单元格相同数据自动合并的功能组件
C语言数组典型应用代码详细讲解—高手误入(逐步代码详解)
浅谈Servlet
预约中,2022京东云产业融合新品发布会线上开启
Introduction to array learning simple question sum of two numbers
抢先预约 | 阿里云无影云应用线上发布会预约开启
Best practices for elastic computing in the game industry
APP常用跨端技术栈深入分析
365 day challenge leetcode 1000 questions - day 040 design jump table + avoid flooding + find the latest grouping with size M + color ball with reduced sales value