CatapultServer  v0.5.0.1 (Elephant)
catapult::observers::NotificationObserverAdapter Class Reference

A notification observer to entity observer adapter. More...

Inheritance diagram for catapult::observers::NotificationObserverAdapter:
Collaboration diagram for catapult::observers::NotificationObserverAdapter:

Public Member Functions

 NotificationObserverAdapter (NotificationObserverPointer &&pObserver, NotificationPublisherPointer &&pPublisher)
 Creates a new adapter around pObserver and pPublisher. More...
 
const std::string & name () const override
 Gets the observer name. More...
 
void notify (const model::WeakEntityInfo &entityInfo, ObserverContext &context) const override
 Notifies the observer with an entityInfo to process and an observer context. More...
 
- Public Member Functions inherited from catapult::observers::EntityObserver
virtual ~EntityObserver ()=default
 

Private Types

using NotificationObserverPointer = NotificationObserverPointerT< model::Notification >
 
using NotificationPublisherPointer = std::unique_ptr< const model::NotificationPublisher >
 

Private Attributes

NotificationObserverPointer m_pObserver
 
NotificationPublisherPointer m_pPublisher
 

Detailed Description

A notification observer to entity observer adapter.

Member Typedef Documentation

◆ NotificationObserverPointer

◆ NotificationPublisherPointer

Constructor & Destructor Documentation

◆ NotificationObserverAdapter()

catapult::observers::NotificationObserverAdapter::NotificationObserverAdapter ( NotificationObserverPointer &&  pObserver,
NotificationPublisherPointer &&  pPublisher 
)

Creates a new adapter around pObserver and pPublisher.

Member Function Documentation

◆ name()

const std::string & catapult::observers::NotificationObserverAdapter::name ( ) const
overridevirtual

Gets the observer name.

Implements catapult::observers::EntityObserver.

◆ notify()

void catapult::observers::NotificationObserverAdapter::notify ( const model::WeakEntityInfo entityInfo,
ObserverContext context 
) const
overridevirtual

Notifies the observer with an entityInfo to process and an observer context.

Implements catapult::observers::EntityObserver.

Member Data Documentation

◆ m_pObserver

NotificationObserverPointer catapult::observers::NotificationObserverAdapter::m_pObserver
private

◆ m_pPublisher

NotificationPublisherPointer catapult::observers::NotificationObserverAdapter::m_pPublisher
private

The documentation for this class was generated from the following files: