| Constructor Summary | |
|---|---|
| public |
(DPQConnect connect) Creates a new DPQExec |
| Methods Summary | |
|---|---|
| void |
begin() |
| void |
rollback() |
| void |
commit() |
| static String |
escapeString(String str) Quoting strings before inclusion in queries. |
| String |
errorMessage() |
| String |
escapeBytea(String bintext, int length) Quoting bytes before inclusion in queries. |
| String |
unescapeBytea(String strtext) UnQuoting bytes. |
| int |
execute(char statement) |
| int |
execute(String statement) |
| DPQResult |
exec(char query) execute simple synchronous query |
| DPQResult |
exec(String query) |
| PGnotify* |
notifies() Notifies \todo do we need a Notify class ??? |
| void |
freeNotify(PGnotify* notify) Frees a struct got from notifies |
| int |
prepare(char statement) |
| int |
prepare(String statement) |
| bit |
sendQuery(String query) /* Interface for multiple-result or asynchronous queries sendQuery Submit a command to the server without waiting for the result(s). |
| DPQResult |
getResult() Wait for the next result from a prior sendQuery, and return it. |
| ResultSet |
getResultSet(char statement) |
| ResultSet |
getResultSet(String statement) |
| bit |
isBusy() Returns true if a query is busy, that is, getResult would block waiting for input. |
| int |
consumeInput() If input is available from the backend, consume it. |
| int |
finish() |
| int |
getLine(String string, int length) /* Routines for copy in/out Get line |
| int |
putLine(String string) putLine |
| int |
getLineAsync(String buffer, int bufsize) getLineAsync |
| int |
putNBytes(String buffer, int nbytes) put n bytes |
| int |
endCopy() end copy |
| int |
setNonBlocking(bit arg) /* Set blocking/nonblocking connection to the backend Sets the state of the connection to nonblocking if arg is 1, blocking if arg is 0. |
| bit |
isNonBlocking() Returns the blocking status of the database connection. |
| int |
flush() /* Force the write buffer to be written (or at least try) Attempt to flush any data queued to the backend, PQflush needs to be called on a nonblocking connection before calling select() to determine if a response has arrived. |