public abstract class DBConnection
extends java.lang.Object
implements java.lang.AutoCloseable
parameter | Description. |
---|---|
host | The DNS identification of the host to connect to. It may either be its DNS name or its IP address in dotted decimal. |
port | The IP port to connect to. |
clientID | The identification of the client trying to connect. |
signatureAlgorithmNames | A set of Strings denoting Signature names that the client is willing and able to use in signing. |
initialAutoCommitForTransactions | A boolean flag indicating the default autoCommit setting that will be given to each transaction started on this connection. |
requestConnectionIdleTime | The idle time in milliseconds that the client requests for this connection. |
encryptionAlgorithmNames | A set of Strings denoting names of Cipher algorithms that the client is willing and able to use. |
signer | A callback object that will be called upon to compute signatures if and when message signing is used. |
Constructors exist in various combinations, possibly leaving out some of the items mentioned. In such cases, default values are used. These default values are configurable for the client in the DBCONNECTION.PROPERTIES file (see the DBConnectionProperties class for more information on where the client package searches for this file). The following table mentions the property name holding this default value for each optional field, and the value the client package will use in the absence of such a property.
Field | Property | Default if property absent |
---|---|---|
signatureAlgorithmNames | DEFAULTSIGNATUREALGORITHMNAMES (property value must be a comma-separated list of algorithm names) | "MD5WITHRSA, MD2WITHRSA, SHA1WITHRSA, SHA1WITHDSA" |
initialAutoCommitForTransactions | DEFAULTAUTOCOMMITFORTRANSACTIONS | False |
transationMode | TRANSACTIONSREADONLY (property value is a boolean ; required value for backward compatibility is 'False') | False |
requestConnectionIdleTime | DEFAULTCONNECTIONIDLETIME | 0 |
encryptionAlgorithmNames | DEFAULTENCRYPTIONALGORITHMNAMES (property value must be a comma-separated list of Cipher algorithm names | SPE |
Though this may look complicated, it only means that the constructors use the following sources of information, in the order given :
Constructor and Description |
---|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
long requestConnectionIdleTime,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port with the given autoCommit setting, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
long requestConnectionIdleTime,
Signer signer)
Creates a connection to the server on the specified host and port with the given autoCommit setting, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
Signer privateKeyProvider)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
long requestConnectionIdleTime,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
long requestConnectionIdleTime,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.util.Set<java.lang.String> signatureAlgorithmNames,
java.lang.String clientID,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
long requestConnectionIdleTime,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port with the given autoCommit setting, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
long requestConnectionIdleTime,
Signer signer)
Creates a connection to the server on the specified host and port with the given autoCommit setting, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
boolean initialAutoCommitForTransactions,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
long requestConnectionIdleTime,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
long requestConnectionIdleTime,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
java.util.Set<java.lang.String> encryptionAlgorithmNames,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
DBConnection(SiraPriseServer siraPriseServer,
java.lang.String clientID,
Signer signer)
Creates a connection to the server on the specified host and port, and opens it for communication.
|
Modifier and Type | Method and Description |
---|---|
abstract void |
close()
Closes the connection.
|
void |
commit()
Deprecated.
Use the commit() method of the DBTransaction object instead
|
Relation |
compileAndCacheQuery(java.lang.String query)
Deprecated.
use the compileAndCacheQuery() method from the DBTransaction instead
|
Relation |
compileQuery(java.lang.String query)
Deprecated.
use compileQuery() on the DBTransaction object (obtained from startTransaction()) instead.
|
void |
endTransaction(boolean commit)
Deprecated.
instead, use end() on the DBTransaction object obtained from startTransaction().
|
Relation |
execDmlCommand(java.lang.String cmd)
Deprecated.
Use the execDmlCommand() method from the DBTransaction instead
|
Relation |
execDmlCommandAndEndTransaction(java.lang.String cmd)
Deprecated.
instead, use execDmlCommandAndEndTransaction() on the DBTransaction object obtained from startTransaction()
|
Relation |
execMultipleStatement(java.util.Collection<?> commands)
Deprecated.
replace this method by the execMultipleStatementAndEndTransaction() of the DBTransaction object obtained from startTransaction()
|
Relation |
execMultipleStatement(java.lang.String[] commands)
Deprecated.
replace this method by the execMultipleStatementAndEndTransaction() of the DBTransaction object obtained from startTransaction()
|
Relation |
execMultipleStatementAndEndTransaction(java.util.Collection<?> commands)
Deprecated.
replace this method by the execMultipleStatementAndEndTransaction() of the DBTransaction object obtained from startTransaction()
|
Relation |
execMultipleStatementAndEndTransaction(java.lang.String[] commands)
Deprecated.
replace this method by the execMultipleStatementAndEndTransaction() of the DBTransaction object obtained from startTransaction()
|
Relation[] |
execQueries(java.lang.String[] expression)
Deprecated.
replace this method by the execQueries() method of the DBTransaction object obtained from startTransaction()
|
Relation[] |
execQueriesAndEndTransaction(java.lang.String[] expression)
Deprecated.
replace this method by the execQueriesAndEndTransaction() method of the DBTransaction object obtained from startTransaction()
|
Relation |
execQuery(java.lang.String expression)
Deprecated.
replace this method by the execQuery() method of the DBTransaction object obtained from startTransaction()
|
Relation |
execQueryAndEndTransaction(java.lang.String expression)
Deprecated.
replace this method by the execQueryAndEndTransaction() method of the DBTransaction object obtained from startTransaction()
|
boolean |
getDefaultTransactionAutoCommit()
Gets The default autocommit setting for all transactions created on this connection
|
Version |
getSpecificationVersionForServer()
Gets The specification version to use in communications with the server
|
static boolean |
isDefaultInitialAutoCommitForTransactions()
Gets defaultInitialAutoCommitForTransactions
|
boolean |
isOpen()
Checks whether a connection is open
|
void |
rollback()
Deprecated.
Use the rollback() method of the DBTransaction object obtained from the connection instead
|
void |
setDefaultTransactionAutoCommit(boolean autoCommit)
Sets The default autocommit setting for all transactions created on this connection
|
DBTransaction |
startTransaction()
Starts an anonymous transaction on the connection with the default autocommit, transactionmode and ddl capture settings for transactions created on this connection
|
DBTransaction |
startTransaction(boolean autoCommit)
Starts an anonymous transaction on the connection with the given autocommit setting
|
DBTransaction |
startTransaction(boolean autoCommit,
DDLCapture ddlCapture)
Starts an anonymous transaction on the connection with the given autocommit and ddl capture settings
|
DBTransaction |
startTransaction(boolean autoCommit,
TransactionMode transactionMode)
Starts an anonymous transaction in the given transaction mode on the connection with the given autocommit setting
|
DBTransaction |
startTransaction(boolean autoCommit,
TransactionMode transactionMode,
DDLCapture ddlCapture)
Starts an anonymous transaction in the given transaction mode on the connection with the given autocommit setting
|
DBTransaction |
startTransaction(boolean autoCommit,
TransactionMode transactionMode,
DDLCapture ddlCapture,
SnapShotIsolationMode snapShotIsolationMode)
Starts an anonymous transaction in the given transaction mode on the connection with the given autocommit setting
|
DBTransaction |
startTransaction(boolean autoCommit,
TransactionMode transactionMode,
SnapShotIsolationMode snapShotIsolationMode)
Starts an anonymous transaction in the given transaction mode on the connection with the given autocommit setting
|
DBTransaction |
startTransaction(DDLCapture ddlCapture)
Starts an anonymous transaction on the connection with the default autocommit and transactionmode settings for transactions created on this connection, and the given ddl capture setting
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature)
Starts a transaction on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
boolean autoCommit,
TransactionMode transactionMode)
Starts a transaction on the connection with the given autoCommit setting
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
boolean autoCommit,
TransactionMode transactionMode,
DDLCapture captureDDL)
Starts a transaction on the connection with the given autoCommit setting
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
boolean autoCommit,
TransactionMode transactionMode,
DDLCapture captureDDL,
SnapShotIsolationMode snapShotIsolationMode)
Starts a transaction on the connection with the given autoCommit setting
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
boolean autoCommit,
TransactionMode transactionMode,
SnapShotIsolationMode snapShotIsolationMode)
Starts a transaction on the connection with the given autoCommit setting
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
DDLCapture ddlCapture)
Starts a transaction on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
TransactionMode transactionMode)
Starts a transaction on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(java.lang.String userID,
boolean userAuthenticatedByClient,
java.lang.String signatureAlgorithm,
byte[] signature,
TransactionMode transactionMode,
DDLCapture ddlCapture)
Starts a transaction on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner)
Starts a transaction on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner,
boolean autoCommit)
Starts a transaction on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner,
boolean autoCommit,
TransactionMode transactionMode)
Starts a transaction in the given transaction mode on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner,
boolean autoCommit,
TransactionMode transactionMode,
SnapShotIsolationMode snapShotIsolationMode)
Starts a transaction in the given transaction mode on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner,
TransactionMode transactionMode)
Starts a transaction in the given read-only mode on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(java.lang.String userID,
Signer userIDSigner,
TransactionMode transactionMode,
SnapShotIsolationMode snapShotIsolationMode)
Starts a transaction in the given read-only mode on the connection for the named user and with the default autocommit setting for transactions created on this connection.
|
DBTransaction |
startTransaction(TransactionMode transactionMode)
Starts an anonymous transaction in the given transaction mode on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(TransactionMode transactionMode,
DDLCapture ddlCapture)
Starts an anonymous transaction in the given transaction mode on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(TransactionMode transactionMode,
DDLCapture ddlCapture,
SnapShotIsolationMode snapShotIsolationMode)
Starts an anonymous transaction in the given transaction mode on the connection with the default autocommit setting for transactions created on this connection
|
DBTransaction |
startTransaction(TransactionMode transactionMode,
SnapShotIsolationMode snapShotIsolationMode)
Starts an anonymous transaction in the given transaction mode on the connection with the default autocommit setting for transactions created on this connection
|
public DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, boolean initialAutoCommitForTransactions, long requestConnectionIdleTime, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws DBException, java.io.IOException, CommunicationProtocolException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The ID identifying the client of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to truerequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idleencryptionAlgorithmNames
- A specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, boolean initialAutoCommitForTransactions, long requestConnectionIdleTime, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The ID identifying the client of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to truerequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idlesigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, boolean initialAutoCommitForTransactions, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to trueencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, boolean initialAutoCommitForTransactions, Signer privateKeyProvider) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to trueprivateKeyProvider
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, long requestConnectionIdleTime, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISErequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idleencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, long requestConnectionIdleTime, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISErequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idlesigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISEencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.util.Set<java.lang.String> signatureAlgorithmNames, java.lang.String clientID, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.signatureAlgorithmNames
- a specified set of usable signature algorithm namesclientID
- The userID identifying the user of this connection to SIRA_PRISEsigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, boolean initialAutoCommitForTransactions, long requestConnectionIdleTime, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The ID identifying the client of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to truerequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idleencryptionAlgorithmNames
- A specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, boolean initialAutoCommitForTransactions, long requestConnectionIdleTime, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The ID identifying the client of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to truerequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idlesigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, boolean initialAutoCommitForTransactions, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to trueencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, boolean initialAutoCommitForTransactions, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISEinitialAutoCommitForTransactions
- true if the transactions created on this connection should have their autocommit set to truesigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, long requestConnectionIdleTime, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISErequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idleencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, long requestConnectionIdleTime, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISErequestConnectionIdleTime
- The requested time in milliseconds that the connection is allowed to stay idlesigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, java.util.Set<java.lang.String> encryptionAlgorithmNames, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISEencryptionAlgorithmNames
- a specified set of usable encryption protocol namessigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic DBConnection(SiraPriseServer siraPriseServer, java.lang.String clientID, Signer signer) throws java.io.IOException, CommunicationProtocolException, DBException
siraPriseServer
- The identification of the host. It may either be its DNS name or its IP address in dotted decimal.clientID
- The userID identifying the user of this connection to SIRA_PRISEsigner
- The Signer object that will be called upon to compute the needed signaturejava.io.IOException
- if an I/O error occurs when creating the TCP socket.CommunicationProtocolException
- If an unexpected message was received during the handshakeDBException
- If an error was detected on the server during the handshakepublic static final boolean isDefaultInitialAutoCommitForTransactions()
public abstract void close()
close
in interface java.lang.AutoCloseable
@Deprecated public void commit() throws ConnectionClosedException
ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation compileAndCacheQuery(java.lang.String query) throws DBException, ConnectionClosedException
query
- the query to be compiled-and-cached, in textual form.DBException
- If the connection has already been closed, no transaction was started, or an error was found in the compilation.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation compileQuery(java.lang.String query) throws DBException, ConnectionClosedException
query
- the query to be verified, in textual form.DBException
- If the connection has already been closed, no transaction was started, or an error was found in the compilation.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public void endTransaction(boolean commit) throws ConnectionClosedException
commit
- true if the transaction is to be committed, false if it is to be rolled back.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execDmlCommand(java.lang.String cmd) throws DBException, ConnectionClosedException
cmd
- the command to be executed, in textual form.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execDmlCommandAndEndTransaction(java.lang.String cmd) throws DBException, ConnectionClosedException
cmd
- the command to be executed, in textual form.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execMultipleStatement(java.util.Collection<?> commands) throws DBException, ConnectionClosedException
commands
- The commands to be executed. Execution is in the obvious order, and thus not randomly, or in reverse order, or whatever.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execMultipleStatement(java.lang.String[] commands) throws DBException, ConnectionClosedException
commands
- The single-assignment commands to be executed. Execution is in the obvious order, and thus not randomly, or in reverse order, or whatever.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execMultipleStatementAndEndTransaction(java.util.Collection<?> commands) throws DBException, ConnectionClosedException
commands
- The commands to be executed. Execution is in the obvious order, and thus not randomly, or in reverse order, or whatever.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execMultipleStatementAndEndTransaction(java.lang.String[] commands) throws DBException, ConnectionClosedException
commands
- The single-assignment commands to be executed. Execution is in the obvious order, and thus not randomly, or in reverse order, or whatever.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation[] execQueries(java.lang.String[] expression) throws DBException, ConnectionClosedException
expression
- The expressions of the relational algebra to be inquired.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation[] execQueriesAndEndTransaction(java.lang.String[] expression) throws DBException, ConnectionClosedException
expression
- The expressions of the relational algebra to be inquired.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execQuery(java.lang.String expression) throws DBException, ConnectionClosedException
expression
- The expression of the relational algebra to be inquired.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the server@Deprecated public Relation execQueryAndEndTransaction(java.lang.String expression) throws DBException, ConnectionClosedException
expression
- The expression of the relational algebra to be inquired.DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverpublic boolean getDefaultTransactionAutoCommit()
public final Version getSpecificationVersionForServer()
public boolean isOpen()
@Deprecated public void rollback() throws DBException, ConnectionClosedException
DBException
- If the connection has already been closed, no transaction was started, or an error was found.ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverpublic void setDefaultTransactionAutoCommit(boolean autoCommit)
autoCommit
- The new default autocommit setting for all transactions created on this connectionpublic final DBTransaction startTransaction() throws ConnectionClosedException, ErrorMessageException
ConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit, DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactionddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit, TransactionMode transactionMode) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modeConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit, TransactionMode transactionMode, DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modeddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit, TransactionMode transactionMode, DDLCapture ddlCapture, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modeddlCapture
- Flag indicating whether DDL capture is to be used in this transactionsnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(boolean autoCommit, TransactionMode transactionMode, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
autoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modesnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
ddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, boolean autoCommit, TransactionMode transactionMode) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- the mode for the transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, boolean autoCommit, TransactionMode transactionMode, DDLCapture captureDDL) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- the mode for the transactioncaptureDDL
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, boolean autoCommit, TransactionMode transactionMode, DDLCapture captureDDL, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- the mode for the transactioncaptureDDL
- Flag indicating whether DDL capture is to be used in this transactionsnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, boolean autoCommit, TransactionMode transactionMode, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- the mode for the transactionsnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signatureddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, TransactionMode transactionMode) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signaturetransactionMode
- The transaction modeConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, boolean userAuthenticatedByClient, java.lang.String signatureAlgorithm, byte[] signature, TransactionMode transactionMode, DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserAuthenticatedByClient
- true if the user has been authenticated by the clientsignatureAlgorithm
- The name of the signature algorithm that can be used by the server to verify the authenticity of the userIDsignature
- the user's signaturetransactionMode
- The transaction modeddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signatureDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner, boolean autoCommit) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signatureautoCommit
- The autoCommit setting for the transactionDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner, boolean autoCommit, TransactionMode transactionMode) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modeDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner, boolean autoCommit, TransactionMode transactionMode, SnapShotIsolationMode snapShotIsolationMode) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signatureautoCommit
- The autoCommit setting for the transactiontransactionMode
- The transaction modesnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner, TransactionMode transactionMode) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signaturetransactionMode
- The transaction modeDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(java.lang.String userID, Signer userIDSigner, TransactionMode transactionMode, SnapShotIsolationMode snapShotIsolationMode) throws DBException, ConnectionClosedException, ErrorMessageException
userID
- The identification of the user starting the transactionuserIDSigner
- The Signer object that will be called upon to compute the needed signaturetransactionMode
- The transaction modesnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyDBException
- If the transaction could not be startedConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(TransactionMode transactionMode) throws ConnectionClosedException, ErrorMessageException
transactionMode
- The transaction modeConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(TransactionMode transactionMode, DDLCapture ddlCapture) throws ConnectionClosedException, ErrorMessageException
transactionMode
- The transaction modeddlCapture
- Flag indicating whether DDL capture is to be used in this transactionConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(TransactionMode transactionMode, DDLCapture ddlCapture, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
transactionMode
- The transaction modeddlCapture
- Flag indicating whether DDL capture is to be used in this transactionsnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message insteadpublic final DBTransaction startTransaction(TransactionMode transactionMode, SnapShotIsolationMode snapShotIsolationMode) throws ConnectionClosedException, ErrorMessageException
transactionMode
- The transaction modesnapShotIsolationMode
- The snapshot mode, in the case the requested transaction is read-onlyConnectionClosedException
- If the connection was closed due to an I/O error that occurred during communication with the serverErrorMessageException
- If the response obtained from the server was not a confirmation, but an error message instead