Documentation
¶
Index ¶
- type AdFilter
- func All(filters []AdFilter) AdFilter
- func Any(filters []AdFilter) AdFilter
- func ByAdData(typ hci.AdType, preamble []byte) AdFilter
- func ByAdType(typ hci.AdType) AdFilter
- func ByAddress(address hci.BtAddress) AdFilter
- func ByIrk(irk []byte) AdFilter
- func ByPartialAddress(buf []byte) AdFilter
- func ByVendor(preamble []byte) AdFilter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdFilter ¶
type AdFilter interface {
Filter(*hci.AdvertisingReport) bool
}
AdFilter can be used to filter incoming Advertising Reports if Filter() returns true, matching ScanReport is created and passed to the channel returned by Host.StartScan()
func ByAdData ¶
ByAdData return AdFilter which can be used to filter Advertising Reports based on Ad Type and start of the advertising data. The filter matches if both type and the start of the data match the ones given to the filter
func ByAdType ¶
ByAdType returns filter which can be used to filter Advertising Reports based on the Type field in the Ad Structures contained on the Advertising Reports
func ByAddress ¶
ByAddress returns AdFilter which filters Advertising Reports by sender address. Filter passes report if it comes from given address
func ByIrk ¶
ByIrk returns filter which returns true if advertiser address is resolvable using given irk
func ByPartialAddress ¶
ByPartialAddress returns filter which matches a partial address bytes against bytes given in buffer.
func ByVendor ¶
ByVendor returns AdFilter which can be used to filter Advertising Reports based on the start of its vendor specific Advertising Data. Filter passes Advertising Reports which have vendor -specific advertising data and the first bytes of the vendor specific data match the given preamble.