Freeze Slice API Reference
Operations | List of all members
Freeze::Connection Local Interface Reference

A connection to a database (database environment with Berkeley DB). More...

defined in <Freeze/Connection.ice>

local interface Connection { ... }

Operations

Transaction beginTransaction ()
 Create a new transaction. More...
 
void close ()
 Closes this connection. More...
 
Transaction currentTransaction ()
 Returns the transaction associated with this connection. More...
 
Ice::Communicator getCommunicator ()
 Returns the communicator associated with this connection. More...
 
Ice::EncodingVersion getEncoding ()
 Returns the encoding version used to encode the data. More...
 
string getName ()
 The name of the connected system (for example, the Berkeley DB environment). More...
 
void removeMapIndex (string mapName, string indexName)
 Remove an unused Freeze Map index. More...
 

Detailed Description

A connection to a database (database environment with Berkeley DB).

If you want to use a connection concurrently in multiple threads, you need to serialize access to this connection.

Operation Documentation

◆ beginTransaction()

Transaction beginTransaction ( )

Create a new transaction.

Only one transaction at a time can be associated with a connection.

Returns
The new transaction.
Exceptions
TransactionAlreadyInProgressExceptionRaised if a transaction is already associated with this connection.

◆ close()

void close ( )

Closes this connection.

If there is an associated transaction, it is rolled back.

◆ currentTransaction()

["cpp:const"]
Transaction currentTransaction ( )

Returns the transaction associated with this connection.

Returns
The current transaction if there is one, null otherwise.

◆ getCommunicator()

["cpp:const"]
Ice::Communicator getCommunicator ( )

Returns the communicator associated with this connection.

Returns
The communicator.

◆ getEncoding()

["cpp:const"]
Ice::EncodingVersion getEncoding ( )

Returns the encoding version used to encode the data.

Returns
The encoding version.

◆ getName()

["cpp:const"]
string getName ( )

The name of the connected system (for example, the Berkeley DB environment).

Returns
The name of the connected system.

◆ removeMapIndex()

void removeMapIndex ( string  mapName,
string  indexName 
)

Remove an unused Freeze Map index.

Parameters
mapNameThe name of the Freeze map.
indexNameThe name of the index.
Exceptions
IndexNotFoundExceptionRaised if this index does not exist.

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