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

Method setFinishSequences

app/src/IO/FrameReader.cpp:243–257  ·  view source on GitHub ↗

* @brief Configures the frame end delimiters and precomputes their KMP tables. */

Source from the content-addressed store, hash-verified

241 * @brief Configures the frame end delimiters and precomputes their KMP tables.
242 */
243void IO::FrameReader::setFinishSequences(const QList<QByteArray>& finishes)
244{
245 m_finishSequences.clear();
246 m_finishSequenceLps.clear();
247
248 for (const auto& f : finishes) {
249 if (f.isEmpty())
250 continue;
251
252 m_finishSequences.append(f);
253 m_finishSequenceLps.append(m_circularBuffer.buildKMPTable(f));
254 }
255
256 Q_ASSERT(m_finishSequences.size() == m_finishSequenceLps.size());
257}
258
259/**
260 * @brief Sets the operation mode and resets checksum state outside ProjectFile.

Callers 5

startFrameReaderMethod · 0.80
runDataPipelineMethod · 0.80
runMethod · 0.80
measureNativeStagesMethod · 0.80
configureAndFeedFunction · 0.80

Calls 5

isEmptyMethod · 0.80
buildKMPTableMethod · 0.80
clearMethod · 0.45
appendMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected