You can annotate the String parameter of the logger method with the @NonNls annotation. Hard-coded string verification then ignores the lines present in the log calls. To add a comment, place the text cursor on the warning and press Alt+ Enterand select the Annotate option "xxx" as @NonNls.
source
share