RetroLinker
Linker for several 8-bit, 16-bit and 32-bit formats
|
Base class representing OMF record types. More...
#include <omf.h>
Public Member Functions | |
Record (uint8_t record_type=0) | |
virtual void | ReadRecordContents (OMFFormat *omf, Linker::Reader &rd)=0 |
Reads the record contents, except for the type, length and checksum. | |
virtual uint16_t | GetRecordSize (OMFFormat *omf) const =0 |
Calculates the required bytes to write the record, might be less than record_length. | |
virtual void | WriteRecordContents (OMFFormat *omf, ChecksumWriter &wr) const =0 |
Writes the record contents, except for the type, length and checksum. | |
virtual void | WriteRecord (OMFFormat *omf, Linker::Writer &wr) const |
Writes the full record. | |
Base class representing OMF record types.
Any record type is expected to extend this class. If several record types have the same or similar layout, they can share the same class, since the record type can be determined using the record_type field.
|
pure virtual |
Calculates the required bytes to write the record, might be less than record_length.
Implemented in OMF::OMFFormat::UnknownRecord, OMF::OMF86Format::Record, OMF::OMF86Format::EmptyRecord, OMF::OMF86Format::ModuleHeaderRecord, OMF::OMF86Format::RModuleHeaderRecord, OMF::OMF86Format::ListOfNamesRecord, OMF::OMF86Format::SegmentDefinitionRecord, OMF::OMF86Format::GroupDefinitionRecord, OMF::OMF86Format::TypeDefinitionRecord, OMF::OMF86Format::SymbolsDefinitionRecord, OMF::OMF86Format::ExternalNamesDefinitionRecord, OMF::OMF86Format::LineNumbersRecord, OMF::OMF86Format::BlockDefinitionRecord, OMF::OMF86Format::DebugSymbolsRecord, OMF::OMF86Format::RelocatableDataRecord, OMF::OMF86Format::PhysicalDataRecord, OMF::OMF86Format::LogicalDataRecord, OMF::OMF86Format::FixupRecord, OMF::OMF86Format::OverlayDefinitionRecord, OMF::OMF86Format::EndRecord, OMF::OMF86Format::RegisterInitializationRecord, OMF::OMF86Format::ModuleEndRecord, OMF::OMF86Format::IntelLibraryHeaderRecord, OMF::OMF86Format::IntelLibraryModuleNamesRecord, OMF::OMF86Format::IntelLibraryModuleLocationsRecord, OMF::OMF86Format::IntelLibraryDictionaryRecord, OMF::OMF86Format::BackpatchRecord, OMF::OMF86Format::NamedBackpatchRecord, OMF::OMF86Format::InitializedCommunalDataRecord, OMF::OMF86Format::SymbolLineNumbersRecord, OMF::OMF86Format::AliasDefinitionRecord, OMF::OMF86Format::OMFVersionNumberRecord, OMF::OMF86Format::VendorExtensionRecord, OMF::OMF86Format::CommentRecord, OMF::OMF86Format::LibraryHeaderRecord, and OMF::OMF86Format::LibraryEndRecord.
|
pure virtual |
Reads the record contents, except for the type, length and checksum.
Implemented in OMF::OMFFormat::UnknownRecord, OMF::OMF86Format::Record, OMF::OMF86Format::EmptyRecord, OMF::OMF86Format::ModuleHeaderRecord, OMF::OMF86Format::RModuleHeaderRecord, OMF::OMF86Format::ListOfNamesRecord, OMF::OMF86Format::SegmentDefinitionRecord, OMF::OMF86Format::GroupDefinitionRecord, OMF::OMF86Format::TypeDefinitionRecord, OMF::OMF86Format::SymbolsDefinitionRecord, OMF::OMF86Format::ExternalNamesDefinitionRecord, OMF::OMF86Format::LineNumbersRecord, OMF::OMF86Format::BlockDefinitionRecord, OMF::OMF86Format::DebugSymbolsRecord, OMF::OMF86Format::RelocatableDataRecord, OMF::OMF86Format::PhysicalDataRecord, OMF::OMF86Format::LogicalDataRecord, OMF::OMF86Format::FixupRecord, OMF::OMF86Format::OverlayDefinitionRecord, OMF::OMF86Format::EndRecord, OMF::OMF86Format::RegisterInitializationRecord, OMF::OMF86Format::ModuleEndRecord, OMF::OMF86Format::IntelLibraryHeaderRecord, OMF::OMF86Format::IntelLibraryModuleNamesRecord, OMF::OMF86Format::IntelLibraryModuleLocationsRecord, OMF::OMF86Format::IntelLibraryDictionaryRecord, OMF::OMF86Format::BackpatchRecord, OMF::OMF86Format::NamedBackpatchRecord, OMF::OMF86Format::InitializedCommunalDataRecord, OMF::OMF86Format::SymbolLineNumbersRecord, OMF::OMF86Format::AliasDefinitionRecord, OMF::OMF86Format::OMFVersionNumberRecord, OMF::OMF86Format::VendorExtensionRecord, OMF::OMF86Format::CommentRecord, OMF::OMF86Format::LibraryHeaderRecord, and OMF::OMF86Format::LibraryEndRecord.
|
virtual |
Writes the full record.
Reimplemented in OMF::OMF86Format::LibraryHeaderRecord, and OMF::OMF86Format::LibraryEndRecord.
|
pure virtual |
Writes the record contents, except for the type, length and checksum.
Implemented in OMF::OMFFormat::UnknownRecord, OMF::OMF86Format::Record, OMF::OMF86Format::EmptyRecord, OMF::OMF86Format::ModuleHeaderRecord, OMF::OMF86Format::RModuleHeaderRecord, OMF::OMF86Format::ListOfNamesRecord, OMF::OMF86Format::SegmentDefinitionRecord, OMF::OMF86Format::GroupDefinitionRecord, OMF::OMF86Format::TypeDefinitionRecord, OMF::OMF86Format::SymbolsDefinitionRecord, OMF::OMF86Format::ExternalNamesDefinitionRecord, OMF::OMF86Format::LineNumbersRecord, OMF::OMF86Format::BlockDefinitionRecord, OMF::OMF86Format::DebugSymbolsRecord, OMF::OMF86Format::RelocatableDataRecord, OMF::OMF86Format::PhysicalDataRecord, OMF::OMF86Format::LogicalDataRecord, OMF::OMF86Format::FixupRecord, OMF::OMF86Format::OverlayDefinitionRecord, OMF::OMF86Format::EndRecord, OMF::OMF86Format::RegisterInitializationRecord, OMF::OMF86Format::ModuleEndRecord, OMF::OMF86Format::IntelLibraryHeaderRecord, OMF::OMF86Format::IntelLibraryModuleNamesRecord, OMF::OMF86Format::IntelLibraryModuleLocationsRecord, OMF::OMF86Format::IntelLibraryDictionaryRecord, OMF::OMF86Format::BackpatchRecord, OMF::OMF86Format::NamedBackpatchRecord, OMF::OMF86Format::InitializedCommunalDataRecord, OMF::OMF86Format::SymbolLineNumbersRecord, OMF::OMF86Format::AliasDefinitionRecord, OMF::OMF86Format::OMFVersionNumberRecord, OMF::OMF86Format::VendorExtensionRecord, OMF::OMF86Format::CommentRecord, OMF::OMF86Format::LibraryHeaderRecord, and OMF::OMF86Format::LibraryEndRecord.