#pragma once #include #include "helpers.hpp" #include "memory.hpp" #include "services/apt.hpp" #include "services/hid.hpp" #include "services/fs.hpp" class ServiceManager { std::array& regs; Memory& mem; APTService apt; HIDService hid; FSService fs; // "srv:" commands void getServiceHandle(u32 messagePointer); void registerClient(u32 messagePointer); public: ServiceManager(std::array& regs, Memory& mem); void reset(); void handleSyncRequest(u32 messagePointer); // Forward a SendSyncRequest IPC message to the service with the respective handle void sendCommandToService(u32 messagePointer, Handle handle); };