|
jxDBCon 0.9z | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.sourceforge.jxdbcon.postgresql.NetProtocol | +--org.sourceforge.jxdbcon.postgresql.NetProtocolV1
The PGProtocolV1 is the protocol implementation for V1. The V1 protocol is used by PostgresSQL v6.3.x
Nested Class Summary | |
(package private) class |
NetProtocolV1.AsciiRow
Fetch a query result row in text form. |
(package private) class |
NetProtocolV1.Authentication
Fetch the authentication response. |
(package private) class |
NetProtocolV1.BinaryRow
Fetch a query result row in binary form. |
(package private) class |
NetProtocolV1.CompletedResponse
Fetch the completed response. |
(package private) class |
NetProtocolV1.CursorResponse
Fetch the cursor name response. |
(package private) class |
NetProtocolV1.EmptyQueryResponse
Fetch the empty query response. |
(package private) static class |
NetProtocolV1.EmptyResponse
Abstract base class for empty content responses. |
(package private) class |
NetProtocolV1.ErrorResponse
Fetch the error response. |
(package private) class |
NetProtocolV1.FunctionResult
Fetch the function result response. |
(package private) class |
NetProtocolV1.MessageResponse
Abstract base class for one-string messages. |
(package private) class |
NetProtocolV1.NoticeResponse
Fetch the notice response. |
(package private) class |
NetProtocolV1.NotificationResponse
Fetch the notification response. |
(package private) static class |
NetProtocolV1.Response
Abstract base class for the messages sent by the backend. |
(package private) class |
NetProtocolV1.RowDescription
Fetch the row description response. |
Field Summary | |
protected int |
nFields
State variable holding the number of fields in the current query. |
Fields inherited from class org.sourceforge.jxdbcon.postgresql.NetProtocol |
copyInStream, copyOutStream, in, lock, messageEncoding, out, socket |
Fields inherited from interface org.sourceforge.jxdbcon.postgresql.PGConstants |
AUTH_REQ_CRYPT, AUTH_REQ_KRB4, AUTH_REQ_KRB5, AUTH_REQ_MD5, AUTH_REQ_OK, AUTH_REQ_PASSWORD, AUTH_REQ_SCM, NUMERIC_DSCALE_MASK, NUMERIC_NAN, NUMERIC_NEG, NUMERIC_POS, NUMERIC_SIGN_MASK, PG_VERSION_STR, PG_VERSION_STR1, TRIGGER_TYPE_BEFORE, TRIGGER_TYPE_DELETE, TRIGGER_TYPE_INSERT, TRIGGER_TYPE_ROW, TRIGGER_TYPE_UPDATE |
Fields inherited from interface org.sourceforge.jxdbcon.postgresql.PGInfoKeys |
FORCECLIENTENC, OPTIONS, PROTOVERSION, SETTIMEZONE, STRICTSCHEMA, TTY, USEASYNC, USECLIENTENC, USEDBENC, USESSL |
Fields inherited from interface org.sourceforge.jxdbcon.InfoKeys |
CATALOG, DESCRIPTION, DRIVER, HOST, PASSWORD, PORT, SUBDRIVER, USER |
Constructor Summary | |
NetProtocolV1()
|
Method Summary | |
private static void |
copyStream(InputStream from,
OutputStream to)
Copy the stream data used by COPY IN/OUT statements. |
protected NetProtocolV1.Response |
dispatch(int ch)
Identify the message by the transmitted first character. |
protected NetProtocolV1.Response |
readFirst()
Read the first/next response from the backend. |
protected void |
sendClose()
Send the close command. |
protected void |
sendFunctionCall(long funcOid,
byte[][] param)
Send a function call. |
protected void |
sendPassword(byte[] password)
Send a password. |
protected void |
sendQuery(byte[] query)
Send a query. |
protected void |
sendStartup(int major,
int minor,
String catalog,
String user,
String pgoptions,
String pgtty)
Send a generic startup packet. |
protected void |
sendStartup(String catalog,
String user,
String pgoptions,
String pgtty)
Send the V1 startup packet. |
Methods inherited from class org.sourceforge.jxdbcon.postgresql.NetProtocol |
connectSocket, limString, readCString, setCopyInStream, setCopyOutStream, setMessageEncoding |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.sourceforge.jxdbcon.postgresql.PGProtocol |
close, connect, exec, requestCancel |
Field Detail |
protected int nFields
Constructor Detail |
public NetProtocolV1()
Method Detail |
private static void copyStream(InputStream from, OutputStream to) throws IOException
IOException
protected NetProtocolV1.Response dispatch(int ch) throws IOException
IOException
protected NetProtocolV1.Response readFirst() throws InterruptedException, IOException
InterruptedException
- if the operation was interrupted
EOFException
- if the end of the stream was found
IOException
- if any other IO problem occuredprotected void sendClose() throws IOException
IOException
protected void sendFunctionCall(long funcOid, byte[][] param) throws IOException
IOException
protected void sendPassword(byte[] password) throws IOException
IOException
protected void sendQuery(byte[] query) throws IOException
IOException
protected void sendStartup(int major, int minor, String catalog, String user, String pgoptions, String pgtty) throws IOException
IOException
protected void sendStartup(String catalog, String user, String pgoptions, String pgtty) throws IOException
IOException
|
jxDBCon 0.9z | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |