proxygen
EventHandlerMock Class Reference
Inheritance diagram for EventHandlerMock:
folly::EventHandler

Public Member Functions

 EventHandlerMock (EventBase *eb, int fd)
 
 MOCK_METHOD1 (_handlerReady, void(uint16_t))
 
void handlerReady (uint16_t events) noexceptoverride
 
- Public Member Functions inherited from folly::EventHandler
 EventHandler (EventBase *eventBase, int fd)
 
 EventHandler (EventBase *eventBase=nullptr, NetworkSocket fd=NetworkSocket())
 
virtual ~EventHandler ()
 
bool registerHandler (uint16_t events)
 
void unregisterHandler ()
 
bool isHandlerRegistered () const
 
void attachEventBase (EventBase *eventBase)
 
void detachEventBase ()
 
void changeHandlerFD (int fd)
 
void changeHandlerFD (NetworkSocket fd)
 
void initHandler (EventBase *eventBase, int fd)
 
void initHandler (EventBase *eventBase, NetworkSocket fd)
 
uint16_t getRegisteredEvents () const
 
bool registerInternalHandler (uint16_t events)
 
bool isPending () const
 

Additional Inherited Members

- Public Types inherited from folly::EventHandler
enum  EventFlags {
  NONE = 0, READ = EV_READ, WRITE = EV_WRITE, READ_WRITE = (READ | WRITE),
  PERSIST = EV_PERSIST
}
 

Detailed Description

Definition at line 48 of file EventHandlerTest.cpp.

Constructor & Destructor Documentation

EventHandlerMock::EventHandlerMock ( EventBase eb,
int  fd 
)
inline

Definition at line 50 of file EventHandlerTest.cpp.

References MOCK_METHOD1, and uint16_t.

50 : EventHandler(eb, fd) {}
EventHandler(EventBase *eventBase, int fd)
Definition: EventHandler.h:65

Member Function Documentation

void EventHandlerMock::handlerReady ( uint16_t  events)
inlineoverridevirtualnoexcept

handlerReady() is invoked when the handler is ready.

Parameters
eventsA bitset indicating the events that are ready.

Implements folly::EventHandler.

Definition at line 53 of file EventHandlerTest.cpp.

53  {
54  _handlerReady(events);
55  }
EventHandlerMock::MOCK_METHOD1 ( _handlerReady  ,
void(uint16_t  
)

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