MCPcopy Create free account
hub / github.com/FastLED/FastLED / consume

Method consume

src/fl/stl/asio/http/http_parser.cpp.hpp:263–271  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

261}
262
263void HttpRequestParser::consume(size_t n) {
264 if (n >= mBuffer.size()) {
265 mBuffer.clear();
266 } else {
267 // Work around fl::vector::erase() issue by copying remaining data
268 fl::vector<u8> remaining(mBuffer.begin() + n, mBuffer.end());
269 mBuffer = remaining;
270 }
271}
272
273fl::optional<fl::string> HttpRequestParser::getHeader(const char* name) const {
274 fl::string lowerName = toLower(name);

Callers

nothing calls this directly

Calls 4

sizeMethod · 0.45
clearMethod · 0.45
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected