|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jpox.store.rdbms.request.Request
Base class representing a request to perform an action on the datastore. All requests have 2 methods - constructor and execute. Currently they build an SQL statement and execute it.
Field Summary | |
protected PrimaryKey |
key
|
protected static Localiser |
LOCALISER
Localisation of messages. |
protected DatastoreClass |
table
|
Constructor Summary | |
Request(DatastoreClass table)
Constructor, taking the table to use for the request. |
Method Summary | |
abstract void |
execute(StateManager sm)
Method to execute the request - to be implemented by deriving classes. |
java.sql.ResultSet |
executeQuery(java.lang.String jdbcText,
java.sql.PreparedStatement ps)
Convenience wrapper for executing a JDBC update. |
void |
executeUpdate(java.lang.String jdbcText,
java.sql.PreparedStatement ps)
Convenience wrapper for executing a JDBC update. |
static java.lang.String |
replaceParamPlaceholdersWithValues(java.lang.String jdbcText,
java.sql.PreparedStatement ps)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected static final Localiser LOCALISER
protected final DatastoreClass table
protected final PrimaryKey key
Constructor Detail |
public Request(DatastoreClass table)
table
- The Table to use for the request.Method Detail |
public abstract void execute(StateManager sm)
sm
- The StateManager for the object in question.public void executeUpdate(java.lang.String jdbcText, java.sql.PreparedStatement ps) throws java.sql.SQLException
jdbcText
- The statement textps
- The PreparedStatement
java.sql.SQLException
- Thrown if an error occurs in the updatepublic java.sql.ResultSet executeQuery(java.lang.String jdbcText, java.sql.PreparedStatement ps) throws java.sql.SQLException
jdbcText
- The statement textps
- The PreparedStatement
java.sql.SQLException
- Thrown if an error occurs in the updatepublic static java.lang.String replaceParamPlaceholdersWithValues(java.lang.String jdbcText, java.sql.PreparedStatement ps)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |