proxygen
proxygen::Mock1867Callback Class Reference
Inheritance diagram for proxygen::Mock1867Callback:
proxygen::RFC1867Codec::Callback testing::StrictMock< proxygen::Mock1867Callback > testing::StrictMock< proxygen::Mock1867Callback > testing::StrictMock< proxygen::Mock1867Callback >

Public Member Functions

 MOCK_METHOD4 (onFieldStartImpl, int(const string &name, const std::string &filename, std::shared_ptr< HTTPMessage > msg, uint64_t bytesProcessed))
 
int onFieldStartImpl (const string &name, const std::string &filename, std::unique_ptr< HTTPMessage > msg, uint64_t bytesProcessed)
 
int onFieldStart (const string &name, folly::Optional< std::string > filename, std::unique_ptr< HTTPMessage > msg, uint64_t bytesProcessed) override
 
 MOCK_METHOD2 (onFieldData, int(std::shared_ptr< folly::IOBuf >, uint64_t))
 
int onFieldData (std::unique_ptr< folly::IOBuf > data, uint64_t bytesProcessed) override
 
 MOCK_METHOD2 (onFieldEnd, void(bool, uint64_t))
 
 MOCK_METHOD0 (onError, void())
 
- Public Member Functions inherited from proxygen::RFC1867Codec::Callback
virtual ~Callback ()
 
virtual void onFieldEnd (bool endedOnBoundary, uint64_t postBytesProcessed)=0
 
virtual void onError ()=0
 

Detailed Description

Definition at line 92 of file RFC1867Test.cpp.

Member Function Documentation

proxygen::Mock1867Callback::MOCK_METHOD0 ( onError  ,
void()   
)
proxygen::Mock1867Callback::MOCK_METHOD2 ( onFieldData  ,
int(std::shared_ptr< folly::IOBuf >, uint64_t  
)
proxygen::Mock1867Callback::MOCK_METHOD2 ( onFieldEnd  ,
void(bool, uint64_t  
)
proxygen::Mock1867Callback::MOCK_METHOD4 ( onFieldStartImpl  ,
int(const string &name, const std::string &filename, std::shared_ptr< HTTPMessage > msg, uint64_t bytesProcessed)   
)
int proxygen::Mock1867Callback::onFieldData ( std::unique_ptr< folly::IOBuf data,
uint64_t  bytesProcessed 
)
inlineoverridevirtual

Implements proxygen::RFC1867Codec::Callback.

Definition at line 109 of file RFC1867Test.cpp.

References MOCK_METHOD0, MOCK_METHOD2, and uint64_t.

110  {
111  std::shared_ptr<IOBuf> sh_data(data.release());
112  return onFieldData(sh_data, bytesProcessed);
113  }
int onFieldData(std::unique_ptr< folly::IOBuf > data, uint64_t bytesProcessed) override
int proxygen::Mock1867Callback::onFieldStart ( const string name,
folly::Optional< std::string filename,
std::unique_ptr< HTTPMessage msg,
uint64_t  bytesProcessed 
)
inlineoverridevirtual

Implements proxygen::RFC1867Codec::Callback.

Definition at line 103 of file RFC1867Test.cpp.

References MOCK_METHOD2, folly::gen::move, uint64_t, and folly::Optional< Value >::value_or().

105  {
106  return onFieldStartImpl(name, filename.value_or(""), std::move(msg), bytesProcessed);
107  }
constexpr detail::Map< Move > move
Definition: Base-inl.h:2567
const char * name
Definition: http_parser.c:437
int onFieldStartImpl(const string &name, const std::string &filename, std::unique_ptr< HTTPMessage > msg, uint64_t bytesProcessed)
Definition: RFC1867Test.cpp:97
FOLLY_CPP14_CONSTEXPR Value value_or(U &&dflt) const &
Definition: Optional.h:330
int proxygen::Mock1867Callback::onFieldStartImpl ( const string name,
const std::string filename,
std::unique_ptr< HTTPMessage msg,
uint64_t  bytesProcessed 
)
inline

Definition at line 97 of file RFC1867Test.cpp.

99  {
100  std::shared_ptr<HTTPMessage> sh_msg(msg.release());
101  return onFieldStartImpl(name, filename, sh_msg, bytesProcessed);
102  }
const char * name
Definition: http_parser.c:437
int onFieldStartImpl(const string &name, const std::string &filename, std::unique_ptr< HTTPMessage > msg, uint64_t bytesProcessed)
Definition: RFC1867Test.cpp:97

The documentation for this class was generated from the following file: