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