12 #define ARPCM_ERROR 0x0
13 #define ARPCM_CALL 0x10
14 #define ARPCM_ECALL 0x11
15 #define ARPCM_RESULT 0x20
16 #define ARPCM_ERESULT 0x21
17 #define ARPCM_LOCAL_REQ 0x30
18 #define ARPCM_LOCAL_RES 0x31
19 #define ARPCM_BROAD_MSG 0x40
20 #define ARPCM_BROAD_RES 0x41
25 #define ALDRPCSERVICE "aldd"
29 #define ALDRPCMAGIC "ALDRPC01"
33 #define ALDRPCVERSION 100
65 #define ALD_RPC_ITF_NAME "ald-rpc"
93 inline bool good()
const {
return alrsOK == status;}
99 inline void addArg(
const string &arg,
const string &val){args.insert(make_pair(arg, val));}
105 inline void addRes(
const string &res,
const string &val){result.insert(make_pair(res, val));}
108 inline void setError(
const string &err){error = err;status = alrsERR;}
112 ald_string_multimap::const_iterator it = args.find(key);
121 ald_string_multimap::const_iterator it = result.find(key);
122 if(it != result.end())
130 ald_string_multimap::const_iterator it = args.find(key);
131 return (it != args.end());
136 ald_string_multimap::const_iterator it = result.find(key);
137 return (it != result.end());
141 inline void clear(){args.clear(); result.clear();}
154 virtual int getTimeout()
const = 0;
156 virtual void setTimeout(
int timeout) = 0;
163 virtual bool Connect(
const string &server,
ALDAuthType at) = 0;
165 virtual bool IsConnected() = 0;
167 virtual void Disconnect() = 0;
string resByName(const string &key)
Definition: ald-rpc.h:120
list< string > ald_string_list
Список строк
Definition: ALDUtils.h:152
Объявление основного интерфейса клиента Astra Linux Directory и необходимых для него типов и интерфей...
IALDRpcWrapper(IALDCore &Core)
Definition: ald-rpc.h:189
shared_ptr< IALDRpcWrapper > CALDRpcWrapperPtr
Definition: ald-rpc.h:197
alRPCStatus status
Definition: ald-rpc.h:88
ald_rpc_header header
Definition: ald-rpc.h:80
#define ALD_RPC_ITF_NAME
Definition: ald-rpc.h:65
string argByName(const string &key)
Definition: ald-rpc.h:111
shared_ptr< IALDRpcConnection > CALDRpcConnPtr
Definition: ald-rpc.h:179
bool good() const
Definition: ald-rpc.h:93
void addRes(const string &res, const string &val)
Установка результата
Definition: ald-rpc.h:105
Абстрактный класс-интерфейс RPC соединения с сервером ALD.
Definition: ald-rpc.h:148
ald_string_multimap result
Definition: ald-rpc.h:86
Базовый класс интерфейса
Definition: ALDCore.h:83
void setError(const string &err)
Definition: ald-rpc.h:108
void clear()
Definition: ald-rpc.h:141
bool resExists(const string &key)
Definition: ald-rpc.h:135
const size_t ALDRPCHDRSIZE
Definition: ald-rpc.h:68
bool SendBroadcastMessage(IALDCore &Core, const string &msg, ald_string_list *responses=NULL, int timeout=3)
Отправка широковещательного сообщения
Структура RPC запроса
Definition: ald-rpc.h:78
multimap< string, string > ald_string_multimap
MultiMAP строка => строка
Definition: ALDUtils.h:166
string name
Definition: ald-rpc.h:82
Абстрактный класс-интерфейс RPC взаимодействия с сервером
Definition: ald-rpc.h:185
Основной заголовочный файл, содержащий необходимый минимум предварительных объявлений и включений дру...
alRPCStatus
Definition: ald-rpc.h:71
Конфигурационные определения для подсистемы локализации Gettext.
ald_string_multimap args
Definition: ald-rpc.h:84
void addArg(const string &arg, const string &val)
Установка аргумента
Definition: ald-rpc.h:99
virtual ~IALDRpcConnection()
Definition: ald-rpc.h:175
ALDAuthType
Набор способов аутентификации
Definition: ALDCore.h:28
Абстрактный класс IALDCore - основной интерфейс клиента Astra Linux Directory, с помощью которого вып...
Definition: ALDCore.h:241
bool argExists(const string &key)
Definition: ald-rpc.h:129
string error
Definition: ald-rpc.h:90