SHAPER  9.13.0
Events_MessageGroup Class Referenceabstract

Message that allows to group messages and send them later as a group of messages. More...

Inheritance diagram for Events_MessageGroup:
Inheritance graph

Public Member Functions

 Events_MessageGroup (const Events_ID theID, const void *theSender=0)
 Creates the message. More...
 
virtual ~Events_MessageGroup ()
 do nothing in the destructor yet More...
 
virtual std::shared_ptr< Events_MessageGroupnewEmpty ()=0
 Creates a new empty group (to store it in the loop before flush) More...
 
virtual void Join (const std::shared_ptr< Events_MessageGroup > &theJoined)=0
 Allows to join the given message with the current one. More...
 
const Events_IDeventID () const
 Returns identifier of the message. More...
 
void * sender () const
 Returns sender of the message or NULL if it is anonymous message. More...
 

Detailed Description

Message that allows to group messages and send them later as a group of messages.

Loop detects such messages and accumulates them without sending. On "flush" loop sends it as a group-message.

Constructor & Destructor Documentation

◆ Events_MessageGroup()

Events_MessageGroup::Events_MessageGroup ( const Events_ID  theID,
const void *  theSender = 0 
)

Creates the message.

◆ ~Events_MessageGroup()

Events_MessageGroup::~Events_MessageGroup ( )
virtual

do nothing in the destructor yet

Member Function Documentation

◆ newEmpty()

virtual std::shared_ptr<Events_MessageGroup> Events_MessageGroup::newEmpty ( )
pure virtual

Creates a new empty group (to store it in the loop before flush)

Implemented in ModelAPI_ObjectDeletedMessage, ModelAPI_ObjectUpdatedMessage, Model_ObjectDeletedMessage, and Model_ObjectUpdatedMessage.

◆ Join()

virtual void Events_MessageGroup::Join ( const std::shared_ptr< Events_MessageGroup > &  theJoined)
pure virtual

Allows to join the given message with the current one.

Implemented in ModelAPI_ObjectDeletedMessage, ModelAPI_ObjectUpdatedMessage, Model_ObjectDeletedMessage, and Model_ObjectUpdatedMessage.

◆ eventID()

const Events_ID& Events_Message::eventID ( ) const
inlineinherited

Returns identifier of the message.

◆ sender()

void* Events_Message::sender ( ) const
inlineinherited

Returns sender of the message or NULL if it is anonymous message.