LeviLamina
Loading...
Searching...
No Matches
TreatmentCodenameManager.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/pub_sub/Publisher.h"
7#include "mc/deps/core/utility/pub_sub/Subscription.h"
8
9// auto generated forward declare list
10// clang-format off
11struct FlightingService;
12struct RealmsAPI;
13namespace Bedrock::PubSub::ThreadModel { struct MultiThreaded; }
14// clang-format on
15
16class TreatmentCodenameManager : public ::std::enable_shared_from_this<::TreatmentCodenameManager> {
17public:
18 // member variables
19 // NOLINTBEGIN
20 ::ll::TypedStorage<8, 32, ::std::string> mCodenameString;
21 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mTreatmentsMonitorSubscription;
22 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mRealmsFeatureFlagsMonitorSubscription;
23 ::ll::TypedStorage<
24 8,
25 128,
26 ::Bedrock::PubSub::Publisher<void(::std::string_view), ::Bedrock::PubSub::ThreadModel::MultiThreaded, 0>>
27 mCodenameUpdatedPublisher;
28 ::ll::TypedStorage<1, 1, bool> mDisableLocalizationForTesting;
29 ::ll::TypedStorage<1, 1, bool> mShowActualTreatmentName;
30 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mRealmsFeatureFlags;
31 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mTreatments;
32 // NOLINTEND
33
34public:
35 // member functions
36 // NOLINTBEGIN
37 MCAPI void _generateCodenames(
38 ::std::vector<::std::string> const& treatments,
39 ::std::vector<::std::string>& codenamesInUse,
40 ::std::stringstream& inoutStream
41 );
42
43 MCAPI void generateNewCodenames(
44 ::std::vector<::std::string> const& realmFeatures,
45 ::std::vector<::std::string> const& treatments
46 );
47
48 MCAPI ::Bedrock::PubSub::Subscription
49 registerCodenameUpdatedListener(::std::function<void(::std::string_view)> callback);
50
51 MCAPI void registerRealmsFeatureNamesListener(::RealmsAPI& realmsAPI);
52
53 MCAPI void registerTreatmentsListener(::std::weak_ptr<::FlightingService> flightingService);
54 // NOLINTEND
55};
Definition TreatmentCodenameManager.h:5
Definition FlightingService.h:5
Definition RealmsAPI.h:5