Class VerificationProperties

java.lang.Object
org.pgcodekeeper.core.parsers.antlr.base.verification.VerificationProperties

public class VerificationProperties extends Object
Configuration properties for code verification rules. Manages various verification settings including complexity limits, formatting rules, and style preferences for database code analysis.
  • Constructor Details

    • VerificationProperties

      public VerificationProperties(Properties properties)
      Creates a new verification properties instance from a Properties object.
      Parameters:
      properties - the properties object containing verification configuration
  • Method Details

    • getMaxCyclomaticComplexity

      public int getMaxCyclomaticComplexity()
      Returns the maximum allowed cyclomatic complexity for functions.
      Returns:
      maximum cyclomatic complexity limit, or -1 if not set
    • getMaxFunctionLenght

      public int getMaxFunctionLenght()
      Returns the maximum allowed length for functions.
      Returns:
      maximum function length limit, or -1 if not set
    • getMaxFunctionParams

      public int getMaxFunctionParams()
      Returns the maximum allowed number of parameters for functions.
      Returns:
      maximum function parameters limit, or -1 if not set
    • getIndentSize

      public int getIndentSize()
      Returns the expected indentation size in spaces.
      Returns:
      indentation size in spaces
    • getMethodCount

      public int getMethodCount()
    • isCheckCaseWithElse

      public boolean isCheckCaseWithElse()
    • isCheckTempTable

      public boolean isCheckTempTable()
    • isCheckSpaceOnMath

      public boolean isCheckSpaceOnMath()
    • isCheckSemicolonAfterSimpleSql

      public boolean isCheckSemicolonAfterSimpleSql()
    • isCheckSpaceAfterIf

      public boolean isCheckSpaceAfterIf()
    • isCheckQuotesInTableColumn

      public boolean isCheckQuotesInTableColumn()
    • isCheckIndents

      public boolean isCheckIndents()
    • isSpaceAfterComma

      public boolean isSpaceAfterComma()
    • getAllowedFunctionStart

      public List<String> getAllowedFunctionStart()
    • getDeniedUsers

      public List<String> getDeniedUsers()
    • readProperties

      public static VerificationProperties readProperties(Path path) throws IOException
      Reads verification properties from a file.
      Parameters:
      path - the path to the properties file
      Returns:
      a new VerificationProperties instance loaded from the file
      Throws:
      IOException - if an error occurs reading the file