ScummVM API documentation
scummvmcloud.h
1
/* ScummVM - Graphic Adventure Engine
2
*
3
* ScummVM is the legal property of its developers, whose names
4
* are too numerous to list here. Please refer to the COPYRIGHT
5
* file distributed with this source distribution.
6
*
7
* This program is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
*
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with this program. If not, see <http://www.gnu.org/licenses/>.
19
*
20
*/
21
22
#ifndef BACKENDS_DLC_SCUMMVMCLOUD_H
23
#define BACKENDS_DLC_SCUMMVMCLOUD_H
24
25
#include "common/queue.h"
26
27
#include "backends/dlc/store.h"
28
#include "backends/networking/curl/request.h"
29
#include "backends/networking/curl/curljsonrequest.h"
30
31
namespace
Networking
{
32
class
SessionRequest;
33
}
34
35
namespace
DLC
{
36
namespace
ScummVMCloud {
37
38
class
ScummVMCloud
:
public
DLC::Store
{
39
40
Networking::SessionRequest
*_rq;
41
42
public
:
43
ScummVMCloud
() {}
44
virtual
~
ScummVMCloud
() {}
45
46
virtual
void
getAllDLCs()
override
;
47
48
virtual
void
startDownloadAsync(
const
Common::String
&
id
,
const
Common::String
&url)
override
;
49
50
virtual
void
removeCacheFile(
const
Common::Path
&file)
override
;
51
52
// extracts the provided zip in the provided destination path
53
Common::Error
extractZip(
const
Common::Path
&file,
const
Common::Path
&destPath);
54
55
void
addEntryToConfig(
Common::Path
gamePath);
56
57
// callback functions
58
void
jsonCallbackGetAllDLCs(
const
Networking::JsonResponse
&response);
59
60
void
errorCallbackGetAllDLCs(
const
Networking::ErrorResponse
&
error
);
61
62
void
downloadFileCallback(
const
Networking::DataResponse
&response);
63
64
void
errorCallback(
const
Networking::ErrorResponse
&error);
65
};
66
67
}
// End of namespace ScummVMCloud
68
}
// End of namespace DLC
69
70
#endif
DLC::Store
Definition:
store.h:32
DLC
Definition:
system.h:51
Common::String
Definition:
str.h:59
Common::Error
Definition:
error.h:84
Networking
Definition:
scummvmcloud.h:31
Networking::ErrorResponse
Definition:
request.h:73
Common::Path
Definition:
path.h:52
Networking::Response
Definition:
request.h:47
DLC::ScummVMCloud::ScummVMCloud
Definition:
scummvmcloud.h:38
Networking::SessionRequest
Class for reading file and storing locally.
Definition:
sessionrequest.h:50
error
void NORETURN_PRE error(MSVC_PRINTF const char *s,...) GCC_PRINTF(1
backends
dlc
scummvmcloud.h
Generated on Fri Aug 30 2024 09:03:30 for ScummVM API documentation by
1.8.13