mirror of
https://github.com/PabloMK7/citra.git
synced 2025-10-11 12:00:03 +00:00
core, web_service: Changes to announce service
Separated registering and updating to correspond to the new announce API endpoint. Also added a verify_UID for JWT audience verification.
This commit is contained in:
parent
1a8841f96e
commit
ab335ccf1b
5 changed files with 135 additions and 49 deletions
|
@ -20,15 +20,16 @@ public:
|
|||
RoomJson(const std::string& host, const std::string& username, const std::string& token)
|
||||
: client(host, username, token), host(host), username(username), token(token) {}
|
||||
~RoomJson() = default;
|
||||
void SetRoomInformation(const std::string& uid, const std::string& name,
|
||||
const std::string& description, const u16 port, const u32 max_player,
|
||||
const u32 net_version, const bool has_password,
|
||||
void SetRoomInformation(const std::string& name, const std::string& description, const u16 port,
|
||||
const u32 max_player, const u32 net_version, const bool has_password,
|
||||
const std::string& preferred_game,
|
||||
const u64 preferred_game_id) override;
|
||||
void AddPlayer(const std::string& nickname,
|
||||
void AddPlayer(const std::string& username, const std::string& nickname,
|
||||
const std::string& avatar_url,
|
||||
const AnnounceMultiplayerRoom::MacAddress& mac_address, const u64 game_id,
|
||||
const std::string& game_name) override;
|
||||
Common::WebResult Announce() override;
|
||||
Common::WebResult Update() override;
|
||||
std::string Register() override;
|
||||
void ClearPlayers() override;
|
||||
AnnounceMultiplayerRoom::RoomList GetRoomList() override;
|
||||
void Delete() override;
|
||||
|
@ -39,6 +40,7 @@ private:
|
|||
std::string host;
|
||||
std::string username;
|
||||
std::string token;
|
||||
std::string room_id;
|
||||
};
|
||||
|
||||
} // namespace WebService
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue