CCHSensorPipelineDelegate Protocol Reference
Implement the delegate if you want to take action before or after an event is sent to ContextHub. You can also decide keep an event from firing.
Called when events are detected on the device.
- (void)sensorPipeline:(CCHSensorPipeline *)sensorPipeline didDetectEvent:(NSDictionary *)event
Called after an event was sent to ContextHub.
- (void)sensorPipeline:(CCHSensorPipeline *)sensorPipeline didPostEvent:(NSDictionary *)event
Sometimes you may want to keep an event from posting to the ContextHub service. This method gives you the opportunity to stop the call. If you return NO, none of the other delegate methods will get called, and the event will be discarded.
- (BOOL)sensorPipeline:(CCHSensorPipeline *)sensorPipeline shouldPostEvent:(NSDictionary *)event
boolean indicating if the event should be posted to ContextHUB
Note: No history of the event will be captured if you return NO here.