Commit Graph

8 Commits

Author SHA1 Message Date
Marten Deinum
4fb5fb906d Update documentation
Document on how to use the BeanWrapperRowMapper with the StreamingXlsxItemReader as that requires a bit more configuration due to the streaming nature.

Next to the documentation also added a test case for this to show how to configure it as well.

Closes: #115
2024-09-18 16:50:02 +02:00
Marten Deinum
395560672a Customization of Apache POI helpers
Prior to this commit it was impossible to modify or configure the DataFormatter and FormulaEvaluator in use. With this commit we resolve this by introducing two interfaces. 1 DataFormatterCustomizer to customize/configure the the DataFormatter in use. 1 interface the FormulaEvaluatorFactory which is a factory used to create the FormulaEvaluator.

The default DataFormatterCustomizer will configure the formatter to use the cached values from cells instead of evaluating the formulas.

The default FormulaEvaluatorFactory in use will always return null instead of creating a FormulaEvaluator.

Fixes: #126
2024-09-18 15:52:18 +02:00
Marten Deinum
7efdb2054a Update README.adoc
Include a FAQ section for commonly asked questions. 

Closes: #97
2023-10-02 16:02:20 +02:00
Marten Deinum
8a276f921c Update README.adoc
Include the supported Spring Batch versions in the documentation.

Closes: #111
2023-10-02 15:55:17 +02:00
Marten Deinum
f9709d9c35 Allow a Locale to be set for formatting (#100)
The internal DataFormatter used from Apache POI allows for setting a fixed
Locale to use when reading numbers, dates etc. Initially we didn't set this
and thus it always used the default Locale as set from the Java runtime. This
could lead to unexpected results. We now allow to set the userLocale property
and use this to configure the DataFormatter used internally.

We also took the opportunity to make this work with the streaming ItemReader
as well as the regular ItemReader. The streaming item reader now also uses
a pre-configured DataFormatter.

Closes: #98
2023-09-19 20:48:29 +02:00
Marten Deinum
7820d8ea6a Optional iso dates (#94)
* Optionally use ISO formatting for dates

Prior to this commit we always used the date pattern as
assigned in the Excel workbook for the cell. Which could
lead to surprising results.

We now allow the dates to be formatted as an ISO date time with
offset, so dates/times are consistently formatted in the result.

Closes: #88
2022-04-12 10:58:18 +02:00
Marten Deinum
f4980bd240 Added note on thread-safety to documentation
Both Apache POI and the AbstractItemCountingItemStreamItemReader aren't threadsafe
and thus the Excel based item readers aren't usable with multiple threads. A note
on this has been added to the documentation.

Closes: #48
2021-05-19 08:51:03 +02:00
Marten Deinum
9bb5c79290 Initial version 0.1.0 changes from original repository
Development of Spring Batch Excel continued in the original repository at
http://github.com/mdeinum/spring-batch-excel.git, with this commit we transfer all fixes, updates and new features in one go to the Spring Batch Excel repository.

The most important changes are:
- Moved to new location org.springframework.batch.extensions
- Removed support for JXL
- Initial support for reading XLSX files streaming
- Upgraded dependencies to most recent versions
- Support for reading password protected files
- Numerous small fixes

Fixes: 10,11,19,26,29,34
Closes: 13,14,30,35,50
2021-03-26 16:53:54 +01:00