forked from phoedos/pmd
+contribution credit
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@7307 51baf565-9d33-0410-a72c-fc3788e3496d
This commit is contained in:
@ -319,6 +319,7 @@ Rules can now be flagged with deprecated='true' in the RuleSet XML to allow the
|
||||
XPathRules can now query using XPath 2.0 with 'version=2.0"', or XPath 2.0 in XPath 1.0 compatibility mode using 'version="1.0 compatibility"'. Many thanks to Saxon!
|
||||
Rules can now use property values in messages, for example ${propertyName} will expand to the value of the 'propertyName' property on the Rule.
|
||||
Rules can now use violation specific values in messages, specifically ${variableName}, ${methodName}, ${className}, ${packageName}.
|
||||
New XPath function 'getCommentOn' can be used to search for strings in comments - Thanks to Andy Throgmorton
|
||||
|
||||
Other changes:
|
||||
Rule property API upgrades:
|
||||
|
@ -14,7 +14,9 @@ import org.jaxen.SimpleFunctionContext;
|
||||
import org.jaxen.XPathFunctionContext;
|
||||
|
||||
/**
|
||||
*
|
||||
* The XPath query "//VariableDeclarator[contains(getCommentOn(), '//password')]"
|
||||
* will find all variables declared that are annotated with the password comment.
|
||||
*
|
||||
* @author Andy Throgmorton
|
||||
*/
|
||||
public class GetCommentOnFunction implements Function {
|
||||
|
Reference in New Issue
Block a user