Symbian
Symbian Developer Library

SYMBIAN OS V9.4

Feedback

[Index] [Previous] [Next]

#include <btsdp.h>
Link against: sdpdatabase.lib

Class RSdpDatabase

class RSdpDatabase : public RSdpSubSession;

Description

Subsession to the SDP through which service records and their attributes can be added, deleted, and updated.

Derivation

Members

Defined in RSdpDatabase:

Inherited from RSubSessionBase:


Construction and destruction


RSdpDatabase()

Capability: LocalServices

IMPORT_C RSdpDatabase();

Description

Default constructor.

[Top]


Member functions


Open(RSdp &)

Capability: LocalServices

IMPORT_C virtual TInt Open(RSdp &aSession);

Description

Opens a SDP database subsession.

Parameters

RSdp &aSession

SDP database session

Return value

TInt

System-wide error code


Close()

Capability: LocalServices

IMPORT_C virtual void Close();

Description

Closes the SDP database subsession.

Any records that have been added during this session will be removed when the session is closed.


CreateServiceRecordL(const TUUID &,TSdpServRecordHandle &)

Capability: LocalServices

IMPORT_C void CreateServiceRecordL(const TUUID &aUUID, TSdpServRecordHandle &aHandle);

Description

Creates a new service record, with a single service class, in the SDP database.

Parameters

const TUUID &aUUID

The service class UUID for the service record

TSdpServRecordHandle &aHandle

On return, the service record handle of the new record


CreateServiceRecordL(CSdpAttrValueDES &,TSdpServRecordHandle &)

Capability: LocalServices

IMPORT_C void CreateServiceRecordL(CSdpAttrValueDES &aUUIDList, TSdpServRecordHandle &aHandle);

Description

Creates a new service record, with multiple service classes, in the SDP database.

Parameters

CSdpAttrValueDES &aUUIDList

The service class attribute of the new record. This should consist of a list of UUIDs of the service classes to which the record belongs. The UUIDs should be ordered from the most derived service class to the base one.

TSdpServRecordHandle &aHandle

On return, the service record handle of the new record


UpdateAttributeL(TSdpServRecordHandle,TSdpAttributeID,CSdpAttrValue &)

Capability: LocalServices

IMPORT_C void UpdateAttributeL(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID, CSdpAttrValue &aAttrValue);

Description

Updates a service record attribute (value encapsulated in a CSdpAttrValue).

If the attribute does not exist, it is created. If it already exists, the current definition is removed and the new value inserted.

No check is made that the attribute value is suitable for the service class to which the record belongs. It is up to the user to ensure that the semantics of the attribute defined by the service class are respected.

Parameters

TSdpServRecordHandle aHandle

The service record handle to update

TSdpAttributeID aAttrID

The attribute ID to update

CSdpAttrValue &aAttrValue

The attribute value


UpdateAttributeL(TSdpServRecordHandle,TSdpAttributeID,TUint)

Capability: LocalServices

IMPORT_C void UpdateAttributeL(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID, TUint aUintValue);

Description

Updates a service record attribute (integer value).

If the attribute does not exist, it is created. If it already exists, the current definition is removed and the new value inserted.

No check is made that the attribute value is suitable for the service class to which the record belongs. It is up to the user to ensure that the semantics of the attribute defined by the service class are respected.

Parameters

TSdpServRecordHandle aHandle

The service record handle to update

TSdpAttributeID aAttrID

The attribute ID to update

TUint aUintValue

The attribute value


UpdateAttributeL(TSdpServRecordHandle,TSdpAttributeID,const TDesC16 &)

Capability: LocalServices

IMPORT_C void UpdateAttributeL(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID, const TDesC16 &aDesCValue);

Description

Updates a service record attribute (narrow descriptor value).

If the attribute does not exist, it is created. If it already exists, the current value is removed and the new value inserted.

No check is made that the attribute value is suitable for the service class to which the record belongs. It is up to the user to ensure that the semantics of the attribute defined by the service class are respected.

Parameters

TSdpServRecordHandle aHandle

The service record handle to update

TSdpAttributeID aAttrID

The attribute ID to update

const TDesC16 &aDesCValue

The attribute value


UpdateAttributeL(TSdpServRecordHandle,TSdpAttributeID,const TDesC8 &)

Capability: LocalServices

IMPORT_C void UpdateAttributeL(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID, const TDesC8 &aDesCValue);

Description

Updates a service record attribute (narrow descriptor value).

If the attribute does not exist, it is created. If it already exists, the current definition is removed and the new value inserted.

No check is made that the attribute value is suitable for the service class to which the record belongs. It is up to the user to ensure that the semantics of the attribute defined by the service class are respected.

Parameters

TSdpServRecordHandle aHandle

The service record handle to update

TSdpAttributeID aAttrID

The attribute ID to update

const TDesC8 &aDesCValue

The attribute value


DeleteAttributeL(TSdpServRecordHandle,TSdpAttributeID)

Interface status: deprecated Use non-leaving version instead
Capability: LocalServices

IMPORT_C void DeleteAttributeL(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID);

Description

Delete an attribute from a service record.

Parameters

TSdpServRecordHandle aHandle

The service record from which to delete the attribute

TSdpAttributeID aAttrID

The ID of the attribute

See also:


DeleteAttribute(TSdpServRecordHandle,TSdpAttributeID)

Capability: LocalServices

IMPORT_C void DeleteAttribute(TSdpServRecordHandle aHandle, TSdpAttributeID aAttrID);

Description

Delete an attribute from a service record.

Parameters

TSdpServRecordHandle aHandle

The service record from which to delete the attribute

TSdpAttributeID aAttrID

The ID of the attribute


DeleteRecordL(TSdpServRecordHandle)

Interface status: deprecated Use non-leaving version instead
Capability: LocalServices

IMPORT_C void DeleteRecordL(TSdpServRecordHandle aHandle);

Description

Deletes a service record.

Parameters

TSdpServRecordHandle aHandle

Handle of the service record to delete

See also:


DeleteRecord(TSdpServRecordHandle)

Capability: LocalServices

IMPORT_C void DeleteRecord(TSdpServRecordHandle aHandle);

Description

Deletes a service record.

Parameters

TSdpServRecordHandle aHandle

Handle of the service record to delete