MCPcopy Create free account
hub / github.com/Pagghiu/SaneCppLibraries / finishFrame

Method finishFrame

Libraries/Http/HttpWebSocket.cpp:925–939  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

923}
924
925Result HttpWebSocketFrameWriter::finishFrame()
926{
927 SC_TRY_MSG(frameInProgress, "HttpWebSocketFrameWriter no frame in progress");
928 SC_TRY_MSG(payloadBytesRemaining == 0, "HttpWebSocketFrameWriter frame payload incomplete");
929
930 if (not currentFrame.isControlFrame())
931 {
932 fragmentedMessageInProgress = not currentFrame.fin;
933 }
934
935 currentFrame = {};
936 frameInProgress = false;
937 payloadBytesWritten = 0;
938 return Result(true);
939}
940
941void HttpWebSocketMessageAssembler::reset(Span<char> storage)
942{

Callers 4

encodeFrameFunction · 0.80
writerRoundtripMethod · 0.80
sendFrameMethod · 0.80
queueAutomaticControlMethod · 0.80

Calls 2

isControlFrameMethod · 0.80
ResultClass · 0.50

Tested by 2

encodeFrameFunction · 0.64
writerRoundtripMethod · 0.64