# Poco

# class AsyncNotificationCenter

Library: Foundation
Package: Notifications
Header: Poco/AsyncNotificationCenter.h

## Description

AsyncNotificationCenter decouples posting of notifications from notifying subscribers by calling observers' notification handler in a dedicated thread.

## Inheritance

Direct Base Classes: NotificationCenter

All Base Classes: NotificationCenter

## Member Summary

Member Functions: backlog, operator =, postNotification

Inherited Functions: addObserver, backlog, countObservers, defaultCenter, hasObserver, hasObservers, mutex, notifyObservers, observersToNotify, postNotification, removeObserver

## Constructors

### AsyncNotificationCenter

AsyncNotificationCenter();

Creates the AsyncNotificationCenter and starts the notifying thread.

### AsyncNotificationCenter

AsyncNotificationCenter(
const AsyncNotificationCenter & param164
) = delete;

### AsyncNotificationCenter

AsyncNotificationCenter(
AsyncNotificationCenter && param166
) = delete;

## Destructor

### ~AsyncNotificationCenter

~AsyncNotificationCenter();

Stops the notifying thread and destroys the AsyncNotificationCenter.

## Member Functions

### backlog

virtual int backlog() const;

Returns the numbner of notifications in the notification queue.

See also: Poco::NotificationCenter::backlog()

### operator =

AsyncNotificationCenter & operator = (
const AsyncNotificationCenter & param163
) = delete;

### operator =

AsyncNotificationCenter & operator = (
AsyncNotificationCenter && param165
) = delete;

### postNotification

virtual void postNotification(
Notification::Ptr pNotification
);

Enqueues notification into the notification queue.

See also: Poco::NotificationCenter::postNotification()