MCPcopy Create free account
hub / github.com/Beckhoff/ADS / Frame

Method Frame

AdsLib/Frame.cpp:13–24  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11#include <new>
12
13Frame::Frame(size_t length, const void *data)
14 : m_Data(new uint8_t[length])
15{
16 m_Size = m_Data ? length : 0;
17 m_Pos = m_Data.get() + m_Size;
18 m_OriginalSize = m_Size;
19
20 if (m_Pos && data) {
21 m_Pos -= length;
22 memcpy(m_Pos, data, length);
23 }
24}
25
26uint8_t Frame::operator[](size_t index) const
27{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected