#ifndef OUTFILE_H #define OUTFILE_H #include #include #include #include #include namespace OutFile { struct Header { unsigned short machinetype; unsigned short sectioncount; unsigned long time; unsigned long symbolptr; unsigned long symbolcount; unsigned short opthead; unsigned short flags; void PrintData() { std::cout<<"Symbol start:"< vSymbol; class File { public: File(std::string path); virtual ~File(); void GetText(char *ptr); size_t GetTextSize(); void LoadSymbols(); vSymbol GetSymbols(){LoadSymbols();return symbols;}; void PrintSymbols(); void PrintRelocations(); protected: private: typedef std::map secMap; secMap sections; vSymbol symbols; Section &GetSection(std::string name); std::fstream mystream; Header myhead; // Section Text; //Section Data; // Section Bss; }; } #endif // OUTFILE_H