Fix some IDE warnings and JVM deprecations

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1851795 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Dominik Stadler 2019-01-22 10:00:01 +00:00
parent 5a758864b5
commit b5fe208770
2 changed files with 3 additions and 4 deletions

View File

@ -106,7 +106,7 @@ public final class POILogFactory {
@SuppressWarnings("unchecked")
Class<? extends POILogger> loggerClass =
(Class<? extends POILogger>) Class.forName(_loggerClassName);
logger = loggerClass.newInstance();
logger = loggerClass.getConstructor().newInstance();
logger.initialize(cat);
} catch(Exception e) {
// Give up and use the null logger

View File

@ -380,10 +380,9 @@ public final class TestCellReference {
//noinspection ObjectEqualsNull
assertNotEquals("null", null, ref1);
assertNotEquals("3D vs 2D", ref1, new CellReference("A5"));
//noinspection EqualsBetweenInconvertibleTypes
assertNotEquals("type", ref1, new Integer(0));
assertNotEquals("type", ref1, 0L);
}
@Test
public void isRowWithinRange() {
SpreadsheetVersion ss = SpreadsheetVersion.EXCEL2007;