Class AppendCharacterWithCharRule

java.lang.Object
net.sourceforge.pmd.properties.AbstractPropertySource
net.sourceforge.pmd.lang.rule.AbstractRule
net.sourceforge.pmd.lang.java.rule.AbstractJavaRule
net.sourceforge.pmd.lang.java.rule.AbstractJavaRulechainRule
net.sourceforge.pmd.lang.java.rule.performance.AppendCharacterWithCharRule
All Implemented Interfaces:
net.sourceforge.pmd.lang.ast.AstVisitor, JavaVisitor, net.sourceforge.pmd.lang.rule.Rule, net.sourceforge.pmd.properties.PropertySource

public class AppendCharacterWithCharRule extends AbstractJavaRulechainRule
This rule finds the following:
 StringBuffer.append("c"); // appends a single character
 

It is preferable to use

StringBuffer.append('c'); // appends a single character
See Also:
  • Constructor Details

    • AppendCharacterWithCharRule

      public AppendCharacterWithCharRule()
  • Method Details