Symbian3/PDK/Source/GUID-B75BD3DE-9C2E-5429-B55B-891462B92795.dita
author Dominic Pinkman <Dominic.Pinkman@Nokia.com>
Thu, 11 Mar 2010 18:02:22 +0000
changeset 3 46218c8b8afa
parent 1 25a17d01db0c
child 5 f345bda72bc4
permissions -rw-r--r--
week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     1
<?xml version="1.0" encoding="utf-8"?>
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     2
<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     3
<!-- This component and the accompanying materials are made available under the terms of the License 
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     4
"Eclipse Public License v1.0" which accompanies this distribution, 
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     5
and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     6
<!-- Initial Contributors:
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     7
    Nokia Corporation - initial contribution.
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     8
Contributors: 
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
     9
-->
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
    10
<!DOCTYPE concept
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
    11
  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
    12
<concept xml:lang="en" id="GUID-B75BD3DE-9C2E-5429-B55B-891462B92795"><title>Connecting to the service discovery database</title><prolog><metadata><keywords/></metadata></prolog><conbody><p>Bluetooth services are registered to the service discovery database. </p> <section><title>How to connect to the service discovery database</title> <p>The first step in registering a service to the service discovery database is establishing a connection to the database. </p> <p><b>Basic Procedure</b> </p> <p>To use the service discovery database, a client must: </p> <ol id="GUID-094BC503-E351-513D-9EAE-5E75E93104AC"><li id="GUID-4564B0E1-5CF7-53F1-B4E7-38CB386A4E28"><p>Create a session to the database object, <xref href="GUID-0879B4D7-A6FA-382F-A124-0234BA89D33D.dita"><apiname>RSdp</apiname></xref>, and open a connection. </p> </li> <li id="GUID-BBB6AB46-AE11-5579-9426-36CF9DF26D11"><p>Create a subsession to the database object, <xref href="GUID-FC133F0F-C9E8-30CB-B2FE-8AC9F7F802AC.dita"><apiname>RSdpDatabase</apiname></xref>, and open it. A client can have multiple subsessions open if required. (Sessions and subsessions are part of Symbian OS's architecture for interprocess communication: see <xref href="GUID-D0D27AEA-FDDB-5F6F-94F6-ADDF5910DC47.dita">Client/Server Overview</xref>). </p> </li> <li id="GUID-6A5DE434-5D70-54EC-9584-3E1179F1AA8A"><p>Close subsessions and sessions when they are no longer needed. </p> </li> </ol> <p><b> Connecting to the database </b> </p> <p>The following example shows how to connect to the database: </p> <ul><li id="GUID-5B6792CF-D05F-5DA6-8CAC-2694705BEEA2"><p>Create and open a session to the database </p> <codeblock id="GUID-BB8D1A05-E9D4-5252-90D6-58493545C53A" xml:space="preserve">RSdp sdp;
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
    13
User::LeaveIfError(sdp.Connect());</codeblock> </li> <li id="GUID-F962F78D-8875-517D-8DA6-5C42BAED5C50"><p>Create and open a subsession </p> <codeblock id="GUID-93C2E486-13BA-5B42-9947-A8E9D260C022" xml:space="preserve">RSdpDatabase sdpSubSession;
46218c8b8afa week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents: 1
diff changeset
    14
User::LeaveIfError(sdpSubSession.Open(sdp));</codeblock> </li> <li id="GUID-2F7C3D26-8DA2-54F7-B2D2-061E5A1B4EEE"><p>Cleanup </p> <codeblock id="GUID-98CCF2D7-F1DC-5FD3-B4BC-0A762DF70EA1" xml:space="preserve">sdpSubSession.Close();
1
25a17d01db0c Addition of the PDK content and example code for Documentation_content according to Feature bug 1607 and bug 1608
Dominic Pinkman <Dominic.Pinkman@Nokia.com>
parents:
diff changeset
    15
sdp.Close();</codeblock> </li> </ul>   </section> <section><title>Where next?</title> <p>The complete set of Service Discovery Database tutorials are shown below: </p> <ol id="GUID-0B5EA0D5-88F7-5E3B-A322-9DDB2632C245"><li id="GUID-B5C6757E-67DE-50E9-9823-E37F6268689A"><p> <b>Connecting to the service discovery database</b> - This document </p> </li> <li id="GUID-9AA92312-5798-596B-A690-147DC7358BBC"><p> <xref href="GUID-E2A2FA2A-5D9A-56FE-B7E5-69CCBC656BB9.dita">Handling SDP attributes</xref>  </p> </li> <li id="GUID-5F8F22AB-476E-5E65-8EBE-750278B3CBD6"><p> <xref href="GUID-2373A158-C18A-51B5-BE9A-6B8F7FC63A35.dita">Registering Services</xref>  </p> </li> <li id="GUID-6926A768-C9EA-594F-B81F-6CF4F79CF66C"><p> <xref href="GUID-33210C48-3198-51BC-9970-8B29F711A8E2.dita">Setting service record attributes</xref>  </p> </li> <li id="GUID-68498D90-4BE3-5826-9DF1-06D790301F1C"><p> <xref href="GUID-ED342E6B-A4A3-576B-8934-7E7C049837F0.dita">SDP Service records and attributes</xref>  </p> </li> </ol> <p>Also refer to the <xref href="GUID-E5893C4A-024A-53A7-805F-68989382DC3F.dita">Bluetooth Service Discovery Database overview</xref> and the <xref href="GUID-8451102A-8E68-5C86-9E40-D53183E32261.dita">Bluetooth SDP Overview</xref> for additional background information. </p> </section> </conbody></concept>