Bug 63779

Summary: RFE: Add support for the new Java date/time API added in Java 8
Product: POI Reporter: Axel Howind <axel>
Component: POI OverallAssignee: POI Developers List <dev>
Severity: normal    
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Bug Depends on: 63794    
Bug Blocks:    

Description Axel Howind 2019-09-28 10:53:36 UTC
Since version 4.0.1, Apache POI requires Java 8. In that Java version, the new date/time API was introduced which is both easier to use and less error prone than the old (and flawed) API consisting of java.util.Date etc.

Client code that uses the new LocalDate and LocalDateTime classes nonetheless has to convert dates to the now somewhat obsolete old classes when dealing with POI. To leverage this, support for LocalDate/LocalDateTime should be added to POI, namely the Cell interface and DateUtil class.

Since the old java.util.Date based API is still used by a lot of client code, support should be added in a backwards compatible way.

I volunteer to add this support, as well as doing some cleanup of the date/time handling.
Comment 1 Dominik Stadler 2019-10-09 19:17:37 UTC
Patch is applied via r1868198, thanks a lot for the implementation work!
Comment 2 PJ Fanning 2019-10-10 07:06:59 UTC
Should we have `@since` annotations on the new methods?
Comment 3 Andreas Beeker 2019-12-08 23:32:07 UTC
Activate round seconds feature again via r1871065