BloombergLP::ball::MultiplexObserver::registerObserver

Add the specified observer to the registry of this multiplexing observer.

Synopsis

Declared in <ball_multiplexobserver.h>

int
registerObserver(Observer* observer);

Description

Add the specified observer to the registry of this multiplexing observer. Return 0 if observer is non-null and was not already registered with this multiplexing observer, and a non-zero value (with no effect) otherwise. Henceforth, this multiplexing observer will forward each record it receives through its publish method, including the record's context, to the publish method of observer, until observer is deregistered. The behavior is undefined unless observer remains valid until it is deregistered from this multiplexing observer or until this observer is destroyed.

Return Value

0 if observer was registered, and a non-zero value otherwise

Parameters

NameDescription
observerobserver to register with this multiplexing observer