This rule is defined by the following Java class: net.sourceforge.pmd.rules.BeanMembersShouldSerializeRule
Example:
private transient int someFoo;//good, it's transient private static int otherFoo;// also OK private int moreFoo;// OK, has proper accessors, see below private int badFoo;//bad, should be marked transient private void setMoreFoo(int moreFoo){ this.moreFoo = moreFoo; } private int getMoreFoo(){ return this.moreFoo; }
This rule has the following properties:
Name | Default value | Description |
---|---|---|
prefix | A variable prefix to skip, i.e., m_ |