[MDSAL-206] DOMEvent contains only event time with Date, which has insufficient precision Created: 03/Nov/16 Updated: 09/Mar/18 Resolved: 23/Feb/18 |
|
| Status: | Resolved |
| Project: | mdsal |
| Component/s: | DOM API |
| Affects Version/s: | None |
| Fix Version/s: | Oxygen |
| Type: | Improvement | ||
| Reporter: | Rudolf Brisuda | Assignee: | Robert Varga |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| Issue Links: |
|
||||||||
| Description |
|
If we want to deal with 6 digits precision at position of milliseconds, e. g. eventTime = "2015-10-23T09:42:27.200001Z", date class is insufficient. Parsing these strings causes wrong time in resulting Date object. Thus precision is only until milliseconds (2 digits). We found solution with using LocalDateTime from Java 8 where is precision until nanoseconds but it is not supporting now. Here is possible solution in controller: |
| Comments |
| Comment by Robert Varga [ 30/Jan/18 ] |
|
I am not sure LocalDateTime is the appropriate type here – we really would like to represent these in UTC, without relying on local timezone. |
| Comment by Robert Varga [ 30/Jan/18 ] |