wut  v1.7.0
Wii U Toolchain
DrcManager.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <nn/result.h>
5 #include <nn/sl/ITimeAccessor.h>
6 #include <nn/sl/ITransferrer.h>
8 #include <nn/sl/sl_cpp.h>
9 #include <wut.h>
10 
11 #ifdef __cplusplus
12 
13 namespace nn::sl {
14 
15  namespace details {
16  typedef struct WUT_PACKED DrcManagerInternal {
20  void *vtable;
22  WUT_CHECK_SIZE(DrcManagerInternal, 0x10);
23  WUT_CHECK_OFFSET(DrcManagerInternal, 0x00, drcTransferrer);
24  WUT_CHECK_OFFSET(DrcManagerInternal, 0x04, settingsAccessor);
25  WUT_CHECK_OFFSET(DrcManagerInternal, 0x08, timeAccessor);
26  WUT_CHECK_OFFSET(DrcManagerInternal, 0x0C, vtable);
27 
32 
35  } // namespace details
36  class DrcManager {
37  public:
38  DrcManager() : mTransferrer(nullptr),
39  mSettingAccessor(nullptr),
40  mTimeAccessor(nullptr) {
41  if (__ct__Q3_2nn2sl10DrcManagerFv(&mInstance) != nullptr) {
42  mTransferrer = details::TransferrerFromPtr(mInstance.drcTransferrer);
43  mSettingAccessor = details::SettingAccessorFromPtr(mInstance.settingsAccessor);
44  mTimeAccessor = details::TimeAccessorFromPtr(mInstance.timeAccessor);
45  }
46  }
47 
48  ~DrcManager() = default;
49 
51  return mTransferrer;
52  }
53 
55  return mSettingAccessor;
56  }
57 
59  return mTimeAccessor;
60  }
61 
63  return CancelTransfer__Q3_2nn2sl10DrcManagerFv(&mInstance);
64  }
65 
66  nn::Result PushNotification(bool *u1, const KillerNotification *u2, bool u3, bool u4, uint64_t u5) {
68  }
69 
72  }
73 
76  &mInstance,
77  transferrer.GetInternal(),
78  settingAccessor.GetInternal(),
79  timeAccessor.GetInternal());
80  }
81 
82  private:
83  details::DrcManagerInternal mInstance = {};
84 
85  details::TransferrerFromPtr mTransferrer;
86  details::SettingAccessorFromPtr mSettingAccessor;
87  details::TimeAccessorFromPtr mTimeAccessor;
88  };
89 } // namespace nn::sl
90 
91 #endif
Result value type used by nn libraries.
Definition: result.h:68
details::ITimeAccessorBase & GetTimeAccessor()
Definition: DrcManager.h:58
~DrcManager()=default
details::ISettingAccessorBase & GetSettingAccessor()
Definition: DrcManager.h:54
nn::Result PushNotification(bool *u1, const KillerNotification *u2, bool u3, bool u4, uint64_t u5)
Definition: DrcManager.h:66
void Initialize(details::ITransferrerBase &transferrer, details::ISettingAccessorBase &settingAccessor, details::ITimeAccessorBase &timeAccessor)
Definition: DrcManager.h:74
details::ITransferrerBase & GetTransferrer()
Definition: DrcManager.h:50
nn::Result CancelTransfer()
Definition: DrcManager.h:62
nn::Result Transfer(TransferableInfo *u1, bool u2, TransferMode u3)
Definition: DrcManager.h:70
DrcManagerInternal * __ct__Q3_2nn2sl10DrcManagerFv(DrcManagerInternal *)
nn::Result Initialize__Q3_2nn2sl10DrcManagerFRQ3_2nn2sl12ITransferrerRQ3_2nn2sl16ISettingAccessorRQ3_2nn2sl13ITimeAccessor(DrcManagerInternal *, ITransferrerInternal *, ISettingAccessorInternal *, ITimeAccessorInternal *)
struct nn::sl::details::DrcManagerInternal DrcManagerInternal
ITransferrerInternal * drcTransferrer
Definition: DrcManager.h:17
nn::Result PushNotification__Q3_2nn2sl10DrcManagerFPbPCQ3_2nn2sl18KillerNotificationbT3L(DrcManagerInternal *, bool *, const KillerNotification *, bool, bool, uint64_t)
nn::Result Transfer__Q3_2nn2sl10DrcManagerFRCQ3_2nn2sl16TransferableInfobQ4_2nn2sl12ITransferrer12TransferMode(DrcManagerInternal *, TransferableInfo *, bool, TransferMode)
nn::Result CancelTransfer__Q3_2nn2sl10DrcManagerFv(DrcManagerInternal *)
ISettingAccessorInternal * settingsAccessor
Definition: DrcManager.h:18
ITimeAccessorInternal * timeAccessor
Definition: DrcManager.h:19
TransferMode
Definition: sl_cpp.h:245