BGXpressScanner
BGXpressScanner is used to detect changes to the Bluetooth hardware and scan for devices. More...
Classes |
|
| protocol | <BGXpressScanDelegate > |
|
A protocol for keeping track of goings on with your
BGXpressScanner
.
More...
|
|
| class | BGXpressScanner |
Enumerations |
|
| enum | ScanState : NSUInteger { CantScan , Idle , Scanning } |
Detailed Description
BGXpressScanner is used to detect changes to the Bluetooth hardware and scan for devices.
It also contains a list of devices.
It has a delegate property using the BGXpressScanDelegate protocol.
Class Documentation
◆ BGXpressScanDelegate -p
| protocol BGXpressScanDelegate -p |
A protocol for keeping track of goings on with your BGXpressScanner .
Inherits <NSObject>.
Instance Methods |
|
| (void) | - bluetoothStateChanged: |
|
bluetoothStateChanged This is called to indicate that system state of Bluetooth changed.
More...
|
|
| (void) | - deviceDiscovered: |
|
This is called to indicate that the scanner has found a device.
More...
|
|
| (void) | - scanStateChanged: |
|
This method is called when the scanState has changed.
More...
|
|
Method Documentation
◆ bluetoothStateChanged:()
|
optional |
bluetoothStateChanged This is called to indicate that system state of Bluetooth changed.
◆ deviceDiscovered:()
|
optional |
This is called to indicate that the scanner has found a device.
You can access each device as its discovered (via the parameter) or access them all using the devicesDiscovered property which is an array of BGXDevice objects.
◆ scanStateChanged:()
|
optional |
This method is called when the scanState has changed.
◆ BGXpressScanner
| class BGXpressScanner |
Inherits NSObject, and <CBCentralManagerDelegate>.
Instance Methods |
|
| (BOOL) | - startScan |
|
Call this method to start scanning for devices.
More...
|
|
| (BOOL) | - stopScan |
|
Call this method to stop scanning for devices.
More...
|
|
Protected Attributes |
|
| ScanState | _scanState |
Properties |
|
| NSObject< BGXpressScanDelegate > * | delegate |
|
Assign this property to be your scan delegate.
More...
|
|
| NSMutableArray * | devicesDiscovered |
|
This is an array of
BGXDevice
objects discovered by the scanner.
More...
|
|
| ScanState | scanState |
|
The current state of the scanner.
More...
|
|
Method Documentation
◆ startScan()
| - (BOOL) startScan |
|
Call this method to start scanning for devices.
- Returns
- Boolean value to indicate if scanning will start.
- Remarks
- Calling this method will clear the contents of the devicesDiscovered mutable array property.
◆ stopScan()
| - (BOOL) stopScan |
|
Call this method to stop scanning for devices.
- Returns
- Boolean value to indicate if scanning will stop.
Member Data Documentation
◆ _scanState
|
protected |
Property Documentation
◆ delegate
|
read write nonatomic strong |
Assign this property to be your scan delegate.
◆ devicesDiscovered
|
read write nonatomic strong |
This is an array of BGXDevice objects discovered by the scanner.
This property will be made read only and immutable in the future.
◆ scanState
|
read nonatomic assign |
The current state of the scanner.
Enumeration Type Documentation
◆ ScanState
| enum ScanState : NSUInteger |