LeviLamina
Loading...
Searching...
No Matches
CrashManager.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/EnableNonOwnerReferences.h"
7
8// auto generated forward declare list
9// clang-format off
10class Scheduler;
11namespace Bedrock { class CrashFileProcessor; }
12namespace Bedrock { class CrashTelemetryProcessor; }
13namespace Bedrock { class WorkerPoolHandleInterface; }
14namespace Bedrock { struct CrashManagerConfig; }
15// clang-format on
16
17namespace Bedrock {
18
19class CrashManager : public ::Bedrock::EnableNonOwnerReferences, public ::Bedrock::ImplBase<::Bedrock::CrashManager> {
20public:
21 // virtual functions
22 // NOLINTBEGIN
23 virtual void initialize(::Bedrock::CrashManagerConfig const& config) = 0;
24
25 virtual void setCrashProcessorForFileType(
26 ::std::string_view fileExtension,
27 ::std::shared_ptr<::Bedrock::CrashFileProcessor> processor
28 ) = 0;
29
30 virtual void setCrashTelemetryProcessor(::gsl::not_null<::Bedrock::CrashTelemetryProcessor*> processor) = 0;
31
32 virtual void processCrashes(
33 ::std::shared_ptr<::Bedrock::WorkerPoolHandleInterface> workerPool,
34 ::Scheduler& scheduler,
35 bool isNetworkAvailable
36 ) = 0;
37
38 virtual void notifyCrashed() = 0;
39
40 virtual void notifySystemError(uint errorCode, ::std::string const& errorMessage) = 0;
41
42 virtual void
43 recordCrashedSession(::std::string_view sessionId, ::std::string_view serializedSession, int64 crashTime) = 0;
44
45 virtual void stopProcessingCrashes() = 0;
46
47 virtual bool isCrashProcessingActive() const = 0;
48
49 virtual ::std::string const& getCrashDataRoot() const = 0;
50
51 virtual ::std::string const& getCrashedSessionFileSuffix() const = 0;
52
53#ifdef LL_PLAT_S
54 virtual ~CrashManager() /*override*/ = default;
55#else // LL_PLAT_C
56 virtual ~CrashManager() /*override*/;
57#endif
58
59 // NOLINTEND
60
61public:
62 // static variables
63 // NOLINTBEGIN
64 MCNAPI static ::std::add_lvalue_reference_t<char const[]> DEFAULT_CRASH_DIRECTORY_NAME();
65 // NOLINTEND
66
67public:
68 // destructor thunk
69 // NOLINTBEGIN
70 MCNAPI void $dtor();
71 // NOLINTEND
72
73public:
74 // virtual function thunks
75 // NOLINTBEGIN
76
77 // NOLINTEND
78};
79
80} // namespace Bedrock
Definition CrashFileProcessor.h:18
Definition CrashManager.h:19
static MCAPI ::std::add_lvalue_reference_t< char const[]> DEFAULT_CRASH_DIRECTORY_NAME()
Definition CrashTelemetryProcessor.h:13
Definition EnableNonOwnerReferences.h:7
Definition _HeaderOutputPredefine.h:260
Definition WorkerPoolHandleInterface.h:15
Definition Scheduler.h:14
Definition CrashManagerConfig.h:7