Skip to content

Class endstone::PluginLoader

ClassList > endstone > PluginLoader

Represents a plugin loader, which handles direct access to specific types of plugins.

  • #include <endstone/plugin/plugin_loader.h>

Public Functions

Type Name
PluginLoader (Server & server)
PluginLoader (const PluginLoader &) = delete
virtual void disablePlugin (Plugin & plugin) const
virtual void enablePlugin (Plugin & plugin) const
Server & getServer () const
Retrieves the Server object associated with thePluginLoader .
virtual std::vector< Plugin * > loadPlugins (const std::string & directory) = 0
PluginLoader & operator= (const PluginLoader &) = delete
virtual ~PluginLoader () = default

Protected Attributes

Type Name
Server & server_

Public Functions Documentation

function PluginLoader [½]

inline explicit endstone::PluginLoader::PluginLoader (
    Server & server
) 

function PluginLoader [2/2]

endstone::PluginLoader::PluginLoader (
    const PluginLoader &
) = delete

function disablePlugin

inline virtual void endstone::PluginLoader::disablePlugin (
    Plugin & plugin
) const

Disables the specified plugin Attempting to disable a plugin that is not enabled will have no effect

Parameters:


function enablePlugin

inline virtual void endstone::PluginLoader::enablePlugin (
    Plugin & plugin
) const

Enables the specified plugin Attempting to enable a plugin that is already enabled will have no effect

Parameters:


function getServer

Retrieves the Server object associated with thePluginLoader .

inline Server & endstone::PluginLoader::getServer () const

This function returns a reference to the Server object that the PluginLoader is associated with.

Returns:

The Server reference.


function loadPlugins

virtual std::vector< Plugin * > endstone::PluginLoader::loadPlugins (
    const std::string & directory
) = 0

Loads the plugin contained within the specified directory

Parameters:

  • directory Directory to check for plugins

Returns:

A list of all plugins loaded


function operator=

PluginLoader & endstone::PluginLoader::operator= (
    const PluginLoader &
) = delete

function ~PluginLoader

virtual endstone::PluginLoader::~PluginLoader () = default

Protected Attributes Documentation

variable server_

Server& endstone::PluginLoader::server_;


The documentation for this class was generated from the following file include/endstone/plugin/plugin_loader.h