Package com.mckoi.database.jdbcserver
Class TCPJDBCServerConnection
- java.lang.Object
-
- com.mckoi.database.jdbcserver.JDBCProcessor
-
- com.mckoi.database.jdbcserver.StreamJDBCServerConnection
-
- com.mckoi.database.jdbcserver.TCPJDBCServerConnection
-
- All Implemented Interfaces:
ProtocolConstants
,ServerConnection
final class TCPJDBCServerConnection extends StreamJDBCServerConnection
A ServerConnection that processes JDBC queries from a client from a TCP Socket.
-
-
Field Summary
Fields Modifier and Type Field Description private java.net.Socket
connection
The socket connection with the client.private boolean
is_closed
Is set to true when the connection to the client is closed.-
Fields inherited from interface com.mckoi.database.jdbc.ProtocolConstants
ACKNOWLEDGEMENT, AUTHENTICATION_ERROR, CLOSE, DATABASE_EVENT, DISPOSE_RESULT, DISPOSE_STREAMABLE_OBJECT, EXCEPTION, FAILED, PING, PUSH_STREAMABLE_OBJECT_PART, QUERY, RESULT_SECTION, SERVER_REQUEST, STREAMABLE_OBJECT_SECTION, SUCCESS, USER_AUTHENTICATION_FAILED, USER_AUTHENTICATION_PASSED
-
-
Constructor Summary
Constructors Constructor Description TCPJDBCServerConnection(DatabaseInterface db_interface, java.net.Socket socket, DebugLogger logger)
Constructs the ServerConnection object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Completely closes the connection to the client.boolean
isClosed()
Returns true if the connection to the client has been closed.-
Methods inherited from class com.mckoi.database.jdbcserver.StreamJDBCServerConnection
blockForRequest, ping, processRequest, requestPending, sendEvent
-
Methods inherited from class com.mckoi.database.jdbcserver.JDBCProcessor
dispose, finalize, getState, printByteArray, processJDBCCommand
-
-
-
-
Constructor Detail
-
TCPJDBCServerConnection
TCPJDBCServerConnection(DatabaseInterface db_interface, java.net.Socket socket, DebugLogger logger) throws java.io.IOException
Constructs the ServerConnection object.- Throws:
java.io.IOException
-
-
Method Detail
-
close
public void close() throws java.io.IOException
Completely closes the connection to the client.- Specified by:
close
in interfaceServerConnection
- Specified by:
close
in classJDBCProcessor
- Throws:
java.io.IOException
-
isClosed
public boolean isClosed() throws java.io.IOException
Returns true if the connection to the client has been closed.- Specified by:
isClosed
in classJDBCProcessor
- Throws:
java.io.IOException
-
-