惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

P
Proofpoint News Feed
Martin Fowler
Martin Fowler
The GitHub Blog
The GitHub Blog
B
Blog RSS Feed
U
Unit 42
阮一峰的网络日志
阮一峰的网络日志
量子位
GbyAI
GbyAI
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
云风的 BLOG
云风的 BLOG
小众软件
小众软件
博客园 - 三生石上(FineUI控件)
L
LangChain Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
博客园_首页
IT之家
IT之家
V
Visual Studio Blog
Y
Y Combinator Blog
Blog — PlanetScale
Blog — PlanetScale
宝玉的分享
宝玉的分享
Apple Machine Learning Research
Apple Machine Learning Research
I
InfoQ
D
Docker
V
V2EX

博客园 - 狗狗听话

SpringBoot学习之缓存@Caching, @Cacheable,@CacheEvict Java学习之LocalDateTime, LocalDate, LocalTime python在某个目录下的查找指定文件夹 SpringBoot学习之JPA设置多个主键的方法 Python使用psycopg2的copy_from方法高效的大量数据批量导入 SpringBoot学习之文件上传(利用postman测试) SpringBoot学习之文件上传,下载 Python常用的语法糖 Python学习之datetime Java学习之 stream 常用方法 SpringBoot学习之使用idea打包jar文件 React学习之数组 Java学习之日期时间转换 Java读取execl 利用JDBC插入Postgresql简单示例 Springboot中项目启动加载的几种方式 Java selenium实现浏览器ctrl + s功能 Macbook pro 安装Redis Macbook pro 打开pgAmin报错 SpringBoot学习之任务定时器 关于git rebase中的一些问题:Git报错“no branch, rebasing master”
Java学习之 EasyExcel
狗狗听话 · 2026-04-15 · via 博客园 - 狗狗听话
package com.dream.data.form;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.*;
import com.alibaba.excel.enums.BooleanEnum;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDate;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@HeadStyle(horizontalAlignment = HorizontalAlignmentEnum.CENTER)
@HeadFontStyle(fontName = "微软雅黑", fontHeightInPoints = 11, bold = BooleanEnum.TRUE)
@ContentStyle(horizontalAlignment = HorizontalAlignmentEnum.CENTER)
@ContentFontStyle(fontName = "微软雅黑", fontHeightInPoints = 11)
public class MatchForm {

/**时间*/
@DateTimeFormat(pattern = "yyyy-MM-dd")
@ExcelProperty(value="比赛时间", index = 0)
@ColumnWidth(16)
private LocalDate matchDate;

/**联赛*/
@ExcelProperty(value = "联赛", index = 1)
@ColumnWidth(12)
private String leagueName;

/**主队*/
@ExcelProperty(value = "主队", index = 2)
@ColumnWidth(20)
private String homeTeam;

/**客队*/
@ExcelProperty(value = "客队", index = 3)
@ColumnWidth(20)
private String awayTeam;

@ExcelProperty(value = "高于", index = 4)
@ColumnWidth(12)
private String concedeGreater;

@ExcelProperty(value = "让球", index = 5)
@ColumnWidth(12)
private String concede;

@ExcelProperty(value = "低于", index = 6)
@ColumnWidth(12)
private String concedeLess;

@ExcelProperty(value = "高于", index = 7)
@ColumnWidth(12)
private String goalsGreater;

@ExcelProperty(value = "大小球", index = 8)
@ColumnWidth(12)
private String goals;

@ExcelProperty(value = "低于", index = 9)
@ColumnWidth(12)
private String goalsLess;

@ExcelProperty(value = "比分(全)", index = 10)
@ColumnWidth(12)
private String fullScore;

@ExcelProperty(value = "比分(半)", index = 11)
@ColumnWidth(12)
private String halfScore;
}