当前位置: 首页>>代码示例>>Java>>正文


Java ExpressionList.setExpressions方法代码示例

本文整理汇总了Java中net.sf.jsqlparser.expression.operators.relational.ExpressionList.setExpressions方法的典型用法代码示例。如果您正苦于以下问题:Java ExpressionList.setExpressions方法的具体用法?Java ExpressionList.setExpressions怎么用?Java ExpressionList.setExpressions使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在net.sf.jsqlparser.expression.operators.relational.ExpressionList的用法示例。


在下文中一共展示了ExpressionList.setExpressions方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: countSelectItem

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
/**
 * 获取jsqlparser中count的SelectItem
 *
 * @return
 */
private static List<SelectItem> countSelectItem() {
    if (CollectionUtils.isNotEmpty(countSelectItem)) {
        return countSelectItem;
    }
    Function function = new Function();
    function.setName("COUNT");
    List<Expression> expressions = new ArrayList<>();
    LongValue longValue = new LongValue(1);
    ExpressionList expressionList = new ExpressionList();
    expressions.add(longValue);
    expressionList.setExpressions(expressions);
    function.setParameters(expressionList);
    countSelectItem = new ArrayList<>();
    SelectExpressionItem selectExpressionItem = new SelectExpressionItem(function);
    countSelectItem.add(selectExpressionItem);
    return countSelectItem;
}
 
开发者ID:Caratacus,项目名称:mybatis-plus-mini,代码行数:23,代码来源:JsqlParserUtils.java

示例2: ExpressionList

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList ExpressionList() throws ParseException {
      ExpressionList retval = new ExpressionList();
      List expressions = new ArrayList();
      Expression expr = null;
  expr = Expression();
                      expressions.add(expr);
  label_18:
  while (true) {
    if (jj_2_22(2147483647)) {
      ;
    } else {
      break label_18;
    }
    jj_consume_token(79);
    expr = Expression();
                                             expressions.add(expr);
  }
              retval.setExpressions(expressions);
              {if (true) return retval;}
  throw new Error("Missing return statement in function");
}
 
开发者ID:UBOdin,项目名称:jsqlparser,代码行数:22,代码来源:CCJSqlParser.java

示例3: countSelectItem

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
/**
 * <p>
 * 获取jsqlparser中count的SelectItem
 * </p>
 */
private static List<SelectItem> countSelectItem() {
    Function function = new Function();
    function.setName("COUNT");
    List<Expression> expressions = new ArrayList<>();
    LongValue longValue = new LongValue(1);
    ExpressionList expressionList = new ExpressionList();
    expressions.add(longValue);
    expressionList.setExpressions(expressions);
    function.setParameters(expressionList);
    List<SelectItem> selectItems = new ArrayList<>();
    SelectExpressionItem selectExpressionItem = new SelectExpressionItem(function);
    selectItems.add(selectExpressionItem);
    return selectItems;
}
 
开发者ID:baomidou,项目名称:mybatis-plus,代码行数:20,代码来源:JsqlParserCountOptimize.java

示例4: countSelectItem

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
/**
 * 获取jsqlparser中count的SelectItem
 *
 * @return
 */
private static List<SelectItem> countSelectItem() {
    if (CollectionUtils.isNotEmpty(countSelectItem)) {
        return countSelectItem;
    }
    Function function = new Function();
    function.setName("COUNT");
    List<Expression> expressions = new ArrayList<Expression>();
    LongValue longValue = new LongValue(0);
    ExpressionList expressionList = new ExpressionList();
    expressions.add(longValue);
    expressionList.setExpressions(expressions);
    function.setParameters(expressionList);
    countSelectItem = new ArrayList<SelectItem>();
    SelectExpressionItem selectExpressionItem = new SelectExpressionItem(function);
    countSelectItem.add(selectExpressionItem);
    return countSelectItem;
}
 
