Controller.
More...
#include <control.h>
|
| Control (int argc, char **argv) |
|
void | connect_to_server (const std::string &login, const std::string &password, TypeCommand command) |
| Start communication with server. More...
|
|
| ~Control () |
| Close client socket when destroy UI controller.
|
|
void Control::autorisation |
( |
const std::string & |
login, |
|
|
const std::string & |
password |
|
) |
| |
|
inlineslot |
User autorization.
- Parameters
-
login | user's login |
password | user's password |
- Todo:
- fix typo autorisation -> authorization
void Control::change_room |
( |
int |
new_room_id | ) |
|
|
inlineslot |
Change chat room to another one.
- Parameters
-
new_room_id | room where user is switching |
void Control::connect_to_server |
( |
const std::string & |
login, |
|
|
const std::string & |
password, |
|
|
TypeCommand |
command |
|
) |
| |
Start communication with server.
- Parameters
-
- Todo:
- fix noreturn
void Control::get_text_from_gui |
( |
const std::string & |
login, |
|
|
const std::string & |
text, |
|
|
int |
room_id |
|
) |
| |
|
inlineslot |
Send message.
- Parameters
-
login | sender's login |
text | message content |
room_id | sender's room |
void Control::registration |
( |
const std::string & |
login, |
|
|
const std::string & |
password |
|
) |
| |
|
inlineslot |
User registration.
- Parameters
-
login | user's login |
password | user's password |
- Todo:
- replace to async?
void Control::send_text_to_gui |
( |
const std::string & |
login, |
|
|
const std::string & |
text, |
|
|
DateTime |
dt |
|
) |
| |
|
signal |
Show reveived message.
- Parameters
-
login | message sender's login |
text | message content |
dt | date and time of sending the text |
void Control::text_from_client |
( |
const std::string & |
from, |
|
|
const std::string & |
text, |
|
|
DateTime |
dt |
|
) |
| |
|
inlineslot |
Notify UI about received message.
- Parameters
-
from | sender's login |
text | message content |
dt | date and time of sending the text |
The documentation for this class was generated from the following files:
- src/client/control/control.h
- src/client/control/control.cpp