|
Nuxeo Enterprise Platform 5.4 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.nuxeo.ecm.core.storage.sql.jdbc.dialect.SQLStatement
public class SQLStatement
A SQL statement and some optional tags that condition execution.
Nested Class Summary | |
---|---|
static class |
SQLStatement.Tag
Tags that may condition execution of the statement. |
Field Summary | |
---|---|
static String |
CATEGORY
Category pseudo-tag |
static String |
DIALECT_WITH_NO_SEMICOLON
|
String |
sql
SQL statement |
List<SQLStatement.Tag> |
tags
Tags on the statement |
Constructor Summary | |
---|---|
SQLStatement(String sql,
List<SQLStatement.Tag> tags)
|
Method Summary | |
---|---|
static void |
execute(List<SQLStatement> statements,
Map<String,Serializable> properties,
JDBCConnection jdbc)
Executes a list of SQL statements, following the tags. |
static Map<String,List<SQLStatement>> |
read(String filename,
Map<String,List<SQLStatement>> statements)
Reads SQL statements from a text file. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String DIALECT_WITH_NO_SEMICOLON
public static final String CATEGORY
public final String sql
public final List<SQLStatement.Tag> tags
Constructor Detail |
---|
public SQLStatement(String sql, List<SQLStatement.Tag> tags)
Method Detail |
---|
public String toString()
toString
in class Object
public static Map<String,List<SQLStatement>> read(String filename, Map<String,List<SQLStatement>> statements) throws IOException
Statements have a category, and optional tags (that may condition execution).
#CATEGORY: mycat #TEST: SELECT foo from bar;
#CATEGORY: mycat #IF: emptyResult #IF: somethingEnabled INSERT INTO ...;An empty line terminates a statement.
IOException
public static void execute(List<SQLStatement> statements, Map<String,Serializable> properties, JDBCConnection jdbc) throws SQLException
SQLException
|
Nuxeo Enterprise Platform 5.4 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |