MCPcopy Create free account
hub / github.com/apache/thrift / global_fixture

Method global_fixture

lib/cpp/test/TransportTest.cpp:1027–1038  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1025struct global_fixture {
1026 std::shared_ptr<apache::thrift::concurrency::Thread> alarmThread_;
1027 global_fixture() {
1028#if _WIN32
1029 apache::thrift::transport::TWinsockSingleton::create();
1030#endif
1031
1032 apache::thrift::concurrency::ThreadFactory factory;
1033 factory.setDetached(false);
1034
1035 alarmThread_ = factory.newThread(
1036 apache::thrift::concurrency::FunctionRunner::create(alarm_handler_wrapper));
1037 alarmThread_->start();
1038 }
1039 ~global_fixture() {
1040 {
1041 apache::thrift::concurrency::Synchronized s(g_alarm_monitor);

Callers

nothing calls this directly

Calls 3

setDetachedMethod · 0.80
newThreadMethod · 0.45
startMethod · 0.45

Tested by

no test coverage detected