LeviLamina
Loading...
Searching...
No Matches
WorkerPool.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/container/MovePriorityQueue.h"
7#include "mc/deps/core/threading/BackgroundTaskBase.h"
8#include "mc/deps/core/utility/EnableNonOwnerReferences.h"
9#include "mc/platform/brstd/flat_set.h"
10
11// auto generated forward declare list
12// clang-format off
14// clang-format on
15
16class WorkerPool : public ::Bedrock::EnableNonOwnerReferences {
17public:
18 // member variables
19 // NOLINTBEGIN
33 // NOLINTEND
34
35public:
36 // prevent constructor by default
37 WorkerPool& operator=(WorkerPool const&);
38 WorkerPool(WorkerPool const&);
39 WorkerPool();
40
41public:
42 // virtual functions
43 // NOLINTBEGIN
44 virtual ~WorkerPool() /*override*/ = default;
45 // NOLINTEND
46
47public:
48 // member functions
49 // NOLINTBEGIN
50#ifdef LL_PLAT_C
51 MCNAPI ::std::vector<::std::thread::id> getThreadIds() const;
52
53 MCNAPI void kick(uint64 count);
54#endif
55
56 MCNAPI void queue(::std::shared_ptr<::BackgroundTaskBase> task, bool queueImmediate);
57 // NOLINTEND
58
59public:
60 // static functions
61 // NOLINTBEGIN
62 MCNAPI static void _registerPool(::WorkerPool& pool);
63 // NOLINTEND
64
65public:
66 // static variables
67 // NOLINTBEGIN
68 MCNAPI static ::brstd::flat_set<::WorkerPool*, ::std::less<::WorkerPool*>, ::std::vector<::WorkerPool*>>&
70
71 MCNAPI static ::std::mutex& sAllPoolsMutex();
72 // NOLINTEND
73};
Definition BackgroundTaskBase.h:18
Definition EnableNonOwnerReferences.h:7
MCAPI void queue(::std::shared_ptr<::BackgroundTaskBase > task, bool queueImmediate)
static MCAPI ::std::mutex & sAllPoolsMutex()
static MCAPI ::brstd::flat_set<::WorkerPool *, ::std::less<::WorkerPool * >, ::std::vector<::WorkerPool * > > & sAllPools()
static MCAPI void _registerPool(::WorkerPool &pool)
Definition Alias.h:14