diff options
author | PJ Fanning <fanningpj@apache.org> | 2018-09-29 09:33:52 +0000 |
---|---|---|
committer | PJ Fanning <fanningpj@apache.org> | 2018-09-29 09:33:52 +0000 |
commit | 874687c490d30c6107c95ed3aab90d37b013f63b (patch) | |
tree | b7b8fde061ce8e284ec828233ac2c77c27d5bf69 /src/java/org/apache/poi/ss | |
parent | a070b90728b1938a7c2cff7a3ad51eadd896b13c (diff) | |
download | poi-874687c490d30c6107c95ed3aab90d37b013f63b.tar.gz poi-874687c490d30c6107c95ed3aab90d37b013f63b.zip |
lgtm issues
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1842302 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/poi/ss')
-rw-r--r-- | src/java/org/apache/poi/ss/formula/EvaluationConditionalFormatRule.java | 16 | ||||
-rw-r--r-- | src/java/org/apache/poi/ss/formula/FormulaParser.java | 3 |
2 files changed, 4 insertions, 15 deletions
diff --git a/src/java/org/apache/poi/ss/formula/EvaluationConditionalFormatRule.java b/src/java/org/apache/poi/ss/formula/EvaluationConditionalFormatRule.java index 42c626b512..3ca5e71d76 100644 --- a/src/java/org/apache/poi/ss/formula/EvaluationConditionalFormatRule.java +++ b/src/java/org/apache/poi/ss/formula/EvaluationConditionalFormatRule.java @@ -21,15 +21,7 @@ import java.text.CollationKey; import java.text.Collator; import java.text.DecimalFormat; import java.text.DecimalFormatSymbols; -import java.util.ArrayList; -import java.util.Collections; -import java.util.HashMap; -import java.util.HashSet; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Locale; -import java.util.Map; -import java.util.Set; +import java.util.*; import org.apache.poi.ss.formula.eval.BlankEval; import org.apache.poi.ss.formula.eval.BoolEval; @@ -900,9 +892,9 @@ public class EvaluationConditionalFormatRule implements Comparable<EvaluationCon return false; } ValueAndFormat o = (ValueAndFormat) obj; - return ( value == o.value || value.equals(o.value)) - && ( format == o.format || format.equals(o.format)) - && (string == o.string || string.equals(o.string)); + return (Objects.equals(value, o.value) + && Objects.equals(format, o.format) + && Objects.equals(string, o.string)); } /** diff --git a/src/java/org/apache/poi/ss/formula/FormulaParser.java b/src/java/org/apache/poi/ss/formula/FormulaParser.java index 5eafdfcca8..3b82daad91 100644 --- a/src/java/org/apache/poi/ss/formula/FormulaParser.java +++ b/src/java/org/apache/poi/ss/formula/FormulaParser.java @@ -382,9 +382,6 @@ public final class FormulaParser { if (token instanceof OperandPtg) { return false; } - if (token instanceof OperationPtg) { - return true; - } return false; } |