Class BooleanExpressionComplexityCheck.Context

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private boolean checking
      Should we perform check in current context or not.
      private int count
      Count of boolean operators.
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Context​(boolean checking)
      Creates new instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void checkCount​(DetailAST ast)
      Checks if we violate maximum allowed complexity.
      boolean isChecking()
      Getter for checking property.
      void visitBooleanOperator()
      Increases operator counter.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • checking

        private final boolean checking
        Should we perform check in current context or not. Usually false if we are inside equals() method.
      • count

        private int count
        Count of boolean operators.
    • Constructor Detail

      • Context

        private Context​(boolean checking)
        Creates new instance.
        Parameters:
        checking - should we check in current context or not.
    • Method Detail

      • isChecking

        public boolean isChecking()
        Getter for checking property.
        Returns:
        should we check in current context or not.
      • checkCount

        public void checkCount​(DetailAST ast)
        Checks if we violate maximum allowed complexity.
        Parameters:
        ast - a node we check now.