diff options
author | Your Name <you@example.com> | 2024-03-28 16:18:36 -0400 |
---|---|---|
committer | Your Name <you@example.com> | 2024-03-28 16:18:36 -0400 |
commit | c644379e79262a7478a7fb9ea8001f315fdb6eaf (patch) | |
tree | d71b15e396ebca28b76f0b5fd1971dd352877e4e /src/vm.h | |
download | nerdhack-master.tar.gz nerdhack-master.tar.bz2 nerdhack-master.zip |
Diffstat (limited to 'src/vm.h')
-rw-r--r-- | src/vm.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/vm.h b/src/vm.h new file mode 100644 index 0000000..a959511 --- /dev/null +++ b/src/vm.h @@ -0,0 +1,25 @@ +#pragma once +#include <libvirt/libvirt.h> +#include <memory> +#include <functional> + +namespace vm { + struct vmImpl; + + void clearAllVMs(); + + class VM { + public: + VM(); + ~VM(); + + int start(std::string config); + void stop(); + + void connect(std::function<int(const char*,size_t)> receiver, std::function<int(char*,size_t)> sender); + + private: + std::shared_ptr<vmImpl> data; + }; + +} |