summaryrefslogtreecommitdiffhomepage
path: root/Public/Kits/SystemKit/FileAPI.hxx
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-01-31 09:42:54 +0100
committerAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-01-31 09:42:54 +0100
commitfc55f0d69d24fb4908cbd811681f2c3fac53614d (patch)
treeba09a2cdbb225df7ba1a9ec5a12bcbb90b673ead /Public/Kits/SystemKit/FileAPI.hxx
parent7bed9287589293bd9d712d152539591dee0b28c0 (diff)
kernel: add GKit, improve AMD64 HAL.
Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'Public/Kits/SystemKit/FileAPI.hxx')
-rw-r--r--Public/Kits/SystemKit/FileAPI.hxx40
1 files changed, 40 insertions, 0 deletions
diff --git a/Public/Kits/SystemKit/FileAPI.hxx b/Public/Kits/SystemKit/FileAPI.hxx
new file mode 100644
index 00000000..c55d26ff
--- /dev/null
+++ b/Public/Kits/SystemKit/FileAPI.hxx
@@ -0,0 +1,40 @@
+/*
+ * ========================================================
+ *
+ * h-core
+ * Copyright Mahrouss Logic, all rights reserved.
+ *
+ * ========================================================
+ */
+
+#ifndef _SYSTEM_KIT_HCORE_FILE_HPP
+#define _SYSTEM_KIT_HCORE_FILE_HPP
+
+#include <CompilerKit/CompilerKit.hpp>
+#include <NewKit/Defines.hpp>
+
+using namespace HCore;
+
+class HFile final {
+ public:
+ explicit HFile(const char *path);
+ ~HFile();
+
+ public:
+ HCORE_COPY_DEFAULT(HFile);
+
+ public:
+ void *Read(SizeT off, SizeT sz);
+ void Write(void *buf, SizeT off, SizeT sz);
+ void Seek(SizeT off);
+ void *Read(SizeT sz);
+ void Write(void *buf, SizeT sz);
+ void Rewind();
+
+ public:
+ void SetMIME(const char *mime);
+};
+
+typedef HFile *HFilePtr;
+
+#endif // ifndef _SYSTEM_KIT_HCORE_FILE_HPP