public static Expression deserialize(ByteBuffer byteBuffer) {
    short type = ReadWriteIOUtils.readShort(byteBuffer);

    Expression expression = null;
    switch (type) {
      case 1:
        expression = new ArithmeticBinaryExpression(byteBuffer);
        break;
      case 2:
        expression = new ArithmeticUnaryExpression(byteBuffer);
        break;
      case 3:
        expression = new LikePredicate(byteBuffer);
        break;
      case 4:
        expression = new InListExpression(byteBuffer);
        break;
      case 5:
        expression = new IsNotNullPredicate(byteBuffer);
        break;
      case 6:
        expression = new IsNullPredicate(byteBuffer);
        break;
      case 7:
        expression = new FunctionCall(byteBuffer);
        break;
      case 8:
        expression = new Identifier(byteBuffer);
        break;
      case 9:
        expression = new Cast(byteBuffer);
        break;
      case 10:
        expression = new GenericDataType(byteBuffer);
        break;
      case 11:
        expression = new BetweenPredicate(byteBuffer);
        break;
      case 12:
        expression = new InPredicate(byteBuffer);
        break;
      case 13:
        expression = new LogicalExpression(byteBuffer);
        break;
      case 14:
        expression = new NotExpression(byteBuffer);
        break;
      case 15:
        expression = new ComparisonExpression(byteBuffer);
        break;
      case 16:
        expression = new BinaryLiteral(byteBuffer);
        break;
      case 17:
        expression = new BooleanLiteral(byteBuffer);
        break;
      case 18:
        expression = new DecimalLiteral(byteBuffer);
        break;
      case 19:
        expression = new DoubleLiteral(byteBuffer);
        break;
      case 20:
        expression = new GenericLiteral(byteBuffer);
        break;
      case 21:
        expression = new LongLiteral(byteBuffer);
        break;
      case 22:
        expression = new NullLiteral(byteBuffer);
        break;
      case 23:
        expression = new StringLiteral(byteBuffer);
        break;
      case 24:
        expression = new SymbolReference(byteBuffer);
        break;
      case 25:
        expression = new CoalesceExpression(byteBuffer);
        break;
      case 26:
        expression = new SimpleCaseExpression(byteBuffer);
        break;
      case 27:
        expression = new SearchedCaseExpression(byteBuffer);
        break;
      case 28:
        expression = new WhenClause(byteBuffer);
        break;
      case 31:
        expression = new Row(byteBuffer);
        break;
      default:
        throw new IllegalArgumentException("Invalid expression type: " + type);
    }

    return expression;
  }
Accessible for {@link AstVisitor}, use {@link AstVisitor#process(Node, Object)} instead.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/relational/sql/ast/Expression.java