public class ParameterisedExecutor extends AbstractDestination<java.lang.String> implements ArooaSessionAware
Constructor and Description |
---|
ParameterisedExecutor() |
Modifier and Type | Method and Description |
---|---|
boolean |
add(java.lang.String sql) |
void |
execute(java.lang.String sql)
Execute the SQL statement.
|
DatabaseDialect |
getDialect() |
int |
getExecutedSQLCount()
Getter for executedSQLCount.
|
ValueType |
getParameters(int index)
Get parameter by index.
|
int |
getSuccessfulSQLCount()
Getter for successful SQL count.
|
boolean |
isAutocommit()
Getter for autocommit.
|
boolean |
isCallable()
Getter for callable statement flag.
|
boolean |
isEscapeProcessing()
Getter for escapeProcessing.
|
void |
setArooaSession(ArooaSession session)
Accept the current Arooa Session.
|
void |
setAutocommit(boolean autocommit)
Auto commit flag for database connection;
optional, default false.
|
void |
setBeanBus(BusConductor busConductor) |
void |
setCallable(boolean callable)
Setter for callable statement flag.
|
void |
setConnection(java.sql.Connection connection)
Set the connection to use.
|
void |
setDialect(DatabaseDialect dialect) |
void |
setEscapeProcessing(boolean escapeProcessing)
Setter for escapeProcessing.
|
void |
setParameters(int index,
ValueType parameter)
Set parameter by index.
|
void |
setResultProcessor(SQLResultHandler processor)
Set the result processor.
|
addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public void setArooaSession(ArooaSession session)
ArooaSessionAware
setArooaSession
in interface ArooaSessionAware
session
- The Arooa Session. Never null.public boolean add(java.lang.String sql)
add
in interface java.util.Collection<java.lang.String>
public void execute(java.lang.String sql) throws java.sql.SQLException, ArooaConversionException, BusException, java.lang.ClassNotFoundException
sql
- the SQL statement to executejava.sql.SQLException
- on SQL problemsConversionFailedException
NoConversionAvailableException
BusException
java.lang.ClassNotFoundException
ArooaConversionException
@Inject public void setBeanBus(BusConductor busConductor)
public void setResultProcessor(SQLResultHandler processor)
processor
- The result processor to pass results to.public void setConnection(java.sql.Connection connection)
connection
- The connection.public void setAutocommit(boolean autocommit)
autocommit
- The autocommit to setpublic boolean isAutocommit()
public boolean isEscapeProcessing()
public void setEscapeProcessing(boolean escapeProcessing)
escapeProcessing
- escapeProcessing flag.public ValueType getParameters(int index) throws java.lang.IndexOutOfBoundsException
index
- The index.java.lang.IndexOutOfBoundsException
public void setParameters(int index, ValueType parameter) throws java.lang.IndexOutOfBoundsException
index
- The index.parameter
- The parameter. Null to remove.java.lang.IndexOutOfBoundsException
public boolean isCallable()
public void setCallable(boolean callable)
callable
- The callable flag.public int getExecutedSQLCount()
public int getSuccessfulSQLCount()
public DatabaseDialect getDialect()
public void setDialect(DatabaseDialect dialect)