eXtremeDB SQL .NET 6.0 API
Classes | Public Types | Public Member Functions | Properties | List of all members
eXtremeDB.SqlRemoteConnection Class Reference

Remote database connection for execution of SQL queries. More...

Inheritance diagram for eXtremeDB.SqlRemoteConnection:
Inheritance graph
[legend]

Classes

class  OpenParameters
 

Public Types

enum class  ReplicationType { SQLReplication , HAReplication }
 

Public Member Functions

 SqlRemoteConnection (Database db, OpenParameters parameters)
 
 SqlRemoteConnection (Database db, string host, int port, int maxAttempts)
 Constructor of the remote database connection. More...
 
 SqlRemoteConnection (Database db, string host, int port, int maxAttempts, int txBufSize)
 Constructor of the remote database connection. More...
 
 SqlRemoteConnection (Database db, string[] nodes, int nReplicas, ReplicationType replType, int maxAttempts, int txBufSize)
 Constructor of the distributed database connection. More...
 
 SqlRemoteConnection (Database db, string[] nodes)
 Constructor of the distributed database connection. More...
 
SqlResultSet ExecuteQuery (String query, params Object[] args)
 Execute SQL query.

Parameters
querySQL query with '?' used as parameter placeholder.
Returns
cursor through selected tuples
More...
 
int ExecuteStatement (String stmt, params Object[] args)
 Execute SQL update statement

Parameters
stmtSQL DML statement with '?' used as parameter placeholder.
Returns
number of affected (updated, inserted, deleted) records
More...
 
void DetachResultSet (SqlResultSet res)
 Internal method called by SqlResultSet. Should not be explicitly called by application. More...
 
void Disconnect ()
 Close this connection. More...
 
void Dispose ()
 Close this connection. The same as Disconnect. More...
 

Properties

IDatabaseWrapper Wrapper [get]
 
- Properties inherited from eXtremeDB.ISqlConnection
IDatabaseWrapper Wrapper [get]
 

Detailed Description

Remote database connection for execution of SQL queries.

Member Enumeration Documentation

◆ ReplicationType

Enumerator
SQLReplication 
HAReplication 

Constructor & Destructor Documentation

◆ SqlRemoteConnection() [1/5]

eXtremeDB.SqlRemoteConnection.SqlRemoteConnection ( Database  db,
OpenParameters  parameters 
)

◆ SqlRemoteConnection() [2/5]

eXtremeDB.SqlRemoteConnection.SqlRemoteConnection ( Database  db,
string  host,
int  port,
int  maxAttempts 
)

Constructor of the remote database connection.

Parameters
dbdatabase instance
hosthostname of xsql server
portport of xsql server
maxAttemptsmaximal attempts of connection to server, interval between each connection attempt is one second, so totally connection will be performed during maxAttempts seconds

◆ SqlRemoteConnection() [3/5]

eXtremeDB.SqlRemoteConnection.SqlRemoteConnection ( Database  db,
string  host,
int  port,
int  maxAttempts,
int  txBufSize 
)

Constructor of the remote database connection.

Parameters
dbdatabase instance
hosthostname of xsql server
portport of xsql server
maxAttemptsmaximal attempts of connection to server, interval between each connection attempt is one second, so totally connection will be performed during maxAttempts seconds
txBufSizesize of internal transmit buffer in bytes. Required to serialize query or statement data

◆ SqlRemoteConnection() [4/5]

eXtremeDB.SqlRemoteConnection.SqlRemoteConnection ( Database  db,
string[]  nodes,
int  nReplicas,
ReplicationType  replType,
int  maxAttempts,
int  txBufSize 
)

Constructor of the distributed database connection.

Parameters
dbdatabase instance
nodesnames of database nodes, each element should have format "HOST:PORT"
nReplicasredundancy level
replTypereplications method
maxAttemptsmaximal attempts of connection to server, interval between each connection attempt is one second, so totally connection will be performed during maxAttempts seconds
txBufSizesize of internal transmit buffer in bytes. Required to serialize query or statement data

◆ SqlRemoteConnection() [5/5]

eXtremeDB.SqlRemoteConnection.SqlRemoteConnection ( Database  db,
string[]  nodes 
)

Constructor of the distributed database connection.

Parameters
dbdatabase instance
nodesnames of database nodes, each element should have format "HOST:PORT"

Member Function Documentation

◆ DetachResultSet()

void eXtremeDB.SqlRemoteConnection.DetachResultSet ( SqlResultSet  result)

Internal method called by SqlResultSet. Should not be explicitly called by application.

Implements eXtremeDB.ISqlConnection.

◆ Disconnect()

void eXtremeDB.SqlRemoteConnection.Disconnect ( )

Close this connection.

Implements eXtremeDB.ISqlConnection.

◆ Dispose()

void eXtremeDB.SqlRemoteConnection.Dispose ( )

Close this connection. The same as Disconnect.

◆ ExecuteQuery()

SqlResultSet eXtremeDB.SqlRemoteConnection.ExecuteQuery ( String  query,
params Object[]  args 
)

Execute SQL query.

Parameters
querySQL query with '?' used as parameter placeholder.
Returns
cursor through selected tuples

Implements eXtremeDB.ISqlConnection.

◆ ExecuteStatement()

int eXtremeDB.SqlRemoteConnection.ExecuteStatement ( String  stmt,
params Object[]  args 
)

Execute SQL update statement

Parameters
stmtSQL DML statement with '?' used as parameter placeholder.
Returns
number of affected (updated, inserted, deleted) records

Implements eXtremeDB.ISqlConnection.

Property Documentation

◆ Wrapper

IDatabaseWrapper eXtremeDB.SqlRemoteConnection.Wrapper
get

The documentation for this class was generated from the following file: