Channel class.
More...
#include <channel.h>
|
| Channel (identifier_t room, database_ptr db) |
| Construct a new Channel. More...
|
|
virtual void | join (subscriber_ptr subscriber) override |
| Join a user to channel. More...
|
|
virtual void | leave (subscriber_ptr subscriber) override |
| Leave a user from channel. More...
|
|
virtual void | notification (text_response_ptr response) override |
| Notify all channel subscribers about new message. More...
|
|
virtual identifier_t | get_room_id () const override |
| Get the room id object. More...
|
|
virtual | ~IRoom ()=default |
| Default virtual destructor.
|
|
Channel class.
Implement IRoom interface
- Todo:
- override virtual destructor to avoid potential problems in further
Channel::Channel |
( |
identifier_t |
room, |
|
|
database_ptr |
db |
|
) |
| |
|
inline |
Construct a new Channel.
- Parameters
-
virtual identifier_t Channel::get_room_id |
( |
| ) |
const |
|
inlineoverridevirtual |
Get the room id object.
- Returns
- identifier_t
Implements IRoom.
void Channel::join |
( |
subscriber_ptr |
subscriber | ) |
|
|
overridevirtual |
Join a user to channel.
- Parameters
-
subscriber | sbscriber who is joining this channel |
Implements IRoom.
void Channel::leave |
( |
subscriber_ptr |
subscriber | ) |
|
|
overridevirtual |
Leave a user from channel.
- Parameters
-
subscriber | sbscriber who is leaving this channel |
Implements IRoom.
void Channel::notification |
( |
text_response_ptr |
response | ) |
|
|
overridevirtual |
Notify all channel subscribers about new message.
- Parameters
-
Implements IRoom.
The documentation for this class was generated from the following files:
- src/server/channel/channel.h
- src/server/channel/channel.cpp