From 3090cf0dab48c9119becc1f4fcd65c625119bfad Mon Sep 17 00:00:00 2001 From: Thomas Jensen Date: Fri, 12 Jun 2015 20:18:18 +0200 Subject: [PATCH] FileContents.getFileName() - resolve issue #1205 --- config/findbugs-exclude.xml | 8 ++++++++ pom.xml | 2 +- .../puppycrawl/tools/checkstyle/api/FileContents.java | 10 ++++++++++ 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/config/findbugs-exclude.xml b/config/findbugs-exclude.xml index 67a01f22a..6e4636f25 100644 --- a/config/findbugs-exclude.xml +++ b/config/findbugs-exclude.xml @@ -73,6 +73,14 @@ + + + + + + + + diff --git a/pom.xml b/pom.xml index 3fa6d9acb..f1b8d186d 100644 --- a/pom.xml +++ b/pom.xml @@ -717,7 +717,7 @@ .*.api.Check10086 .*.api.Comment10095 .*.api.DetailAST9598 - .*.api.FileContents9694 + .*.api.FileContents9693 .*.api.FileText5059 .*.api.FullIdent8396 .*.api.JavadocTagInfo2577 diff --git a/src/main/java/com/puppycrawl/tools/checkstyle/api/FileContents.java b/src/main/java/com/puppycrawl/tools/checkstyle/api/FileContents.java index a1a55d67b..589cc87fb 100644 --- a/src/main/java/com/puppycrawl/tools/checkstyle/api/FileContents.java +++ b/src/main/java/com/puppycrawl/tools/checkstyle/api/FileContents.java @@ -251,6 +251,16 @@ public final class FileContents implements CommentListener { return fileName; } + /** + * Getter. + * @return the name of the file + * @deprecated use {@link #getFileName} instead + */ + @Deprecated + public String getFilename() { + return getFileName(); + } + /** * Checks if the specified line is blank. * @param lineNo the line number to check