LeviLamina
Loading...
Searching...
No Matches
ll::mod::NativeMod Class Reference
Inheritance diagram for ll::mod::NativeMod:

Public Types

enum class  State { Enabled , Disabled }
using callback_t = bool(Mod&)
using CallbackFn = std::function<callback_t>

Public Member Functions

 NativeMod (Manifest manifest, sys_utils::HandleT handle=nullptr)
LLNDAPI sys_utils::HandleT getHandle () const
LLNDAPI State getState () const
LLNDAPI Manifest const & getManifest () const
LLNDAPI std::string const & getName () const
LLNDAPI std::string const & getType () const
LLNDAPI std::filesystem::path const & getModDir () const
LLNDAPI std::filesystem::path const & getDataDir () const
LLNDAPI std::filesystem::path const & getConfigDir () const
LLNDAPI std::optional< std::filesystem::path > getWorldDataDir () const
LLNDAPI std::optional< std::filesystem::path > getWorldConfigDir () const
LLNDAPI std::filesystem::path const & getLangDir () const
LLNDAPI std::filesystem::path const & getResourceDir () const
LLNDAPI std::filesystem::path const & getBehaviorDir () const
LLNDAPI io::LoggergetLogger () const
bool isEnabled () const
bool isDisabled () const
LLAPI void onLoad (CallbackFn func) noexcept
LLAPI void onUnload (CallbackFn func) noexcept
LLAPI void onEnable (CallbackFn func) noexcept
LLAPI void onDisable (CallbackFn func) noexcept

Static Public Member Functions

static LLNDAPI std::shared_ptr< NativeMod > getByHandle (sys_utils::HandleT handle)
static LLNDAPI std::shared_ptr< NativeMod > current (sys_utils::HandleT handle=sys_utils::getCurrentModuleHandle())

Protected Member Functions

sys_utils::DynamicLibrary & getDynamicLibrary ()
LLAPI Expected onLoad () noexcept
LLAPI Expected onUnload () noexcept
LLAPI Expected onEnable () noexcept
LLAPI Expected onDisable () noexcept
LLAPI void release () noexcept
LLAPI void setState (State state) const
LLNDAPI bool hasOnLoad () const noexcept
LLNDAPI bool hasOnUnload () const noexcept
LLNDAPI bool hasOnEnable () const noexcept
LLNDAPI bool hasOnDisable () const noexcept

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