class ASTAndCondition extends ASTAggregatedCondition {

  public ASTAndCondition(ASTCondition left, ASTCondition right) {
    super(left, right);
  }

  public void apply(Analysis a) {
    a.caseASTAndCondition(this);
  }

  public String toString() {
    if (left instanceof ASTUnaryBinaryCondition) {
      if (right instanceof ASTUnaryBinaryCondition) {
        if (not) {
          return "!(" + left.toString() + " && " + right.toString() + ")";
        } else {
          return left.toString() + " && " + right.toString();
        }
      } else { // right is ASTAggregatedCondition
        if (not) {
          return "!(" + left.toString() + " && (" + right.toString() + " ))";
        } else {
          return left.toString() + " && (" + right.toString() + " )";
        }
      }
    } else { // left is ASTAggregatedCondition
      if (right instanceof ASTUnaryBinaryCondition) {
        if (not) {
          return "!(( " + left.toString() + ") && " + right.toString() + ")";
        } else {
          return "( " + left.toString() + ") && " + right.toString();
        }
      } else { // right is ASTAggregatedCondition also
        if (not) {
          return "!(( " + left.toString() + ") && (" + right.toString() + " ))";
        } else {
          return "( " + left.toString() + ") && (" + right.toString() + " )";
        }
      }
    }
  }

  public void toString(UnitPrinter up) {<FILL_FUNCTION_BODY>}

}

    if (up instanceof DavaUnitPrinter) {

      if (not) {
        // print !
        ((DavaUnitPrinter) up).addNot();
        // print left paren
        ((DavaUnitPrinter) up).addLeftParen();
      }

      if (left instanceof ASTUnaryBinaryCondition) {
        if (right instanceof ASTUnaryBinaryCondition) {

          left.toString(up);

          ((DavaUnitPrinter) up).addAggregatedAnd();

          right.toString(up);
        } else { // right is ASTAggregatedCondition

          left.toString(up);

          ((DavaUnitPrinter) up).addAggregatedAnd();

          ((DavaUnitPrinter) up).addLeftParen();
          right.toString(up);
          ((DavaUnitPrinter) up).addRightParen();
        }
      } else { // left is ASTAggregatedCondition
        if (right instanceof ASTUnaryBinaryCondition) {

          ((DavaUnitPrinter) up).addLeftParen();
          left.toString(up);
          ((DavaUnitPrinter) up).addRightParen();

          ((DavaUnitPrinter) up).addAggregatedAnd();

          right.toString(up);
        } else { // right is ASTAggregatedCondition also

          ((DavaUnitPrinter) up).addLeftParen();
          left.toString(up);
          ((DavaUnitPrinter) up).addRightParen();

          ((DavaUnitPrinter) up).addAggregatedAnd();

          ((DavaUnitPrinter) up).addLeftParen();
          right.toString(up);
          ((DavaUnitPrinter) up).addRightParen();
        }
      }

      if (not) {
        // print right paren
        ((DavaUnitPrinter) up).addRightParen();
      }
    } else {
      throw new RuntimeException();
    }
  
<methods>public void <init>(soot.dava.internal.AST.ASTCondition, soot.dava.internal.AST.ASTCondition) ,public void flip() ,public soot.dava.internal.AST.ASTCondition getLeftOp() ,public soot.dava.internal.AST.ASTCondition getRightOp() ,public boolean isNotted() ,public void setLeftOp(soot.dava.internal.AST.ASTCondition) ,public void setRightOp(soot.dava.internal.AST.ASTCondition) <variables>soot.dava.internal.AST.ASTCondition left,boolean not,soot.dava.internal.AST.ASTCondition right