Protocols

The following protocols are available globally.

Main SDK Interface Protocol

  • This is the main “generic” protocol, applicable to both Central and Peripheral.

    The SDK defines an interface between Bluetooth LE devices and abstracts Apple’s Core Bluetooth Library.

    The SDK can be instantiated as either a Bluetooth LE “Central,” or as a “Peripheral.”.

    The role of the SDK is determined by which variant of the SDK is instantiated.

    This is a teaching aid, and, as such, has an extremely limited and tightly-defined functionality. It is a Bluetooth expression of a “Magic 8-Ball” app.

    Centrals are instantiated as ITCB_SDK_Central instances, and Peripherals are instantiated as ITCB_SDK_Peripheral instances. They are described as protocols, instead of concrete classes or structs, in order to assure opacity and flexibility.

    All protocol members are required (Except for the internal createInstance() method; which is, in reality, required).

    See more

    Declaration

    Swift

    public protocol ITCB_SDK_Protocol

This is the protocol for a Central Instance of the SDK

This is the protocol for a Peripheral Instance of the SDK

This is the “Base” Device Protocol for the Main SDK

This is the Central Device Protocol Specialization for the Main SDK

This is the Peripheral Device Protocol Specialization for the Main SDK

Observer Protocol for the Main SDK

  • This protocol describes an instance that can register to observe the main SDK.

    All members are required.

    See more

    Declaration

    Swift

    public protocol ITCB_Observer_Protocol

This is the protocol for an Observer of the Central Instance of the SDK

This is the protocol for an Observer of the Peripheral Instance of the SDK