Refactored the D* function enum to have instances return the function implementation instances rather than using a case construct, now that Java 8 is required.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1819376 13f79535-47bb-0310-9956-ffa450edef68
Found some optimizations in the general evaluation framework related to blank cells in rows beyond the last defined row of a sheet.
I don't see any issue with passing a bit of context down deeper into this framework, as it's all POI-internal and only had one calling path.
See the above bug for the performance analysis. Not specifically related to VLOOKUP, but improves that case by more than 2/3 as well.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1817252 13f79535-47bb-0310-9956-ffa450edef68
Fixes Bug 61761 Conditional formatting rule evaluation doesn't like comparing cells of different types
fixed, with unit tests.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1815298 13f79535-47bb-0310-9956-ffa450edef68
now evaluating based on cell references instead, and watching out for undefined cells in rules that require a cell.
Added unit test based on previously failing file.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1805245 13f79535-47bb-0310-9956-ffa450edef68
One of my users found that my initial implementation was lacking a core distinction - most evaluations expect a single result, and "unwrap" 2/3D ValueEval results to a single value based on the input row/column.
However, data validation list formulas explicitly are expected to return a 2D ValueEval. This worked when the formula was simple and evaluated to a single Ptg, but only returned one value when the formula was more complex, or referenced a named range defined as a complex formula.
This change teaches WorkbookEvaluator about the distinction, by way of a new attribute for FormulaType.
There is room for discussion over how it is implemented, but this works for me.
Includes the failing workbook we had as a new unit test.
While I was in FormulaType I went ahead and removed the deprecated, unused, and redundant code marked for removal in 3.17.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1803121 13f79535-47bb-0310-9956-ffa450edef68
Adjust table style processing to allow for AlternateContent wrappers for table element style definitions.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799733 13f79535-47bb-0310-9956-ffa450edef68
teach XSSFColor and most things that create instances about indexed colors.
Null is a valid value for IndexedColorMap instances - the existing built-in default colors are used.
Whenever a workbook style is accessible in the call hierarchy its color mappings are passed down now.
Thanks for the unit test in the issue, it now passes.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796359 13f79535-47bb-0310-9956-ffa450edef68
Currently only implemented for XSSF, as there is no API available for HSSF conditional formatting rule number formats (if it is even in the files).
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1794084 13f79535-47bb-0310-9956-ffa450edef68
Thanks to Mauricio Eastmond for the Excel test file and unit test.
Thanks to Sebastian Wikalinski for isolating the problem and providing a patch.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1793223 13f79535-47bb-0310-9956-ffa450edef68
implemented per issue, breaking out static text vs. formula based title getters and setters, with unit test updates and additions.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1791025 13f79535-47bb-0310-9956-ffa450edef68
includes unit test from the issue. Verified unit test results in Excel vs. incorrect previous POI results. Test passes new code, as do existing tests.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1783037 13f79535-47bb-0310-9956-ffa450edef68