Go to the documentation of this file.
111 sectionWriter->
finalize(stream, sect);
136 "SectionWriter::findSectionWriter");
160 (*prototypes_)[key] = sWriter;
179 if (counter == 0) counter++;
HalfWord SectionId
Type for storing binary file section ids.
static void writeData(BinaryStream &stream, const Section *sect, const BinaryWriter *writer)
virtual void actualWriteData(BinaryStream &stream, const Section *sect) const =0
Does actual writing of sections data.
virtual void finalize(BinaryStream &stream, Section *section) const
virtual Section::SectionType type() const =0
Returns SectionType that actual reader or writer instance can handle.
virtual SectionType type() const =0
Returns SectioType of actual section instance.
Section * section(Word index) const
Word sectionCount() const
virtual void actualWriteHeader(BinaryStream &stream, const Section *sect) const =0
Does actual writing of sections header.
#define assert(condition)
static void registerSectionWriter(const SectionWriter *sWriter)
static void writeHeader(BinaryStream &stream, const Section *sect, const BinaryWriter *writer)
static const SectionWriter * findSectionWriter(const Section::SectionType type, const BinaryWriter *bWriter)
std::pair< const Section::SectionType, const BinaryWriter * > MapKey
Key type for finding values in map of section writers.
virtual const BinaryWriter & parent() const =0
Gets parent of instance which for SectionWriter is created.
static void finalizeBinary(BinaryStream &stream, const Binary *binaryToFinalize, const BinaryWriter *writer)
static MapType * prototypes_
Contains section writers for all kinds of sections and all kinds of binrary fromats that are supporte...
static SectionId getUniqueSectionId()
std::map< MapKey, const SectionWriter * > MapType
Map type that contains instances of registered section writers.