Set a subscription state change handler to be called by the Communication Management implementation as soon as the subscription state of this event changes.

The Communication Management implementation will serialize calls to the registered handler. If by any chance the application receives consecutive updates with the same subscription state, the handler will not be called again until an update with a state different from the last known one arrives.

Syntax

template <…>
void amsr::socal::r20_11::events::ProxyEvent<…>::SetSubscriptionStateHandler (ara::com::SubscriptionStateChangeHandler handler)

Parameters

in

handler

user-defined function. Must not be nullptr. Any exception thrown by the callback will lead to a termination through std::terminate().

Returns

void

Precondition

Subscribe() has not been called or Unsubscribe() has been called.

Thread-safety, Reentrance, Result Delivery

  • Threadsafe : FALSE for same class instance, TRUE for different instances
  • Reentrant : FALSE for same class instance, TRUE for different instances
  • Synchronous : TRUE