mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-22 01:11:42 +00:00
Passes the ConnectionInfo of the Rpc client on server callback (#112)
This commit is contained in:
committed by
Peter Johnson
parent
c5c069743b
commit
7e9754acff
@@ -79,6 +79,7 @@ struct RpcDefinition {
|
||||
struct RpcCallInfo {
|
||||
unsigned int rpc_id;
|
||||
unsigned int call_uid;
|
||||
ConnectionInfo conn_info;
|
||||
std::string name;
|
||||
std::string params;
|
||||
};
|
||||
@@ -224,7 +225,8 @@ constexpr double kTimeout_Indefinite = -1;
|
||||
void SetRpcServerOnStart(std::function<void()> on_start);
|
||||
void SetRpcServerOnExit(std::function<void()> on_exit);
|
||||
|
||||
typedef std::function<std::string(StringRef name, StringRef params)>
|
||||
typedef std::function<std::string(StringRef name, StringRef params,
|
||||
const ConnectionInfo& conn_info)>
|
||||
RpcCallback;
|
||||
|
||||
void CreateRpc(StringRef name, StringRef def, RpcCallback callback);
|
||||
|
||||
Reference in New Issue
Block a user