Summary: | Forbidden APIs patches | ||
---|---|---|---|
Product: | POI | Reporter: | Andreas Beeker <kiwiwings> |
Component: | POI Overall | Assignee: | POI Developers List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | enhancement | Keywords: | PatchAvailable |
Priority: | P2 | ||
Version: | 3.13-dev | ||
Target Milestone: | --- | ||
Hardware: | All | ||
OS: | All | ||
Attachments: | [PATCH] patch for forbidden apis - v1 |
Description
Andreas Beeker
2015-09-04 09:28:26 UTC
Created attachment 33060 [details]
[PATCH] patch for forbidden apis - v1
I like the separate LocaleUtil class which encapsulates the selection of all these items, I think it would be good to apply these changes now without enabling more forbidden-api-checks in order to get tests running fine again for now and then fix the remaining api-checks in the main sources. Then take a look at all the items in tests separately step-by-step while maintaining a green CI-build. first set of changes for locale and timezone settings with r1701688 also includes fixes for - name shadowing - unused deprecated method "getClipRect" in classes extending Graphics2d - HexDump - replaced intermediate String.format calls with custom padding - convert testcases to junit4 - closing resources also tested with an arbitary timezone (PST) and locale (ru) supresses forbidden apis check for - LocaleUtil (the only place where Locale.getDefault() and TimeZone.getDefault() should be called) - Classes using FontMetrics - without the actual text it's difficult to return something sane Some usage of UTC and Locale.ROOT might be still wrong, e.g. in MapiMessage we don't access the extended mapi properties, which might contain the timezone DataFormatter has now a Observable property which need to be observed when custom formats are used and the Locale changes The charset fixes are applied with r1701713 So it looks like, there's only - a probably not so easy to catch - error with CellDateFormatter to fix ... Although there are still areas where we use forbidden apis, and we probably add further method signatures to the poi custom signature file, I'm closing this for now, as the main goal seems to be reached ... |