开发者ID:baomidou,项目名称:hibernate-plus,代码行数:23,代码来源:SqlUtils.java

示例5: SQLExpressionList

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList SQLExpressionList() throws ParseException {ExpressionList retval = new ExpressionList();
        List expressions = new ArrayList();
        List comments = new ArrayList();
        Expression expr = null;
        Token tk = null;
    expr = Expression();
expressions.add(expr);
    label_18:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {
      case COMMA:{
        ;
        break;
        }
      default:
        jj_la1[107] = jj_gen;
        break label_18;
      }
      tk = jj_consume_token(COMMA);
if (tk.specialToken != null) {
      comments.add(tk.specialToken.image);
     } else {comments.add("");}
      expr = Expression();
expressions.add(expr);
    }
retval.setExpressions(expressions);
                retval.setCommentsComma(comments);
                {if ("" != null) return retval;}
    throw new Error("Missing return statement in function");
  }
 
开发者ID:marat-gainullin,项目名称:platypus-js,代码行数:31,代码来源:CCJSqlParser.java

示例6: SimpleExpressionList

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList SimpleExpressionList() throws ParseException {ExpressionList retval = new ExpressionList();
        List expressions = new ArrayList();
        List comments = new ArrayList();
        Expression expr = null;
        Token tk = null;
    expr = SimpleExpression();
expressions.add(expr);
    label_19:
    while (true) {
      switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {
      case COMMA:{
        ;
        break;
        }
      default:
        jj_la1[108] = jj_gen;
        break label_19;
      }
      tk = jj_consume_token(COMMA);
if (tk.specialToken != null) {
      comments.add(tk.specialToken.image);
     } else {comments.add("");}
      expr = SimpleExpression();
expressions.add(expr);
    }
retval.setExpressions(expressions);
                retval.setCommentsComma(comments);
                {if ("" != null) return retval;}
    throw new Error("Missing return statement in function");
  }
 
开发者ID:marat-gainullin,项目名称:platypus-js,代码行数:31,代码来源:CCJSqlParser.java

示例7: SQLExpressionList

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList SQLExpressionList() throws ParseException {
/* @bgen(jjtree) SQLExpressionList */
      SimpleNode jjtn000 = new SimpleNode(JJTSQLEXPRESSIONLIST);
      boolean jjtc000 = true;
      jjtree.openNodeScope(jjtn000);
      ExpressionList retval = new ExpressionList();
      List<Expression> expressions = new ArrayList<Expression>();
      Expression expr = null;
      try {
          expr = Expression();
          expressions.add(expr);
          label_38:
          while (true) {
              switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) {
                  case 165:
                      ;
                      break;
                  default:
                      jj_la1[185] = jj_gen;
                      break label_38;
              }
              jj_consume_token(165);
              expr = Expression();
              expressions.add(expr);
          }
          jjtree.closeNodeScope(jjtn000, true);
          jjtc000 = false;
          retval.setExpressions(expressions);
          {
              if (true)
                  return retval;
          }
      } catch (Throwable jjte000) {
          if (jjtc000) {
              jjtree.clearNodeScope(jjtn000);
              jjtc000 = false;
          } else {
              jjtree.popNode();
          }
          if (jjte000 instanceof RuntimeException) {
              {
                  if (true)
                      throw (RuntimeException) jjte000;
              }
          }
          if (jjte000 instanceof ParseException) {
              {
                  if (true)
                      throw (ParseException) jjte000;
              }
          }
          {
              if (true)
                  throw (Error) jjte000;
          }
      } finally {
          if (jjtc000) {
              jjtree.closeNodeScope(jjtn000, true);
          }
      }
      throw new Error("Missing return statement in function");
  }
 
开发者ID:WeiMei-Tian,项目名称:editor-sql,代码行数:63,代码来源:CCJSqlParser.java

