Class JavaPropertiesHelper


  • public class JavaPropertiesHelper
    extends Object
    • Method Detail

      • retrievedPropertyDefaultValue

        @CheckForNull
        public static org.sonar.plugins.java.api.tree.ExpressionTree retrievedPropertyDefaultValue​(org.sonar.plugins.java.api.tree.ExpressionTree expression)
        If the provided expression is an IdentifierTree or a MethodInvocationTree, it will check if it used to retrieve a property with a default value provided (using Properties.getProperty(String, String)).
        Parameters:
        expression -
        Returns:
        null The default value of the getProperty method invocation, or null if the expression is not of the expected kind or if is not used to retrieve a property with a default value. .