mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-15 04:30:05 +00:00
Put WebResult into a seperate file
This commit is contained in:
parent
6fb6737642
commit
d28233961b
@ -90,6 +90,7 @@ add_library(common STATIC
|
|||||||
timer.cpp
|
timer.cpp
|
||||||
timer.h
|
timer.h
|
||||||
vector_math.h
|
vector_math.h
|
||||||
|
web_result.h
|
||||||
)
|
)
|
||||||
|
|
||||||
if(ARCHITECTURE_x86_64)
|
if(ARCHITECTURE_x86_64)
|
||||||
|
@ -9,23 +9,7 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include "common/common_types.h"
|
#include "common/common_types.h"
|
||||||
|
#include "common/web_result.h"
|
||||||
namespace Common {
|
|
||||||
struct WebResult {
|
|
||||||
enum class Code : u32 {
|
|
||||||
Success,
|
|
||||||
InvalidURL,
|
|
||||||
CredentialsMissing,
|
|
||||||
LibError,
|
|
||||||
HttpError,
|
|
||||||
WrongContent,
|
|
||||||
NoWebservice,
|
|
||||||
};
|
|
||||||
Code result_code;
|
|
||||||
std::string result_string;
|
|
||||||
std::string returned_data;
|
|
||||||
};
|
|
||||||
} // namespace Common
|
|
||||||
|
|
||||||
namespace AnnounceMultiplayerRoom {
|
namespace AnnounceMultiplayerRoom {
|
||||||
|
|
||||||
|
25
src/common/web_result.h
Normal file
25
src/common/web_result.h
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
// Copyright 2018 Citra Emulator Project
|
||||||
|
// Licensed under GPLv2 or any later version
|
||||||
|
// Refer to the license.txt file included.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
#include "common/common_types.h"
|
||||||
|
|
||||||
|
namespace Common {
|
||||||
|
struct WebResult {
|
||||||
|
enum class Code : u32 {
|
||||||
|
Success,
|
||||||
|
InvalidURL,
|
||||||
|
CredentialsMissing,
|
||||||
|
LibError,
|
||||||
|
HttpError,
|
||||||
|
WrongContent,
|
||||||
|
NoWebservice,
|
||||||
|
};
|
||||||
|
Code result_code;
|
||||||
|
std::string result_string;
|
||||||
|
std::string returned_data;
|
||||||
|
};
|
||||||
|
} // namespace Common
|
@ -2,14 +2,15 @@
|
|||||||
// Licensed under GPLv2 or any later version
|
// Licensed under GPLv2 or any later version
|
||||||
// Refer to the license.txt file included.
|
// Refer to the license.txt file included.
|
||||||
|
|
||||||
|
#include <array>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
#include <mutex>
|
#include <mutex>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <LUrlParser.h>
|
#include <LUrlParser.h>
|
||||||
#include <httplib.h>
|
#include <httplib.h>
|
||||||
#include "common/announce_multiplayer_room.h"
|
|
||||||
#include "common/common_types.h"
|
#include "common/common_types.h"
|
||||||
#include "common/logging/log.h"
|
#include "common/logging/log.h"
|
||||||
|
#include "common/web_result.h"
|
||||||
#include "web_service/web_backend.h"
|
#include "web_service/web_backend.h"
|
||||||
|
|
||||||
namespace WebService {
|
namespace WebService {
|
||||||
|
Loading…
Reference in New Issue
Block a user