33 std::unique_ptr<HTTPMessage> msg,
35 virtual int onFieldData(std::unique_ptr<folly::IOBuf>,
49 CHECK(!boundary.empty());
50 boundary_ = folly::to<std::string>(
"\n--", boundary);
60 std::unique_ptr<folly::IOBuf>
onIngress(std::unique_ptr<folly::IOBuf>
data);
84 std::unique_ptr<HTTPMessage> msg)
override;
86 std::unique_ptr<folly::IOBuf> ,
92 std::unique_ptr<HTTPHeaders> )
override {
folly::IOBufQueue readToBoundary(bool &foundBoundary)
void onMessageComplete(HTTPCodec::StreamID, bool) override
void onTrailersComplete(HTTPCodec::StreamID, std::unique_ptr< HTTPHeaders >) override
void onHeadersComplete(HTTPCodec::StreamID stream, std::unique_ptr< HTTPMessage > msg) override
void onMessageBegin(HTTPCodec::StreamID, HTTPMessage *) override
void onBody(HTTPCodec::StreamID, std::unique_ptr< folly::IOBuf >, uint16_t) override
virtual int onFieldData(std::unique_ptr< folly::IOBuf >, uint64_t postBytesProcessed)=0
virtual void onFieldEnd(bool endedOnBoundary, uint64_t postBytesProcessed)=0
static Options cacheChainLength()
void onError(HTTPCodec::StreamID, const HTTPException &, bool) override
void setCallback(Callback *callback) override
RFC1867Codec(const std::string &boundary)
virtual int onFieldStart(const std::string &name, folly::Optional< std::string > filename, std::unique_ptr< HTTPMessage > msg, uint64_t postBytesProcessed)=0
std::unique_ptr< folly::IOBuf > pendingCR_
HTTP1xCodec headerParser_
void setCallback(Callback *callback)
std::unique_ptr< folly::IOBuf > onIngress(std::unique_ptr< folly::IOBuf > data)
void setParserPaused(bool paused) override
uint64_t getBytesProcessed() const
static constexpr uint64_t data[1]