Audacity
3.2.0
libraries
lib-cloud-audiocom
sync
CloudSyncError.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-or-later */
2
/*!********************************************************************
3
4
Audacity: A Digital Audio Editor
5
6
CloudSyncError.h
7
8
Dmitry Vedenko
9
10
**********************************************************************/
11
#pragma once
12
13
#include <string>
14
15
#include "
NetworkUtils.h
"
16
17
class
TranslatableString
;
18
19
namespace
audacity::network_manager
20
{
21
class
IResponse;
22
}
// namespace audacity::network_manager
23
24
namespace
audacity::cloud::audiocom::sync
25
{
26
struct
CLOUD_AUDIOCOM_API
CloudSyncError
final
27
{
28
enum
ErrorType
29
{
30
None
,
31
Authorization
,
32
ProjectLimitReached
,
33
ProjectStorageLimitReached
,
34
ProjectVersionConflict
,
35
ProjectNotFound
,
36
DataUploadFailed
,
37
Network
,
38
Server
,
39
Cancelled
,
40
Aborted
,
41
ClientFailure
,
42
};
43
44
ErrorType
Type { };
45
std::string
ErrorMessage
;
46
};
47
48
CLOUD_AUDIOCOM_API
49
CloudSyncError
DeduceUploadError
(
audacity::network_manager::IResponse
& response);
50
51
CLOUD_AUDIOCOM_API
52
CloudSyncError
MakeClientFailure
(
const
TranslatableString
& message);
53
54
CLOUD_AUDIOCOM_API
55
CloudSyncError
MakeClientFailure
(
const
std::string& message);
56
57
CLOUD_AUDIOCOM_API
58
CloudSyncError
MakeClientFailure
(
const
char
* message);
59
60
CLOUD_AUDIOCOM_API
CloudSyncError::ErrorType
61
DeduceError
(
SyncResultCode
code);
62
63
}
// namespace audacity::cloud::audiocom::sync
NetworkUtils.h
TranslatableString
Holds a msgid for the translation catalog; may also bind format arguments.
Definition:
TranslatableString.h:32
audacity::network_manager::IResponse
Interface, that provides access to the data from the HTTP response.
Definition:
IResponse.h:113
audacity::cloud::audiocom::sync
Definition:
CloudSyncService.h:31
audacity::cloud::audiocom::sync::DeduceError
CloudSyncError::ErrorType DeduceError(SyncResultCode code)
Definition:
CloudSyncError.cpp:88
audacity::cloud::audiocom::sync::MakeClientFailure
CloudSyncError MakeClientFailure(const TranslatableString &message)
Definition:
CloudSyncError.cpp:72
audacity::cloud::audiocom::sync::DeduceUploadError
CLOUD_AUDIOCOM_API CloudSyncError DeduceUploadError(audacity::network_manager::IResponse &response)
Definition:
CloudSyncError.cpp:23
audacity::cloud::audiocom::SyncResultCode
SyncResultCode
Definition:
NetworkUtils.h:43
audacity::network_manager
Definition:
NetworkUtils.h:18
audacity::cloud::audiocom::sync::CloudSyncError
Definition:
CloudSyncError.h:27
audacity::cloud::audiocom::sync::CloudSyncError::ErrorMessage
std::string ErrorMessage
Definition:
CloudSyncError.h:45
audacity::cloud::audiocom::sync::CloudSyncError::ErrorType
ErrorType
Definition:
CloudSyncError.h:29
audacity::cloud::audiocom::sync::CloudSyncError::ClientFailure
@ ClientFailure
Definition:
CloudSyncError.h:41
audacity::cloud::audiocom::sync::CloudSyncError::Server
@ Server
Definition:
CloudSyncError.h:38
audacity::cloud::audiocom::sync::CloudSyncError::Network
@ Network
Definition:
CloudSyncError.h:37
audacity::cloud::audiocom::sync::CloudSyncError::ProjectLimitReached
@ ProjectLimitReached
Definition:
CloudSyncError.h:32
audacity::cloud::audiocom::sync::CloudSyncError::Aborted
@ Aborted
Definition:
CloudSyncError.h:40
audacity::cloud::audiocom::sync::CloudSyncError::None
@ None
Definition:
CloudSyncError.h:30
audacity::cloud::audiocom::sync::CloudSyncError::Authorization
@ Authorization
Definition:
CloudSyncError.h:31
audacity::cloud::audiocom::sync::CloudSyncError::ProjectVersionConflict
@ ProjectVersionConflict
Definition:
CloudSyncError.h:34
audacity::cloud::audiocom::sync::CloudSyncError::DataUploadFailed
@ DataUploadFailed
Definition:
CloudSyncError.h:36
audacity::cloud::audiocom::sync::CloudSyncError::ProjectNotFound
@ ProjectNotFound
Definition:
CloudSyncError.h:35
audacity::cloud::audiocom::sync::CloudSyncError::ProjectStorageLimitReached
@ ProjectStorageLimitReached
Definition:
CloudSyncError.h:33
audacity::cloud::audiocom::sync::CloudSyncError::Cancelled
@ Cancelled
Definition:
CloudSyncError.h:39
Generated by
1.9.3