MCPcopy Create free account
hub / github.com/Nemo1870/sql-parse / Update

Class Update

src/main/java/com/sql/parse/statement/Update.java:12–87  ·  view source on GitHub ↗

@date 2019年4月30日上午09:58:02 @desc Update语法操作类

Source from the content-addressed store, hash-verified

10 * @desc Update语法操作类
11 */
12public abstract class Update extends Statement {
13 @Override
14 public abstract String getSql(boolean safe);
15
16 /**
17 * @title: addColumn
18 * @desc 新增update数据
19 */
20 public abstract Update addColumn(UpdateItem updateItem);
21
22 public abstract Update addColumn(String column, String value);
23
24 /**
25 * @title: where
26 * @desc "WHERE"符号
27 */
28 public abstract Update where(String expr);
29
30 /**
31 * @title: and
32 * @desc 移除where条件
33 */
34 public abstract Update removeAllWhere();
35
36 /**
37 * @title: and
38 * @desc "AND"符号
39 */
40 public abstract Update and(String expr);
41
42 /**
43 * @title: or
44 * @desc "OR"符号
45 */
46 public abstract Update or(String expr);
47
48 /**
49 * @title: orderBy
50 * @desc "ORDER BY"符号
51 *//*
52 public abstract Update orderBy(String... columnNames);
53
54 public abstract Update orderBy(OrderByItem... orderByItems);*/
55
56 /**
57 * @title: limit
58 * @desc "LIMIT"符号
59 *//*
60 public abstractUpdate limit(int offset, int rows);*/
61
62 /**
63 * @title: parse
64 * @desc Update解析器
65 */
66 public static Update parse(String sql) {
67 switch (SqlParseConfig.getHandle()) {
68 case "com.github.jsqlparser":{
69 try {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected