public static String getPropertyForSetter ( String setterName ) { if ( setterName == null || setterName . length ( ) == 0 ) return null ; if ( setterName . startsWith ( "set" ) ) { String prop = setterName . substring ( 3 ) ; return convertValidPropertyMethodSuffix ( prop ) ; } return null ; }
Returns a property name equivalent for the given setter name or null if it is not a valid setter . If not null or empty the setter name is assumed to be a valid identifier .