|
VoltMod
C++23 framework for CS2 server plugins
|
#include <PublishedInterfaces.hpp>
Public Types | |
| using | OwnerId = const void * |
Public Member Functions | |
| void | Publish (OwnerId owner, std::string_view name, void *implementation) |
| void | Unpublish (OwnerId owner, std::string_view name) |
| void * | Find (std::string_view name) const |
| std::vector< std::string > | RemoveAll (OwnerId owner) |
Interfaces plugins publish to each other. Only the publishing owner can refresh or withdraw a name.
Definition at line 12 of file PublishedInterfaces.hpp.
Definition at line 15 of file PublishedInterfaces.hpp.
| void * VoltMod::PublishedInterfaces::Find | ( | std::string_view | name | ) | const |
Definition at line 38 of file PublishedInterfaces.cpp.
References VoltMod::ReadFile().
Referenced by VoltMod::PluginContext::Find().
| void VoltMod::PublishedInterfaces::Publish | ( | OwnerId | owner, |
| std::string_view | name, | ||
| void * | implementation | ||
| ) |
Add or refresh name. A peer's live pointer is never swapped out from under it.
Definition at line 9 of file PublishedInterfaces.cpp.
References VoltMod::ReadFile().
Referenced by VoltMod::PluginContext::Publish().
| std::vector< std::string > VoltMod::PublishedInterfaces::RemoveAll | ( | OwnerId | owner | ) |
Withdraw everything owner published and report the names it was still holding.
Definition at line 44 of file PublishedInterfaces.cpp.
References VoltMod::ReadFile().
Referenced by VoltMod::PluginContext::RemoveAll().
Definition at line 27 of file PublishedInterfaces.cpp.
References VoltMod::ReadFile().
Referenced by VoltMod::PluginContext::Unpublish().