RaySDKDelegate

The delegate of an RSDK object must adopt the RaySDKDelegate protocol.

  • Tells the delegate that one or more beacons are in range.

    Declaration

    Swift

    optional func rsdkDidRangeRayBeacon(beacon: [RSDKBeacon]!, inRegionWithIdentifier identifier: String)

    Parameters

    beacon

    An array of verified RSDKBeacon objects representing the beacons currently in range.

    identifier

    The region identifier of the beacon ranged

  • Tells the delegate that the beacon has entered the region

    Declaration

    Swift

    optional func rsdkDidEnterRegionWithIdentifier(identifier: String)

    Parameters

    identifier

    The identifier of the region the beacon entered

  • Tells the delegate that the beacon has exited the region

    Declaration

    Swift

    optional func rsdkDidExitRegionWithIdentifier(identifier: String)

    Parameters

    identifier

    The identifier of the region the beacon exited

  • Tells the delegate that app has walked into a beacon range. The beacon will first be verified first before being returned

    Declaration

    Swift

    optional func rsdkDidWalkInToBeacon(beacon: RSDKBeacon!, inRegionWithIdentifier identifier: String)

    Parameters

    beacon

    The returned RSDKBeacon object that was ranged and verified

    identifier

    The region identifier of the beacon ranged

  • Tells the delegate that app has walked out of a beacon range.

    Declaration

    Swift

    optional func rsdkDidWalkOutOfBeacon(beacon: RSDKBeacon!, inRegionWithIdentifier identifier: String)

    Parameters

    beacon

    The returned RSDKBeacon object that the app has walked out of

    identifier

    The region identifier of the beacon ranged

  • Tells the delegate that the SDK beacon list has been set up

    Declaration

    Swift

    optional func rsdkListReady()
  • Tells the delegate that the an error occured

    Declaration

    Swift

    optional func rsdkDidFailWithError(error: NSError!)

    Parameters

    error

    The NSError object containing the error description and error code

  • Tells the delegate that a bluetooth peripheral’s state has changed

    Declaration

    Swift

    optional func rsdkBluetoothManagerDidUpdateState(state: BluetoothState)

    Parameters

    state

    The state the peripheral changed to.