
resources.report.rules.pmd.StringInstantiation.html Maven / Gradle / Ivy
StringInstantiation
StringInstantiation
Avoid instantiating String objects; this is usually unnecessary.
This rule is defined by the following Java class:
net.sourceforge.pmd.rules.strings.StringInstantiation
Example:
public class Foo {
private String bar = new String("bar"); // just do a String bar = "bar";
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy