From 83398660de4521428a693aacbfe66c89547ed2e4 Mon Sep 17 00:00:00 2001 From: Javen O'Neal Date: Fri, 4 Dec 2015 10:54:21 +0000 Subject: [PATCH] FindBugs warning: ExcelStyleDateFormatter doesn't override java.text.SimpleDAtaFormat.equals(Object) git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1717930 13f79535-47bb-0310-9956-ffa450edef68 --- .../poi/ss/usermodel/ExcelStyleDateFormatter.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/java/org/apache/poi/ss/usermodel/ExcelStyleDateFormatter.java b/src/java/org/apache/poi/ss/usermodel/ExcelStyleDateFormatter.java index 2ea273f951..3e40fe5c7d 100644 --- a/src/java/org/apache/poi/ss/usermodel/ExcelStyleDateFormatter.java +++ b/src/java/org/apache/poi/ss/usermodel/ExcelStyleDateFormatter.java @@ -179,4 +179,14 @@ public class ExcelStyleDateFormatter extends SimpleDateFormat { return new StringBuffer(s); } + + @Override + public boolean equals(Object o) { + if (!(o instanceof ExcelStyleDateFormatter)) { + return false; + } + + ExcelStyleDateFormatter other = (ExcelStyleDateFormatter) o; + return dateToBeFormatted == other.dateToBeFormatted; + } } -- 2.39.5