public class CreateParser extends Object implements SQLParser<CreateStatement,CreateStatementBuilder>
The SQL parser of the database create statement will parse the information about the statement, encapsulate it into an object, and provide functions to transfer data to the outside world.
| 构造器和说明 |
|---|
CreateParser() |
| 限定符和类型 | 方法和说明 |
|---|---|
static CreateParser |
getInstance()
获取到全局唯一的解析器对象,通过该函数,可以从管理者中获取到该解析器对象,如果管理者中不存在,该函数会在管理者中注册一个新组件。
|
String |
getName() |
CreateStatement |
parseSql(String sql)
开始解析一个sql语句
|
CreateStatement |
parseSqlByWord(CreateStatementBuilder createStatementBuilder,
int startIndex,
String sql,
String sqlWord)
解析一个sql语句中的指定sql解析词相关的子sql语句
|
public static CreateParser getInstance()
Get the globally unique parser object. With this function, you can get the parser object from the manager. If the manager does not exist, this function will register a new component in the manager.
public String getName()
getName 在接口中 SQLParser<CreateStatement,CreateStatementBuilder>Get the name of the parser, which is also used for the registration of the component in the manager, so you can also get the component object through the manager
public CreateStatement parseSql(String sql)
parseSql 在接口中 SQLParser<CreateStatement,CreateStatementBuilder>sql - 需要被解析的sql语句public CreateStatement parseSqlByWord(CreateStatementBuilder createStatementBuilder, int startIndex, String sql, String sqlWord)
parseSqlByWord 在接口中 SQLParser<CreateStatement,CreateStatementBuilder>createStatementBuilder - 累计的sql语句结果startIndex - 解析词开始出现的索引位置sql - 完整的sql语句sqlWord - 需要被解析的sql解析词Copyright © 2022. All rights reserved.