All Packages Class Hierarchy This Package Previous Next Index
Class twz1.jdbc.mysql.jdbcMysqlConnex
java.lang.Object
|
+----twz1.jdbc.mysql.jdbcMysqlConnex
- public final class jdbcMysqlConnex
- extends Object
- implements Connection
-
broken
- boolean broken
-
catalog
- The "database" or catalog
-
clientCapabilities
- Can we send long passwords
-
clientProtocol
- The client protocol number
-
connexTimeout
- Connection wait timeout
-
curl
- The url properties.
-
dbmdConnections
- Derived DatabaseMetaData connections
-
errs
-
-
guard
- My thread prophylactic
-
hashSeed
- The password hash seed.
-
host
- The host
-
inBag
- Input buffer for the socket
-
multipleQueries
- Do I allow multiple queries?
-
myOID
- My object id
-
open
- Am I open??
-
outBag
- Output buffer.
-
password
- The password
-
port
- The port.
-
serverThreadID
- The client threadid.
-
serverVersion
- The server version name.
-
socket
- Our socket for connection.
-
socketInput
- The socket input stream
-
socketOutput
- The socket output stream;
-
sockSO_LINGER
-
-
sockTCP_NODELAY
- Socket parms
-
sockTimeout
-
-
user
- The user
-
xOptions
- Extra connection options
-
jdbcMysqlConnex(jdbcMysqlURL)
- The connection constructor.
-
addDBMDconnex(jdbcMysqlConnex)
-
-
clearWarnings()
- Currently we return null, later I shall implement warnings to
pass back the error stack.
-
close()
- Close the connection.
-
closeMe()
- The close function to attempt to shutdown gracefully.
-
commit()
- Transactions are not supported in MySQL.
Oops, in dbmd docs say commit should be a noop.
-
createStatement()
- Create a statement to talk to the database.
-
errHandlerE(int, Exception)
-
-
errHandlerL(int, String)
-
-
errHandlerM(int, String, Exception)
-
-
errHandlerPS(int, String)
-
-
getAutoCommit()
- Transactions are not supported in MySQL.
-
getCatalog()
- Get the current catalog, aka "database" in MySQL.
-
getInBag()
- Get input bag
-
getMetaData()
- DatabaseMetaData is not yet supported, but probably will be
fairly soon, though most of its methods will be exceptional.
-
getOutBag()
-
-
getProperty(String)
-
-
getTransactionIsolation()
- Transactions are not supported in MySQL.
-
getWarnings()
- Currently we return null, later I shall implement warnings to
pass back the error stack.
-
hashPassword(String)
- Hash password, stolen almost verbatim from monty's code.
-
isClosed()
- API: return connection status.
-
iSetCat(String)
-
-
isMultipleQuery()
- is multiple query ?
-
isReadOnly()
- Read only connections are not supported by MySQL.
-
lock(boolean, int, int)
- Invoke a mutex to protect access to the connex after first
checking whether multiple connections are allowed and throwing
a fit if not and already connected.
-
nativeSQL(String)
- As we don't do any translation on the query this just bounces
back the parameter.
-
prepareCall(String)
- MySQL doesn't do callables.
-
prepareStatement(String)
- Initiate prepared statement.
-
rollback()
- Transactions are not supported in MySQL.
-
scramble()
- More of Monty's scrambled eggs encryption.
-
setAutoCommit(boolean)
- Transactions are not supported in MySQL.
-
setCatalog(String)
- Set the catalog, i.e "database" in MySQL talk.
-
setMultipleQuery(boolean)
- Set multiple queries
-
setProperty(String, String)
-
-
setReadDump(boolean)
- Set a read dump
-
setReadOnly(boolean)
- Read only connections are not supported by MySQL.
-
setTransactionIsolation(int)
- Transactions are not supported in MySQL.
-
setWriteDump(boolean)
- Set a write dump
-
testOpen(String)
-
-
xOpen()
-
curl
jdbcMysqlURL curl
- The url properties.
open
boolean open
- Am I open??
host
String host
- The host
port
int port
- The port.
catalog
String catalog
- The "database" or catalog
user
String user
- The user
password
String password
- The password
socket
Socket socket
- Our socket for connection.
socketInput
BufferedInputStream socketInput
- The socket input stream
socketOutput
BufferedOutputStream socketOutput
- The socket output stream;
multipleQueries
boolean multipleQueries
- Do I allow multiple queries?
inBag
jdbcMysqlBag inBag
- Input buffer for the socket
outBag
jdbcMysqlBag outBag
- Output buffer.
clientProtocol
int clientProtocol
- The client protocol number
clientCapabilities
int clientCapabilities
- Can we send long passwords
serverVersion
String serverVersion
- The server version name.
serverThreadID
int serverThreadID
- The client threadid.
hashSeed
String hashSeed
- The password hash seed.
guard
jdbcMysqlMutex guard
- My thread prophylactic
myOID
int myOID
- My object id
xOptions
int xOptions
- Extra connection options
sockTCP_NODELAY
int sockTCP_NODELAY
- Socket parms
sockSO_LINGER
int sockSO_LINGER
sockTimeout
int sockTimeout
connexTimeout
int connexTimeout
- Connection wait timeout
dbmdConnections
Vector dbmdConnections
- Derived DatabaseMetaData connections
broken
boolean broken
- boolean broken
errs
static final String errs[]
jdbcMysqlConnex
jdbcMysqlConnex(jdbcMysqlURL jurl) throws SQLException
- The connection constructor.
- Parameters:
- jurl - a URL/hashtable/properties list.
xOpen
void xOpen() throws SQLException
setReadDump
void setReadDump(boolean t) throws SQLException
- Set a read dump
setWriteDump
void setWriteDump(boolean t) throws SQLException
- Set a write dump
setMultipleQuery
void setMultipleQuery(boolean t) throws SQLException
- Set multiple queries
isMultipleQuery
boolean isMultipleQuery() throws SQLException
- is multiple query ?
getInBag
jdbcMysqlBag getInBag() throws SQLException
- Get input bag
getOutBag
jdbcMysqlBag getOutBag() throws SQLException
testOpen
private void testOpen(String s) throws SQLException
getProperty
String getProperty(String name)
setProperty
void setProperty(String n,
String v)
addDBMDconnex
void addDBMDconnex(jdbcMysqlConnex dbcx)
lock
boolean lock(boolean lockOnOff,
int oid,
int timeout) throws SQLException
- Invoke a mutex to protect access to the connex after first
checking whether multiple connections are allowed and throwing
a fit if not and already connected.
- Parameters:
- lockOnOff - set or clear the mutex.
- oid - Object setting the lock.
- timeout - time (seconds) to wait before tossing cookies.
closeMe
void closeMe()
- The close function to attempt to shutdown gracefully.
close
public void close() throws SQLException
- Close the connection.
isClosed
public boolean isClosed() throws SQLException
- API: return connection status.
setCatalog
public void setCatalog(String c) throws SQLException
- Set the catalog, i.e "database" in MySQL talk.
iSetCat
private void iSetCat(String c) throws SQLException
createStatement
public Statement createStatement() throws SQLException
- Create a statement to talk to the database.
getCatalog
public String getCatalog() throws SQLException
- Get the current catalog, aka "database" in MySQL.
clearWarnings
public void clearWarnings() throws SQLException
- Currently we return null, later I shall implement warnings to
pass back the error stack.
getWarnings
public SQLWarning getWarnings() throws SQLException
- Currently we return null, later I shall implement warnings to
pass back the error stack.
getTransactionIsolation
public int getTransactionIsolation() throws SQLException
- Transactions are not supported in MySQL.
setTransactionIsolation
public void setTransactionIsolation(int l) throws SQLException
- Transactions are not supported in MySQL.
rollback
public void rollback() throws SQLException
- Transactions are not supported in MySQL.
commit
public void commit() throws SQLException
- Transactions are not supported in MySQL.
Oops, in dbmd docs say commit should be a noop.
getAutoCommit
public boolean getAutoCommit() throws SQLException
- Transactions are not supported in MySQL.
setAutoCommit
public void setAutoCommit(boolean s) throws SQLException
- Transactions are not supported in MySQL.
setReadOnly
public void setReadOnly(boolean s) throws SQLException
- Read only connections are not supported by MySQL. If there is
a call for it I may implement support through this driver in the
future.
isReadOnly
public boolean isReadOnly() throws SQLException
- Read only connections are not supported by MySQL. If there is
a call for it I may implement support through this driver in the
future.
- Returns:
- always false.
getMetaData
public DatabaseMetaData getMetaData() throws SQLException
- DatabaseMetaData is not yet supported, but probably will be
fairly soon, though most of its methods will be exceptional.
nativeSQL
public String nativeSQL(String s) throws SQLException
- As we don't do any translation on the query this just bounces
back the parameter.
prepareCall
public CallableStatement prepareCall(String s) throws SQLException
- MySQL doesn't do callables.
prepareStatement
public PreparedStatement prepareStatement(String s) throws SQLException
- Initiate prepared statement.
errHandlerL
private void errHandlerL(int n,
String s) throws SQLException
errHandlerPS
private void errHandlerPS(int n,
String s) throws SQLException
errHandlerM
private void errHandlerM(int n,
String s,
Exception e) throws SQLException
errHandlerE
private void errHandlerE(int n,
Exception e) throws SQLException
hashPassword
private long[] hashPassword(String pass)
- Hash password, stolen almost verbatim from monty's code.
scramble
private byte[] scramble()
- More of Monty's scrambled eggs encryption.
All Packages Class Hierarchy This Package Previous Next Index