示例8: SimpleExpressionList

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList SimpleExpressionList() throws ParseException {
/* @bgen(jjtree) SimpleExpressionList */
      SimpleNode jjtn000 = new SimpleNode(JJTSIMPLEEXPRESSIONLIST);
      boolean jjtc000 = true;
      jjtree.openNodeScope(jjtn000);
      ExpressionList retval = new ExpressionList();
      List<Expression> expressions = new ArrayList<Expression>();
      Expression expr = null;
      try {
          expr = SimpleExpression();
          expressions.add(expr);
          label_39:
          while (true) {
              switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) {
                  case 165:
                      ;
                      break;
                  default:
                      jj_la1[186] = jj_gen;
                      break label_39;
              }
              jj_consume_token(165);
              expr = SimpleExpression();
              expressions.add(expr);
          }
          jjtree.closeNodeScope(jjtn000, true);
          jjtc000 = false;
          retval.setExpressions(expressions);
          {
              if (true)
                  return retval;
          }
      } catch (Throwable jjte000) {
          if (jjtc000) {
              jjtree.clearNodeScope(jjtn000);
              jjtc000 = false;
          } else {
              jjtree.popNode();
          }
          if (jjte000 instanceof RuntimeException) {
              {
                  if (true)
                      throw (RuntimeException) jjte000;
              }
          }
          if (jjte000 instanceof ParseException) {
              {
                  if (true)
                      throw (ParseException) jjte000;
              }
          }
          {
              if (true)
                  throw (Error) jjte000;
          }
      } finally {
          if (jjtc000) {
              jjtree.closeNodeScope(jjtn000, true);
          }
      }
      throw new Error("Missing return statement in function");
  }
 
开发者ID:WeiMei-Tian,项目名称:editor-sql,代码行数:63,代码来源:CCJSqlParser.java

示例9: SimpleExpressionListAtLeastTwoItems

import net.sf.jsqlparser.expression.operators.relational.ExpressionList; //导入方法依赖的package包/类
final public ExpressionList SimpleExpressionListAtLeastTwoItems()
          throws ParseException {
/* @bgen(jjtree) SimpleExpressionListAtLeastTwoItems */
      SimpleNode jjtn000 = new SimpleNode(
              JJTSIMPLEEXPRESSIONLISTATLEASTTWOITEMS);
      boolean jjtc000 = true;
      jjtree.openNodeScope(jjtn000);
      ExpressionList retval = new ExpressionList();
      List<Expression> expressions = new ArrayList<Expression>();
      Expression expr = null;
      try {
          expr = SimpleExpression();
          expressions.add(expr);
          label_40:
          while (true) {
              jj_consume_token(165);
              expr = SimpleExpression();
              expressions.add(expr);
              switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) {
                  case 165:
                      ;
                      break;
                  default:
                      jj_la1[187] = jj_gen;
                      break label_40;
              }
          }
          jjtree.closeNodeScope(jjtn000, true);
          jjtc000 = false;
          retval.setExpressions(expressions);
          {
              if (true)
                  return retval;
          }
      } catch (Throwable jjte000) {
          if (jjtc000) {
              jjtree.clearNodeScope(jjtn000);
              jjtc000 = false;
          } else {
              jjtree.popNode();
          }
          if (jjte000 instanceof RuntimeException) {
              {
                  if (true)
                      throw (RuntimeException) jjte000;
              }
          }
          if (jjte000 instanceof ParseException) {
              {
                  if (true)
                      throw (ParseException) jjte000;
              }
          }
          {
              if (true)
                  throw (Error) jjte000;
          }
      } finally {
          if (jjtc000) {
              jjtree.closeNodeScope(jjtn000, true);
          }
      }
      throw new Error("Missing return statement in function");
  }
 
开发者ID:WeiMei-Tian,项目名称:editor-sql,代码行数:65,代码来源:CCJSqlParser.java


注:本文中的net.sf.jsqlparser.expression.operators.relational.ExpressionList.setExpressions方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。