diff --git a/README.md b/README.md index aa1a37b..bdcdcb8 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,19 @@ # IACore (Independent Architecture Core) -![License](https://img.shields.io/badge/license-GPLv3-blue.svg) -![Standard](https://img.shields.io/badge/C%2B%2B-20-yellow.svg) -![Platform](https://img.shields.io/badge/platform-Windows%20%7C%20Linux-lightgrey.svg) +
+ IACore Logo +
+ + License + C++ Standard + Platform +

+ The Battery-Included Foundation for High-Performance C++ Applications. +

+
+ +## 📖 Description IACore is a high-performance, battery-included C++20 foundation library designed to eliminate "dependency hell." It bundles essential systems—IPC, Logging, Networking, Compression, and Async Scheduling—into a single, coherent API. Originally developed as the internal core for IASoft (PVT) LTD., it is now open-source to provide a standardized bedrock for C++ applications. @@ -35,17 +45,16 @@ target_link_libraries(MyApp PRIVATE IACore) ## 📦 Dependencies IACore manages its own dependencies via CMake's FetchContent. You do not need to install these manually: -* nlohmann_json & glaze (JSON Parsing) -* cpp-httplib (Networking) -* zlib-ng & zstd (Compression) -* tl-expected (Error Handling) +* **JSON:** `nlohmann_json`, `glaze`, & `simdjson` +* **Networking:** `cpp-httplib` +* **Compression:** `zlib-ng` & `zstd` +* **Utilities:** `tl-expected` & `unordered_dense` ## 💡 Usage Examples ### 1. IPC (Manager & Node) IACore provides a manager/node architecture using shared memory. -Manager: - +#### Manager: ```C++ #include @@ -58,6 +67,36 @@ String msg = "Hello Node"; manager.SendPacket(*nodeID, 100, {(PCUINT8)msg.data(), msg.size()}); ``` +#### Node: +```C++ +#include + +class Node : public IACore::IPC_Node { +public: + void OnSignal(uint8_t signal) override { + // Handle signals + } + + void OnPacket(uint16_t packetID, std::span payload) override { + // Handle packets + } +}; + +int main(int argc, char* argv[]) { + // The connection string is passed as the first argument by the Manager + if (argc < 2) return -1; + + Node node; + // Connect back to the manager via Shared Memory + if (!node.Connect(argv[1])) return -1; + + while(true) { + node.Update(); + } + return 0; +} +``` + ### 2. Async Jobs ```C++ @@ -81,7 +120,7 @@ IACore::AsyncOps::WaitForScheduleCompletion(mySchedule); ```C++ #include -IACore::HttpClient client("[https://api.example.com](https://api.example.com)"); +IACore::HttpClient client("https://api.example.com"); auto res = client.JsonGet("/data", {}); if (res) { diff --git a/logo.svg b/logo.svg new file mode 100644 index 0000000..9642a5e --- /dev/null +++ b/logo.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + IACore + + INDEPENDENT ARCHITECTURE + + \ No newline at end of file