Monorepo containing small Spring/utility modules for common development tasks.
-
spring-excel-mapper — Lightweight, annotation-driven Excel import/export mapper
-
spring-tools-simples — Demo/example application with usage patterns
<dependency>
<groupId>org.springtools</groupId>
<artifactId>spring-excel-mapper</artifactId>
<version>1.0.0-SNAPSHOT</version>
</dependency>// 1. Define model with annotations
@ExcelSheet
@ExcelRow(startRowIndex = 1)
public class StudentExcelModel {
@ExcelColumn(col = "A", required = true)
public String name;
@ExcelColumn(col = "B", regex = "^[\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}$")
public String email;
@ExcelColumn(col = "C", min = 18, max = 65)
public Integer age;
}
// 2. Parse Excel (with validation)
Workbook workbook = WorkbookFactory.create(inputStream);
ImportResult<StudentExcelModel> result =
ExcelMapper.parseWorkbookWithResult(workbook, StudentExcelModel.class, false);
// 3. Export to template (preserves styles)
Sheet sheet = workbook.getSheet("Students");
ExcelExporter.fillTableRows(sheet, 1, result.getSuccessList(), StudentExcelModel.class);See Usage Patterns for detailed examples.
# Build all modules
mvn clean package
# Build specific module
mvn -pl spring-excel-mapper -am package
# Run example application
mvn -pl spring-tools-simples spring-boot:run- API Reference & Design: spring-excel-mapper/README.md
- Usage Patterns: spring-tools-simples/README.md
- 中文文档: spring-excel-mapper/README-zh.md
- Java 17+
- Spring Boot 2.7+ (for example module)
- Apache POI 5.x