MCPcopy Create free account
hub / github.com/SmingHub/Sming / readMemoryBlock

Method readMemoryBlock

Sming/Core/Data/Stream/MultiStream.cpp:15–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13#include "MultiStream.h"
14
15uint16_t MultiStream::readMemoryBlock(char* data, int bufSize)
16{
17 if(stream && stream->isFinished()) {
18 stream.reset();
19 }
20
21 if(!stream) {
22 stream.reset(getNextStream());
23 if(!stream) {
24 finished = true;
25 return 0;
26 }
27 }
28
29 return stream->readMemoryBlock(data, bufSize);
30}
31
32bool MultiStream::seek(int len)
33{

Callers 1

copyFromMethod · 0.45

Calls 2

isFinishedMethod · 0.45
resetMethod · 0.45

Tested by 1

copyFromMethod · 0.36