MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / IsFinalized

Method IsFinalized

lib/mdflib/mdflib/src/idblock.cpp:175–195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174
175void IdBlock::IsFinalized(bool finalized, std::streambuf& buffer,
176 uint16_t standard_flags, uint16_t custom_flags) {
177 if (finalized) {
178 file_identifier_ = "MDF ";
179 standard_flags_ = 0;
180 custom_flags_ = 0;
181 } else {
182 file_identifier_ = "UnFinMF ";
183 standard_flags_ = standard_flags;
184 custom_flags_ = custom_flags;
185 }
186
187 // Check if the file also needs update
188 if (FilePosition() == 0) {
189 SetFirstFilePosition(buffer);
190 WriteStr(buffer, file_identifier_, 8);
191 SetFilePosition(buffer, 60);
192 WriteNumber(buffer, standard_flags_);
193 WriteNumber(buffer, custom_flags_);
194 }
195}
196
197bool IdBlock::IsFinalized(uint16_t &standard_flags,
198 uint16_t &custom_flags) const {

Callers 4

TEST_FFunction · 0.45
TEST_FFunction · 0.45
getMethod · 0.45
EXPORTFEATUREFUNCFunction · 0.45

Calls 4

SetFirstFilePositionFunction · 0.85
WriteStrFunction · 0.85
SetFilePositionFunction · 0.85
emptyMethod · 0.80

Tested by 2

TEST_FFunction · 0.36
TEST_FFunction · 0.36