You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

68 lines
3.0 KiB

2 years ago
/*
BabyBluetooth
ble库CoreBluetooth
https://github.com/coolnameismy/BabyBluetooth
@brief babybluetooth 广service参数characteristic参数
*/
// Created by 刘彦玮 on 15/9/27.
// Copyright © 2015年 刘彦玮. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <CoreBluetooth/CoreBluetooth.h>
@interface BabyOptions : NSObject
#pragma mark - 属性
/*!
* ,centralManager:scanForPeripheralsWithServices:self.scanForPeripheralsWithServices options:self.scanForPeripheralsWithOptions
* @param An optional dictionary specifying options for the scan.
* @see centralManager:scanForPeripheralsWithServices
* @seealso CBCentralManagerScanOptionAllowDuplicatesKey :Peripheral端的多个发现事件被聚合成一个发现事件
* @seealso CBCentralManagerScanOptionSolicitedServiceUUIDsKey
*/
@property (nonatomic, copy) NSDictionary *scanForPeripheralsWithOptions;
/*!
*
* @method connectPeripheral:options:
* @param An optional dictionary specifying connection behavior options.
* @see centralManager:didConnectPeripheral:
* @see centralManager:didFailToConnectPeripheral:error:
* @seealso CBConnectPeripheralOptionNotifyOnConnectionKey
* @seealso CBConnectPeripheralOptionNotifyOnDisconnectionKey
* @seealso CBConnectPeripheralOptionNotifyOnNotificationKey
*/
@property (nonatomic, copy) NSDictionary *connectPeripheralWithOptions;
/*!
* ,centralManager:scanForPeripheralsWithServices:self.scanForPeripheralsWithServices options:self.scanForPeripheralsWithOptions
*@param serviceUUIDs A list of <code>CBUUID</code> objects representing the service(s) to scan for.
*@see centralManager:scanForPeripheralsWithServices
*/
@property (nonatomic, copy) NSArray *scanForPeripheralsWithServices;
// [peripheral discoverServices:self.discoverWithServices];
@property (nonatomic, copy) NSArray *discoverWithServices;
// [peripheral discoverCharacteristics:self.discoverWithCharacteristics forService:service];
@property (nonatomic, copy) NSArray *discoverWithCharacteristics;
#pragma mark - 构造方法
- (instancetype)initWithscanForPeripheralsWithOptions:(NSDictionary *)scanForPeripheralsWithOptions
connectPeripheralWithOptions:(NSDictionary *)connectPeripheralWithOptions;
- (instancetype)initWithscanForPeripheralsWithOptions:(NSDictionary *)scanForPeripheralsWithOptions
connectPeripheralWithOptions:(NSDictionary *)connectPeripheralWithOptions
scanForPeripheralsWithServices:(NSArray *)scanForPeripheralsWithServices
discoverWithServices:(NSArray *)discoverWithServices
discoverWithCharacteristics:(NSArray *)discoverWithCharacteristics;
@end