public static ViewExpression deserialize(InputStream inputStream) {
    try {
      short type = ReadWriteIOUtils.readShort(inputStream);

      ViewExpression expression;
      switch (type) {
        case -4:
          expression = new ConstantViewOperand(inputStream);
          break;
        case -3:
          expression = new TimestampViewOperand(inputStream);
          break;
        case -2:
          expression = new TimeSeriesViewOperand(inputStream);
          break;
        case -1:
          expression = new FunctionViewExpression(inputStream);
          break;

        case 0:
          expression = new NegationViewExpression(inputStream);
          break;
        case 1:
          expression = new LogicNotViewExpression(inputStream);
          break;

        case 2:
          expression = new MultiplicationViewExpression(inputStream);
          break;
        case 3:
          expression = new DivisionViewExpression(inputStream);
          break;
        case 4:
          expression = new ModuloViewExpression(inputStream);
          break;

        case 5:
          expression = new AdditionViewExpression(inputStream);
          break;
        case 6:
          expression = new SubtractionViewExpression(inputStream);
          break;

        case 7:
          expression = new EqualToViewExpression(inputStream);
          break;
        case 8:
          expression = new NonEqualViewExpression(inputStream);
          break;
        case 9:
          expression = new GreaterEqualViewExpression(inputStream);
          break;
        case 10:
          expression = new GreaterThanViewExpression(inputStream);
          break;
        case 11:
          expression = new LessEqualViewExpression(inputStream);
          break;
        case 12:
          expression = new LessThanViewExpression(inputStream);
          break;

        case 13:
          expression = new LikeViewExpression(inputStream);
          break;
        case 14:
          expression = new RegularViewExpression(inputStream);
          break;

        case 15:
          expression = new IsNullViewExpression(inputStream);
          break;

        case 16:
          expression = new BetweenViewExpression(inputStream);
          break;

        case 17:
          expression = new InViewExpression(inputStream);
          break;

        case 18:
          expression = new LogicAndViewExpression(inputStream);
          break;

        case 19:
          expression = new LogicOrViewExpression(inputStream);
          break;

        case 20:
          expression = new NullViewOperand();
          break;
        default:
          throw new IllegalArgumentException("Invalid viewExpression type: " + type);
      }
      return expression;
    } catch (IOException e) {
      throw new RuntimeException(e);
    }
  }
@return if this view expression could be a source for an ALIAS series (one kind of view),
    return true; else return false. Foe example, a SINGLE TimeSeriesOperand could be a source
    for an alias view.
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/schema/view/viewExpression/ViewExpression.java