code: public static Expression trimParentheses(Expression node) {
      while (node instanceof ParenthesizedExpression) {
        node = ((ParenthesizedExpression) node).getExpression();
      }
      return node;
    }
docs: Returns the first descendant of the given node that is not a ParenthesizedExpression.