7f2d2857ae0e0e39f6db13ba378bc0c681653439
[framework/osp/bluetooth.git] / inc / FNetBtBluetoothManager.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18 /**
19  * @file    FNetBtBluetoothManager.h
20  * @brief   This is the header file for the %BluetoothManager class.
21  *
22  * This header file contains the declarations of the %BluetoothManager class.
23  */
24 #ifndef _FNET_BT_BLUETOOTH_MANAGER_H_
25 #define _FNET_BT_BLUETOOTH_MANAGER_H_
26
27 #include <FBaseObject.h>
28 #include <FBaseResult.h>
29 #include <FNetBtBluetoothTypes.h>
30
31 namespace Tizen { namespace Base
32 {
33 class String;
34 class ByteBuffer;
35 namespace Collection
36 {
37 class IList;
38 }
39 } }
40
41 namespace Tizen { namespace Net { namespace Bluetooth
42 {
43
44 // forward declarations
45 class BluetoothDevice;
46 class IBluetoothManagerEventListener;
47 class IBluetoothDeviceEventListener;
48 class _BluetoothManagerImpl;
49
50 /**
51  * @class   BluetoothManager
52  * @brief   This class is used to obtain information about the local device or the paired devices, and to configure
53  *          the %Bluetooth stack.
54  * @since   2.0
55  *
56  * The %BluetoothManager class is used to obtain information about the local device or the paired devices and to configure the
57  * %Bluetooth stack.
58  *
59  * For more information on the class features, see
60  * <a href="../org.tizen.native.appprogramming/html/guide/net/bluetooth_namespace.htm">Bluetooth Guide</a>.
61  */
62 class _OSP_EXPORT_ BluetoothManager
63         : public Tizen::Base::Object
64 {
65 public:
66         /**
67          * The object is not fully constructed after this constructor is called. For full construction, the Construct()
68          * method must be called right after calling this constructor.
69          *
70          * @since       2.0
71          */
72         BluetoothManager(void);
73
74         /**
75          * This destructor overrides Tizen::Base::Object::~Object().
76          *
77          * @since       2.0
78          */
79         virtual ~BluetoothManager(void);
80
81         /**
82          * Constructs and initializes an instance of the %BluetoothManager class with the specified listener.
83          *
84          * @since       2.0
85          * @feature     %http://tizen.org/feature/network.bluetooth
86          *
87          * @return      An error code
88          * @param[in]   listener                The listener to handle the %BluetoothManager event
89          * @exception   E_SUCCESS               The method is successful.
90          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
91          * @exception   E_UNSUPPORTED_OPERATION The Emulator or target device does not support the required feature.
92          *                                      For more information, see
93          *                                      <a href="../org.tizen.gettingstarted/html/tizen_overview/application_filtering.htm">
94          *                                      Application Filtering</a>.
95          * @exception   E_SYSTEM                A system error has occurred.
96          * @remarks     Before calling this method, check whether the feature is supported by %Tizen::System::SystemInfo::GetValue()
97          *              methods.
98          */
99         result Construct(IBluetoothManagerEventListener& listener);
100
101         /**
102          * Activates %Bluetooth on a device.
103          *
104          * @since       2.0
105          * @privlevel   public
106          * @privilege   %http://tizen.org/privilege/bluetooth.admin
107          *
108          * @return      An error code
109          * @exception   E_SUCCESS               The method is successful.
110          * @exception   E_IN_PROGRESS           The %Bluetooth activation process is in progress.
111          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of the specified
112          *                                      operation. @n
113          *                                      For example, %Bluetooth is already activated.
114          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
115          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
116          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
117          * @exception   E_SYSTEM                A system error has occurred.
118          * @see         IBluetoothManagerEventListener::OnBluetoothActivated()
119          */
120         result Activate(void);
121
122         /**
123          * Deactivates %Bluetooth on a device.
124          *
125          * @since       2.0
126          * @privlevel   public
127          * @privilege   %http://tizen.org/privilege/bluetooth.admin
128          *
129          * @return      An error code
130          * @exception   E_SUCCESS               The method is successful.
131          * @exception   E_IN_PROGRESS           The %Bluetooth deactivation process is in progress.
132          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of the specified
133          *                                      operation. @n
134          *                                      For example, the %Bluetooth is already deactivated.
135          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
136          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
137          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
138          * @exception   E_SYSTEM                A system error has occurred.
139          * @see         IBluetoothManagerEventListener::OnBluetoothDeactivated()
140          */
141         result Deactivate(void);
142
143         /**
144          * @if OSPDEPREC
145          * Checks whether a %Bluetooth-specific profile is available.
146          *
147          * @brief <i> [Deprecated]  </i>
148          * @deprecated  This method is deprecated because multiple clients as well as multiple SPP servers with unique
149          *              service UUIDs are supported. In case of OPP server, invoke
150          *              BluetoothOppServer::StartService() directly without checking OPP server's availability.
151          *              If a new OPP server is not available, the method returns the E_SERVICE_UNAVAILABLE exception.
152          * @since       2.0
153          *
154          * @return      @c true if the specified type of connection is available, @n
155          *              else @c false
156          * @param[in]   type                    The connection type
157          *
158          * @endif
159          */
160         bool IsAvailable(BluetoothConnectionType type) const;
161
162         /**
163          * @if OSPDEPREC
164          * Gets the local device information.
165          *
166          * @brief <i> [Deprecated]  </i>
167          * @deprecated  This method is deprecated because the return value of this method is a dangling pointer if this
168          *              instance of %BluetoothManager is deleted. In addition to this, the %BluetoothDevice class
169          *              represents only remote devices since Tizen. Instead of using this method, the GetLocalDeviceAddress()
170          *              and GetLocalDeviceName() methods are recommended.
171          * @since       2.0
172          *
173          * @return      The local device information
174          * @exception   E_SUCCESS               The method is successful.
175          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
176          * @exception   E_SYSTEM                A system error has occurred.
177          * @remarks     The specific error code can be accessed using the GetLastResult() method.
178          * @endif
179          */
180         const BluetoothDevice* GetLocalDevice(void) const;
181
182         /**
183          * Gets the local %Bluetooth device address.
184          *
185          * @since       2.0
186          *
187          * @return      The local %Bluetooth device address @n
188          *              The address is expressed as a @c 6 byte hexadecimal value delimited by colons. @n
189          *              For example, "00:3D:47:EF:8A:03".
190          */
191         Tizen::Base::String GetLocalDeviceAddress(void) const;
192
193         /**
194          * Gets the local %Bluetooth device name.
195          *
196          * @since       2.0
197          *
198          * @return      The local %Bluetooth device name
199          */
200         Tizen::Base::String GetLocalDeviceName(void) const;
201
202         /**
203          * @if OSPDEPREC
204          * Gets the operational mode of the %Bluetooth unit.
205          *
206          * @brief <i> [Deprecated]  </i>
207          * @deprecated  %BluetoothDeviceStateType is deprecated. Therefore, this method is also deprecated, because the
208          *              return value of this method is of type %BluetoothDeviceStateType. Instead of using this method, the
209          *              IsActivated() and GetDiscoverableMode() methods are recommended.
210          *
211          * @since       2.0
212          *
213          * @return      The operational mode
214          * @endif
215          */
216         BluetoothDeviceStateType GetLocalDeviceState(void) const;
217
218         /**
219          * Checks whether the local %Bluetooth is activated.
220          *
221          * @since       2.0
222          *
223          * @return      @c true if the local %Bluetooth is activated, @n
224          *              else @c false
225          */
226         bool IsActivated(void) const;
227
228         /**
229          * Gets the discoverable mode of the local device.
230          *
231          * @if OSPCOMPAT
232          * @brief <i> [Compatibility]  </i>
233          * @endif
234          * @since       2.0
235          * @if OSPCOMPAT
236          * @compatibility   This method has compatibility issues. @n
237          *                  For more information, see @ref BluetoothManagerGetDiscoverableModePage "here".
238          *
239          * @endif
240          * @return      The discoverable mode of the local device
241          */
242         BluetoothDiscoverableMode GetDiscoverableMode(void) const;
243
244         /**
245          * @if OSPCOMPAT
246          * @page        BluetoothManagerGetDiscoverableModePage Compatibility for GetDiscoverableMode()
247          *
248          * @section     BluetoothManagerGetDiscoverableModePageIssueSection Issues
249          *              Implementation of this method in API versions prior to 2.0 has the following issue: @n
250          *
251          *              -# The always discoverable mode and the discoverable mode with a certain amount of time cannot be
252          *              differentiated. BT_DISC_MODE_DISCOVERABLE of BluetoothDiscoverableMode means both.
253          *
254          * @section     BluetoothManagerGetDiscoverableModePageSolutionSection Resolutions
255          *              The issue mentioned above is resolved in API version 2.0, and it is recommended to use API version
256          *              3.0 or above. @n
257          *
258          *              -# The new element, BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE, is added into BluetoothDiscoverableMode
259          *              in API version 2.0, Therefore, BT_DISC_MODE_DISCOVERABLE means the always discoverable mode and
260          *              BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE means the discoverable mode with a certain amount of time.
261          * @endif
262          */
263
264         /**
265          * Gets the remaining time, in seconds, until the discoverable mode is changed from
266          * ::BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE to be ::BT_DISC_MODE_NOT_DISCOVERABLE. @n
267          * The %GetRemainingTimeAsDiscoverable() method is valid only if the current discoverable mode is @c
268          * BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE.
269          *
270          * @since 2.0
271          *
272          * @return      The remaining time, in seconds, until the local device is not discoverable @n
273          *              @c 0 is returned if the current discoverable mode is not ::BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE.
274          */
275         int GetRemainingTimeAsDiscoverable(void) const;
276
277         /**
278          * Checks whether the device discovery is in progress.
279          *
280          * @since       2.0
281          *
282          * @return      @c true if the device discovery is in progress, @n
283          *              else @c false
284          */
285         bool IsDiscoveryInProgress(void) const;
286
287         /**
288          * Sets a name of the local device. @n
289          * The searching device detects the local devices in close proximity based on the specified device name, and the
290          * name is only valid while an application is active.
291          *
292          * @since       2.0
293          * @privlevel   public
294          * @privilege   %http://tizen.org/privilege/bluetooth.admin
295          *
296          * @return      An error code
297          * @param[in]   deviceName              The new device name @n
298          *                                      The specified device name is automatically truncated if its size is greater
299          *                                      than @c 64 bytes.
300          * @exception   E_SUCCESS               The method is successful.
301          * @exception   E_INVALID_ARG           The specified device name is an empty string.
302          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
303          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
304          * @exception   E_SYSTEM                A system error has occurred.
305          * @remarks     This method does not affect the system settings.
306          */
307         result SetLocalDeviceName(const Tizen::Base::String& deviceName);
308
309         /**
310          * Sets the discoverable mode of the local device.
311          *
312          * @since 2.0
313          * @privlevel   platform
314          * @privilege   %http://tizen.org/privilege/bluetoothmanager
315          *
316          * @return      An error code
317          * @param[in]   mode                    The new discoverable mode
318          * @param[in]   seconds                 The duration in seconds for which the local device is discoverable @n
319          *                                      The specified duration is adopted only if the specified @c mode is
320          *                                      @c BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE.
321          * @exception   E_SUCCESS               The method is successful.
322          * @exception   E_INVALID_ARG           The specified @c seconds should be greater than 0 if the specified @c mode
323          *                                      is @c BT_DISC_MODE_TIME_LIMITED_DISCOVERABLE.
324          * @exception   E_INVALID_OPERATION     %Bluetooth is not activated.
325          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
326          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
327          * @exception   E_SYSTEM                A system error has occurred.
328          * @see         IBluetoothManagerEventListener::OnBluetoothDiscoverableModeChanged()
329          */
330         result SetDiscoverableMode(BluetoothDiscoverableMode mode, int seconds = 0);
331
332         /**
333          * @if OSPDEPREC
334          * Refreshes the paired device list.
335          *
336          * @brief <i> [Deprecated]  </i>
337          * @deprecated  This method is deprecated because the paired device list of this instance of %BluetoothManager is
338          *              refreshed automatically. An application should not call this method to refresh the list.
339          * @since       2.0
340          *
341          * @return      An error code
342          * @exception   E_SUCCESS               The method is successful.
343          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
344          * @exception   E_SYSTEM                A system error has occurred.
345          * @endif
346          */
347         result RefreshPairedDeviceList(void);
348
349         /**
350          * @if OSPDEPREC
351          * Searches for an element that matches a %Bluetooth address.
352          *
353          * @brief <i> [Deprecated]  </i>
354          * @deprecated  This method is deprecated because the return value of this method is a dangling pointer, if this
355          *              instance of %BluetoothManager is deleted. In addition to this, it is also an invalid pointer if the
356          *              paired device list is updated internally. Instead of using this method, GetPairedDeviceByAddressN()
357          *              is recommended.
358          * @since       2.0
359          *
360          * @return      The instance of %BluetoothDevice containing the specified address, @n
361          *              else @c null if the search is not successful
362          * @param[in]   deviceAddress           The address to locate
363          * @exception   E_SUCCESS               The method is successful.
364          * @exception   E_OBJ_NOT_FOUND         The specified device is not found in the paired device list.
365          * @remarks     The specific error code can be accessed using the GetLastResult() method.
366          * @endif
367          */
368         const BluetoothDevice* GetPairedDeviceByAddress(const Tizen::Base::ByteBuffer& deviceAddress) const;
369
370         /**
371          * Gets an element that matches a %Bluetooth address.
372          *
373          * @since       2.0
374          *
375          * @return      The instance of %BluetoothDevice containing the specified address, @n
376          *              else @c null if the search is not successful
377          * @param[in]   deviceAddress           The address to locate
378          * @exception   E_SUCCESS               The method is successful.
379          * @exception   E_OBJ_NOT_FOUND         The specified device is not found in the paired device list.
380          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
381          * @remarks     The specific error code can be accessed using the GetLastResult() method.
382          */
383         BluetoothDevice* GetPairedDeviceByAddressN(const Tizen::Base::ByteBuffer& deviceAddress) const;
384
385         /**
386          * Gets the elements matching a device name in the paired device list.
387          *
388          * @since       2.0
389          *
390          * @return      A list containing the matching devices, @n
391          *              else @c null if the search is not successful
392          * @param[in]   deviceName              The name of the device to locate
393          * @exception   E_SUCCESS               The method is successful.
394          * @exception   E_OBJ_NOT_FOUND         The specified device is not found in the paired device list.
395          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
396          * @remarks     The specific error code can be accessed using the GetLastResult() method.
397          */
398         Tizen::Base::Collection::IList* GetPairedDeviceByNameN(const Tizen::Base::String& deviceName) const;
399
400         /**
401          * @if OSPDEPREC
402          * Gets the element at the specified index.
403          *
404          * @brief <i> [Deprecated]  </i>
405          * @deprecated  This method is deprecated because the return value of this method is a dangling pointer, if this
406          *              instance of %BluetoothManager is deleted. In addition to this, it is also an invalid pointer if the
407          *              paired device list is updated internally. Instead of using this method, GetPairedDeviceListN() and
408          *              Tizen::Base::Collection::IList::GetAt() are recommended.
409          * @since       2.0
410          *
411          * @return      The instance of %BluetoothDevice at the specified index, @n
412          *              else @c null if there is no element
413          * @param[in]   index                   The index in the list
414          * @exception   E_SUCCESS               The method is successful.
415          * @exception   E_OBJ_NOT_FOUND         The specified index is not found in the paired device list.
416          * @remarks     The specific error code can be accessed using the GetLastResult() method.
417          * @endif
418          */
419         const BluetoothDevice* GetPairedDeviceAt(int index) const;
420
421         /**
422          * @if OSPDEPREC
423          * Gets the paired device list.
424          *
425          * @brief <i> [Deprecated]  </i>
426          * @deprecated  This method is deprecated because the return value of this method is a dangling pointer, if this
427          *              instance of %BluetoothManager is deleted. In addition to this, some elements of the list may also
428          *              be invalid pointers if the paired device list is updated internally. Instead of using this method,
429          *              GetPairedDeviceListN() is recommended.
430          * @since       2.0
431          *
432          * @return      A pointer to the paired device list on success, @n
433          *              else @c null
434          * @exception   E_SUCCESS               The method is successful.
435          * @remarks     The specific error code can be accessed using the GetLastResult() method.
436          * @endif
437          */
438         const Tizen::Base::Collection::IList* GetPairedDeviceList(void) const;
439
440         /**
441          * Gets the paired device list.
442          *
443          * @since       2.0
444          *
445          * @return      A pointer to the paired device list on success, @n
446          *              else @c null
447          * @exception   E_SUCCESS               The method is successful.
448          * @exception   E_OUT_OF_MEMORY         The memory is insufficient.
449          * @remarks     The specific error code can be accessed using the GetLastResult() method.
450          */
451         Tizen::Base::Collection::IList* GetPairedDeviceListN(void) const;
452
453         /**
454          * Sets a remote device event listener for searching devices and services.
455          *
456          * @since       2.0
457          *
458          * @return      An error code
459          * @param[in]   pListener               The device event listener to set @n
460          *                                      If the specified listener is @c null, the listener currently set is
461          *                                      unregistered.
462          * @exception   E_SUCCESS               The method is successful.
463          * @exception   E_SYSTEM                A system error has occurred.
464          * @remarks     Only one event listener can be set.
465          */
466         result SetBluetoothDeviceListener(IBluetoothDeviceEventListener* pListener);
467
468         /**
469          * Starts the device discovery process.
470          *
471          * @since       2.0
472          * @privlevel   public
473          * @privilege   %http://tizen.org/privilege/bluetooth.gap
474          *
475          * @return      An error code
476          * @exception   E_SUCCESS               The method is successful.
477          * @exception   E_IN_PROGRESS           The device discovery process is in progress.
478          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
479          *                                      operation.
480          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
481          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
482          * @exception   E_SYSTEM                A system error has occurred.
483          * @see         IBluetoothDeviceEventListener::OnBluetoothDiscoveryStarted()
484          * @see         IBluetoothDeviceEventListener::OnBluetoothRemoteDeviceFoundN()
485          * @see         IBluetoothDeviceEventListener::OnBluetoothDiscoveryDone()
486          */
487         result StartDiscovery(void);
488
489         /**
490          * Cancels the device discovery process.
491          *
492          * @since       2.0
493          * @privlevel   public
494          * @privilege   %http://tizen.org/privilege/bluetooth.gap
495          *
496          * @return      An error code
497          * @exception   E_SUCCESS               The method is successful.
498          * @exception   E_IN_PROGRESS           The termination of the device discovery process is in progress.
499          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
500          *                                      operation. @n
501          *                                      For example, the discovery has not started as yet.
502          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
503          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
504          * @exception   E_SYSTEM                A system error has occurred.
505          * @see         IBluetoothDeviceEventListener::OnBluetoothDiscoveryDone()
506          */
507         result CancelDiscovery(void);
508
509         /**
510          * Retrieves the service list from a remote device.
511          *
512          * @since       2.0
513          * @privlevel   public
514          * @privilege   %http://tizen.org/privilege/bluetooth.gap
515          *
516          * @return      An error code
517          * @param[in]   pairedDevice            A remote device that is already paired with the local device
518          * @exception   E_SUCCESS               The method is successful.
519          * @exception   E_IN_PROGRESS           The retrieving is in progress.
520          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
521          *                                      operation. @n
522          *                                      For example, the discovery is in progress.
523          * @exception   E_NOT_PAIRED            The input device is not found in the paired device list.
524          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
525          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
526          * @exception   E_SYSTEM                A system error has occurred.
527          * @remarks     The target remote device should be a paired device.
528          * @see         IBluetoothDeviceEventListener::OnBluetoothServiceListReceived()
529          */
530         result RetrieveServiceList(const BluetoothDevice& pairedDevice);
531
532         /**
533          * Pairs with the specified remote device.
534          *
535          * @since 2.0
536          * @privlevel   public
537          * @privilege   %http://tizen.org/privilege/bluetooth.gap
538          *
539          * @return      An error code
540          * @param[in]   remoteDevice            The remote %Bluetooth device to pair with
541          * @exception   E_SUCCESS               The method is successful.
542          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
543          *                                      operation. @n
544          *                                      For example, the %Bluetooth is not activated.
545          * @exception   E_DEVICE_BUSY           The device cannot be approached because other operation is in progress.
546          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
547          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
548          * @exception   E_SYSTEM                A system error has occurred.
549          * @remarks     IBluetoothDeviceEventListener::OnBluetoothPaired() is called if the pairing is successful, @n
550          *              IBluetoothDeviceEventListener::OnBluetoothPairingFailed() if the pairing has failed.
551          */
552         result Pair(const BluetoothDevice& remoteDevice);
553
554         /**
555          * Stops the pairing process.
556          *
557          * @since 2.0
558          * @privlevel   public
559          * @privilege   %http://tizen.org/privilege/bluetooth.gap
560          *
561          * @return      An error code
562          * @exception   E_SUCCESS               The method is successful.
563          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
564          *                                      operation. @n
565          *                                      For example, the pairing process is not in progress.
566          * @exception   E_IN_PROGRESS           The termination of the pairing process is in progress.
567          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
568          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
569          * @exception   E_SYSTEM                A system error has occurred.
570          * @remarks     If the canceling of the pairing process is successful, @n
571          *              IBluetoothDeviceEventListener::OnBluetoothPairingFailed() is called with @c E_OPERATION_CANCELED.
572          */
573         result CancelPair(void);
574
575         /**
576          * Unpairs with a paired device. @n
577          * The process of unpairing is to remove a specified device from the paired device list. No notification is
578          * transmitted to the remote device. @n
579          * The %Unpair() method is synchronous. Only when the result of this method is @c E_SUCCESS, the unpaired event is fired.
580          *
581          * @since       2.0
582          * @privlevel   public
583          * @privilege   %http://tizen.org/privilege/bluetooth.gap
584          *
585          * @return      An error code
586          * @param[in]   pairedDevice            The paired device to unpair
587          * @exception   E_SUCCESS               The method is successful.
588          * @exception   E_INVALID_OPERATION     The current state of the instance prohibits the execution of this
589          *                                      operation. @n
590          *                                      For example, the %Bluetooth is not activated, or retrieving the service
591          *                                      list is in progress.
592          * @exception   E_NOT_PAIRED            The input device is not found in the paired device list.
593          * @exception   E_PRIVILEGE_DENIED      The application does not have the privilege to call this method.
594          * @exception   E_USER_NOT_CONSENTED    The user blocks an application from calling this method. @b Since: @b 2.1
595          * @exception   E_SYSTEM                A system error has occurred.
596          * @see         IBluetoothDeviceEventListener::OnBluetoothUnpaired()
597          */
598         result Unpair(const BluetoothDevice& pairedDevice);
599
600 private:
601         //
602         // The implementation of this copy constructor is intentionally blank to prohibit copying of objects.
603         //
604         BluetoothManager(const BluetoothManager& value);
605
606         //
607         // The implementation of this copy assignment operator is intentionally blank to prohibit copying of objects.
608         //
609         BluetoothManager& operator =(const BluetoothManager& value);
610
611 private:
612         _BluetoothManagerImpl* __pImpl;
613
614         friend class _BluetoothManagerImpl;
615
616 }; // BluetoothManager
617
618 } } }
619 #endif // _FNET_BT_BLUETOOTH_MANAGER_H_