diff options
| author | Amlal <amlalelmahrouss@icloud.com> | 2024-07-28 16:11:46 +0000 |
|---|---|---|
| committer | Amlal <amlalelmahrouss@icloud.com> | 2024-07-28 16:11:46 +0000 |
| commit | c4023005e029ae092dad2689564c490580dd5c28 (patch) | |
| tree | 3080ba07a6b552bf3d7591574cf69b2a3c8fd0fd /Boot/BootKit/ProgramLoader.hxx | |
| parent | 8c8822fff78f9ff9cd640271da9b3634c4c2f97f (diff) | |
| parent | 4db57a2d646b1538783a0675b38bada7a0f903ae (diff) | |
Merged in MHR-36 (pull request #17)
MHR-36
Diffstat (limited to 'Boot/BootKit/ProgramLoader.hxx')
| -rw-r--r-- | Boot/BootKit/ProgramLoader.hxx | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/Boot/BootKit/ProgramLoader.hxx b/Boot/BootKit/ProgramLoader.hxx new file mode 100644 index 00000000..90f8996f --- /dev/null +++ b/Boot/BootKit/ProgramLoader.hxx @@ -0,0 +1,42 @@ +/* ------------------------------------------- + + Copyright ZKA Technologies + +------------------------------------------- */ + +#pragma once + +#include <KernelKit/PE.hxx> +#include <KernelKit/MSDOS.hxx> +#include <FirmwareKit/Handover.hxx> + +namespace Boot +{ + using namespace Kernel; + + class ProgramLoader; + + /// @brief Program loader class + /// @package nl.zeta.boot.api + class ProgramLoader final + { + public: + explicit ProgramLoader() = delete; + ~ProgramLoader() = default; + + explicit ProgramLoader(Kernel::VoidPtr blob); + + ProgramLoader& operator=(const ProgramLoader&) = default; + ProgramLoader(const ProgramLoader&) = default; + + void Start(HEL::HandoverInformationHeader* handover); + const char* GetName(); + void SetName(const char* name); + + private: + Char fBlobName[255]; + Char* fStackPtr{nullptr}; + VoidPtr fStartAddress{nullptr}; + VoidPtr fBlob{nullptr}; + }; +} // namespace Boot |
