#pragma once #include #include #include #include #include #include namespace llo { /// /// lloiff class which contains all of the information for representing a file format in a IL format... /// class lloiff_t { public: /// /// iff section struct containing IL information about a section... /// struct iff_section_t { /// /// section name, hashed so that there can be multiple... /// llo::utils::hash_t< std::string > section_name; /// /// opaque value, lifted from the original file format... /// this is should only be used by code that understands what the underlying file /// format was... /// std::uint64_t characteristics; /// /// vector of symbols for this section... /// std::vector< std::shared_ptr< llo::symbol::symbol_base_t > > symbols; /// /// vector of raw bytes containing the original bytes of this section... /// std::vector< std::uint8_t > raw; }; /// /// explicit constructor, must pass a name and the original file as a vector of bytes... /// /// name for this iff object... /// vector of raw bytes containing the original file... explicit lloiff_t( const std::string &name, const std::vector< std::uint8_t > &raw ) : name( name ), raw( raw ) { } /// /// entry point, where code execution begins.... /// this is lifted from the underlying file format... /// std::shared_ptr< disposition_t > entry; /// /// name of the iff file, hashed so there can be unique objects... /// llo::utils::hash_t< std::string > name; /// /// vector of iff sections... /// std::vector< iff_section_t > sections; /// /// vector of bytes containing the entire original file... /// std::vector< std::uint8_t > raw; }; } // namespace llo