MCPcopy Create free account
hub / github.com/FastLED/FastLED / ~ServerGuard

Method ~ServerGuard

tests/fl/stl/asio/http/native_client.cpp:29–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27 ServerGuard(ServerGuard&& o) : ptr(fl::move(o.ptr)), port(o.port) { o.port = 0; }
28 ServerGuard& operator=(ServerGuard&& o) { ptr = fl::move(o.ptr); port = o.port; o.port = 0; return *this; }
29 ~ServerGuard() { if (ptr) { ptr->stop(); } }
30 NativeHttpServer* operator->() { return ptr.get(); }
31 NativeHttpServer& operator*() { return *ptr; }
32 explicit operator bool() const { return ptr != nullptr; }

Callers

nothing calls this directly

Calls 1

stopMethod · 0.45

Tested by

no test coverage detected