#ifndef IOMAN_H #define IOMAN_H #include "netman.h" #include "cmdman.h" #include "fileman.h" #include #define BLOCKSIZE 8 class IoMan { private: const std::string protoVersion = "0.2"; protected: NetMan netman; CmdMan cmdman; FileMan fileman; bool loggedin; std::string promptcmd = ""; std::string promptuser = ""; std::string promptpass = ""; virtual bool parseJson(Json::Value *root, string jsonstring) = 0; virtual bool handleJson(Json::Value root) = 0; virtual void printErrorMessage(std::string msg) = 0; virtual void printWelcomeMessage() = 0; public: // Basic constructor IoMan(char *ipcstring); // destructor to clean up all generic stuff ~IoMan(); // enters loop to handle further interaction based on derived class void run(); // setup stuff bool init(); }; #endif