Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: 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:
Close(), CreateServiceRecordL(), CreateServiceRecordL(), DeleteAttribute(), DeleteAttributeL(), DeleteRecord(), DeleteRecordL(), Open(), RSdpDatabase(), UpdateAttributeL(), UpdateAttributeL(), UpdateAttributeL(), UpdateAttributeL()

Inherited from RSubSessionBase:
CloseSubSession(), CreateAutoCloseSubSession(), CreateSubSession(), Send(), SendReceive(), Session(), SubSessionHandle()


Construction and destruction


RSdpDatabase()

Capability: LocalServices

IMPORT_C RSdpDatabase();

Description

Default constructor.

[Top]


Member functions


Open()

Capability: LocalServices

virtual IMPORT_C 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

virtual IMPORT_C 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()

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()

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()

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()

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()

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()

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()

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


DeleteAttribute()

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()

Capability: LocalServices

IMPORT_C void DeleteRecordL(TSdpServRecordHandle aHandle);

Description

Deletes a service record.

Parameters

TSdpServRecordHandle aHandle

Handle of the service record to delete


DeleteRecord()

Capability: LocalServices

IMPORT_C void DeleteRecord(TSdpServRecordHandle aHandle);

Description

Deletes a service record.

Parameters

TSdpServRecordHandle aHandle

Handle of the service record to delete