bluetoothengine/headsetsimulator/profiles/hspprofile/inc/hspsdp.h
branchheadsetsimulator
changeset 60 90dbfc0435e3
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bluetoothengine/headsetsimulator/profiles/hspprofile/inc/hspsdp.h	Wed Sep 15 15:59:44 2010 +0200
@@ -0,0 +1,100 @@
+/* 
+ *
+ * Copyright (c) <2010> Comarch S.A. and/or its subsidiary(-ies).
+ * All rights reserved.
+ * This component and the accompanying materials are made available
+ * under the terms of the License "Eclipse Public License v1.0"
+ * which accompanies this distribution, and is available
+ * at the URL "http://www.eclipse.org/legal/epl-v10.html".
+ *
+ * Original Contributors:
+ * Comarch S.A. - original contribution.
+ *
+ * Contributors:
+ *
+ * Description:
+ *
+ */
+
+#ifndef HSPSDP_H_
+#define HSPSDP_H_
+
+#include <btsdp.h>
+#include <hssdppluginbase.h>
+
+/** Headset Uid */
+const TInt KHsHeadsetUid = 0x1131;
+
+/** Generic Audio Uid */
+const TInt KHsGenericAudioUid = 0x1203;
+
+/** Profile's UID */
+const TInt KHsHeadsetProfileUid = 0x1108;
+
+/** Profile's version */
+const TInt KHsHeadsetProfileVersion = 0x0102;
+
+/** Supported remote audio volume control UID */
+const TInt KHsRemoteAudioVolumeControl = 0x0302;
+/** Service name */
+_LIT(KHsServiceNameHeadset, "Headset");
+
+/**
+ * @brief Manages SDP record
+ */
+class CHsHSPSDP : public CHsSdpBase
+{
+public:
+    /**
+     * Two-phase constructor
+     * 
+     * @return instance of class
+     */
+    static CHsHSPSDP* NewL();
+
+    /**
+     * Two-phase constructor
+     * 
+     * @return instance of class
+     */
+    static CHsHSPSDP* NewLC();
+
+    /**
+     * Destructor
+     */
+    ~CHsHSPSDP();
+
+public:
+    /**
+     * Creates SDP record
+     */
+    void CreateSdpRecordL();
+
+    /**
+     * Destroys SDP record
+     */
+    void DeleteSdpRecordL();
+
+private:
+    /**
+     * Constructor for performing 1st stage construction
+     */
+    CHsHSPSDP();
+
+    /**
+     * Constructor for performing 2nd stage construction
+     */
+    void ConstructL();
+
+private:
+    /** Session to the SDP */
+    RSdp iSdp;
+
+    /** Subsession to the SDP */
+    RSdpDatabase iSdpDatabase;
+
+    /** Handle to SDP record */
+    TSdpServRecordHandle iSdpRecordHandle;
+};
+
+#endif /* HSPSDP_H_ */