Original Symbian headers
Selected EUSER, Window Server, networking, graphics and device declarations
Loading...
Searching...
No Matches
RNetDatabase Class Reference

Provides an interface to network databases, such as LM-IAS with IrDA, that may be provided by particular protocol modules. More...

#include <es_sock.h>

Inheritance diagram for RNetDatabase:
RSubSessionBase

Public Member Functions

IMPORT_C TInt Open (RSocketServ &aSocketServer, TUint anAddrFamily, TUint aProtocol)
 Initialises a database access service provided by a particular protocol.
 
IMPORT_C void Query (const TDesC8 &aQuery, TDes8 &aResult, TRequestStatus &aStat)
 Makes a query to the database asynchronously.
 
IMPORT_C TInt Query (const TDesC8 &aQuery, TDes8 &aResult)
 Makes a query to the database.
 
IMPORT_C void Add (const TDesC8 &anItem, TRequestStatus &aStat)
 Adds a record to the database asynchronously.
 
IMPORT_C TInt Add (const TDesC8 &anItem)
 Adds a record to the database.
 
IMPORT_C void Remove (const TDesC8 &anItem, TRequestStatus &aStat)
 Removes a record from the database asynchronously.
 
IMPORT_C TInt Remove (const TDesC8 &anItem)
 Removes a record from the database.
 
IMPORT_C void Close ()
 Closes a database access service.
 
IMPORT_C void Cancel ()
 Cancels any outstanding asynchronous calls, which will return with error code KErrCancel.
 
- Public Member Functions inherited from RSubSessionBase
TInt SubSessionHandle () const
 Gets the sub-session handle number.
 

Additional Inherited Members

- Protected Member Functions inherited from RSubSessionBase
 RSubSessionBase ()
 Default constructor.
 
IMPORT_C const RSessionBase Session () const
 Returns a copy of the session associated with this sub-session.
 
TInt CreateSubSession (const RSessionBase &aSession, TInt aFunction, const TIpcArgs &aArgs)
 Creates a new sub-session within an existing session.
 
TInt CreateSubSession (const RSessionBase &aSession, TInt aFunction)
 Creates a new sub-session within an existing session.
 
IMPORT_C TInt CreateAutoCloseSubSession (RSessionBase &aSession, TInt aFunction, const TIpcArgs &aArgs)
 Creates a new sub-session within an existing session.
 
IMPORT_C void CloseSubSession (TInt aFunction)
 Closes the sub-session.
 
TInt Send (TInt aFunction, const TIpcArgs &aArgs) const
 Sends a blind message to the server - no reply is expected.
 
void SendReceive (TInt aFunction, const TIpcArgs &aArgs, TRequestStatus &aStatus) const
 Sends a message to the server and waits asynchronously for the reply.
 
TInt SendReceive (TInt aFunction, const TIpcArgs &aArgs) const
 Sends a message to the server and waits synchronously for a reply.
 
TInt Send (TInt aFunction) const
 Sends a blind message to the server - no reply is expected.
 
void SendReceive (TInt aFunction, TRequestStatus &aStatus) const
 Sends a message to the server and waits asynchronously for the reply.
 
TInt SendReceive (TInt aFunction) const
 Sends a message to the server and waits synchronously for a reply.
 

Detailed Description

Provides an interface to network databases, such as LM-IAS with IrDA, that may be provided by particular protocol modules.

Before making any queries, a connection to a socket server session must be made.

Each function is available in both synchronous and asynchronous versions.

A single RNetDatabase can only perform one request of any type at once. A client is panicked if it makes two requests.

Particular database access services will specify the format of queries and of responses.

API status
Published to all clients. Released API.

Definition at line 1058 of file es_sock.h.

Member Function Documentation

◆ Add() [1/2]

IMPORT_C TInt RNetDatabase::Add ( const TDesC8 &  anItem)

Adds a record to the database.

Parameters
anItemThe record to add
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)

◆ Add() [2/2]

IMPORT_C void RNetDatabase::Add ( const TDesC8 &  anItem,
TRequestStatus &  aStat 
)

Adds a record to the database asynchronously.

Parameters
anItemThe record to add
aStatIndicates asynchronous operation and on completion contains an error code: see the system-wide error codes.
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)

◆ Cancel()

IMPORT_C void RNetDatabase::Cancel ( )

Cancels any outstanding asynchronous calls, which will return with error code KErrCancel.

(generated from Symbian Developer Library)

◆ Close()

IMPORT_C void RNetDatabase::Close ( )

Closes a database access service.

If a service has been opened using Open(), then it should be closed using Close(). This will ensure all associated resources are released.

(generated from Symbian Developer Library)

◆ Open()

IMPORT_C TInt RNetDatabase::Open ( RSocketServ &  aSocketServer,
TUint  anAddrFamily,
TUint  aProtocol 
)

Initialises a database access service provided by a particular protocol.

It must be called before other object functions are used.

Parameters
aSocketServerThe socket server session
anAddrFamilyA constant identifying the protocol family
aProtocolA constant that identifies the protocol that provides the database access service

(generated from Symbian Developer Library)

◆ Query() [1/2]

IMPORT_C TInt RNetDatabase::Query ( const TDesC8 &  aQuery,
TDes8 &  aResult 
)

Makes a query to the database.

Parameters
aQueryThe query to perform
aResultThe result of the query
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)

◆ Query() [2/2]

IMPORT_C void RNetDatabase::Query ( const TDesC8 &  aQuery,
TDes8 &  aResult,
TRequestStatus &  aStat 
)

Makes a query to the database asynchronously.

Parameters
aQueryThe query to perform
aResultThe result of the query
aStatIndicates asynchronous operation and on completion contains an error code: see the system-wide error codes.
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)

◆ Remove() [1/2]

IMPORT_C TInt RNetDatabase::Remove ( const TDesC8 &  anItem)

Removes a record from the database.

Parameters
anItemThe record to remove
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)

◆ Remove() [2/2]

IMPORT_C void RNetDatabase::Remove ( const TDesC8 &  anItem,
TRequestStatus &  aStat 
)

Removes a record from the database asynchronously.

Parameters
anItemThe record to remove
aStatIndicates asynchronous operation and on completion contains an error code: see the system-wide error codes.
capability
Dependent on the type of connection so deferred to PRT

(generated from Symbian Developer Library)


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