MoSync 3.3
MAUtil::BluetoothDiscoverer Class Reference

A class that connects to Environment and handles Bluetooth discovery operations. More...

#include <MAUtil/BluetoothDiscovery.h>

Inheritance diagram for MAUtil::BluetoothDiscoverer:
MAUtil::BluetoothListener

List of all members.

Public Member Functions

 BluetoothDiscoverer ()
int startDeviceDiscovery (BluetoothDeviceDiscoveryListener *listener, bool names)
int startServiceDiscovery (const MABtAddr &address, const MAUUID &uuid, BluetoothServiceDiscoveryListener *listener)
int cancel ()

Detailed Description

A class that connects to Environment and handles Bluetooth discovery operations.


Constructor & Destructor Documentation


Member Function Documentation

Starts a device discovery operation.

Will cause a panic if there is no Environment, or if listener is NULL, or if the previous operation has not yet completed.

Parameters:
listenerA pointer to the object that will receive the events generated by the operation.
namesIf true, the operation will fetch the names of the remote devices. This will take extra time. If false, names will not be fetched, speeding up the operation.
Returns:
Zero, if the operation started successfully. Less than zero, if the operation failed. In that case, the operation is considered complete and another may be attempted.

Starts a service discovery operation.

Will cause a panic if there is no Environment, or if listener is NULL, or if the previous operation has not yet completed.

Parameters:
addressThe address of the device to query.
uuidThe service class UUID to search for.
listenerA pointer to the object that will receive the events generated by the operation.
Returns:
Zero, if the operation started successfully. Less than zero, if the operation failed. In that case, the operation is considered complete and another may be attempted.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines