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


Java Delete.setTable方法代码示例

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


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

示例1: visit

import net.sf.jsqlparser.statement.delete.Delete; //导入方法依赖的package包/类
/**
 * mysql 'delete' doesn't support alais
 */
@Override
public void visit(Delete delete) {
    if (enableLimitCheck && delete.getLimit() == null) {
        throw new IllegalStateException("no limit in sql: " + sql);
    }
    this.getStack().push(new FrameContext());
    ShardRouteConfig routeConfig = shardRouter.getRouteConfig(delete.getTable().getSchemaName(),
                                                              delete.getTable().getName());
    if (routeConfig != null) {
        TableWrapper tab = new TableWrapper(delete.getTable(), routeConfig);
        delete.setTable(tab);
        addRoutedTableIntoContext(tab, routeConfig, false);
    }
    super.visit(delete);
    afterVisitBaseStatement();
}
 
开发者ID:hellojavaer,项目名称:ddal,代码行数:20,代码来源:JSQLParserAdapter.java

示例2: Delete

import net.sf.jsqlparser.statement.delete.Delete; //导入方法依赖的package包/类
final public Delete Delete() throws ParseException {
      Delete delete = new Delete();
      Table table = null;
      Expression where = null;
  jj_consume_token(K_DELETE);
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case K_FROM:
    jj_consume_token(K_FROM);
    break;
  default:
    jj_la1[17] = jj_gen;
    ;
  }
  table = TableWithAlias();
  switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
  case K_WHERE:
    where = WhereClause();
                         delete.setWhere(where);
    break;
  default:
    jj_la1[18] = jj_gen;
    ;
  }
      delete.setTable(table);
      {if (true) return delete;}
  throw new Error("Missing return statement in function");
}
 
开发者ID:UBOdin,项目名称:jsqlparser,代码行数:28,代码来源:CCJSqlParser.java

示例3: Delete

import net.sf.jsqlparser.statement.delete.Delete; //导入方法依赖的package包/类
final public Delete Delete() throws ParseException {Delete delete = new Delete();
        Table table = null;
        Alias alias = null;
        Expression where = null;
        Token tk = null;
    //<K_DELETE> [<K_FROM>] table=TableWithAlias()
        tk = jj_consume_token(K_DELETE);
if (tk.specialToken != null) {
       delete.setComment(tk.specialToken.image);
     }
    switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {
    case K_FROM:{
      tk = jj_consume_token(K_FROM);
if (tk.specialToken != null) {
       delete.setFromComment(tk.specialToken.image);
     }
      break;
      }
    default:
      jj_la1[16] = jj_gen;
      ;
    }
    table = Table();
    switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {
    case K_AS:
    case S_IDENTIFIER:
    case S_QUOTED_IDENTIFIER:{
      alias = Alias();
table.setAlias(alias);
      break;
      }
    default:
      jj_la1[17] = jj_gen;
      ;
    }
    switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {
    case K_WHERE:{
      tk = jj_consume_token(K_WHERE);
if (tk.specialToken != null) {
       delete.setWhereComment(tk.specialToken.image);
      }
      where = WhereClause();
delete.setWhere(where);
      break;
      }
    default:
      jj_la1[18] = jj_gen;
      ;
    }
delete.setTable(table);
        {if ("" != null) return delete;}
    throw new Error("Missing return statement in function");
  }
 
开发者ID:marat-gainullin,项目名称:platypus-js,代码行数:54,代码来源:CCJSqlParser.java


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