![]() |
Spicy
|
#include <library.h>
Public Member Functions | |
Library (const hilti::rt::filesystem::path &path) | |
Library (const Library &)=delete | |
Library & | operator= (const Library &)=delete |
Library (Library &&)=default | |
Library & | operator= (Library &&)=default |
hilti::rt::Result< hilti::rt::library::Version > | open () const |
hilti::rt::Result< Nothing > | save (const hilti::rt::filesystem::path &path) const |
hilti::rt::Result< void * > | symbol (std::string_view name) const |
hilti::rt::Result< Nothing > | remove () const |
Container for storing code compiled into a native shared library.
This class loads the underlying library it wraps into its internal store on construction and subsequently does not depend on it anymore.
hilti::rt::Library::Library | ( | const hilti::rt::filesystem::path & | path | ) |
Makes a library available for opening.
path | full path to the library file |
<em>std::runtime_error</em> | if library does not exist, or any other I/O operation failed |
hilti::rt::Result< hilti::rt::library::Version > hilti::rt::Library::open | ( | ) | const |
Load the library into the current process
hilti::rt::Result< hilti::rt::Nothing > hilti::rt::Library::save | ( | const hilti::rt::filesystem::path & | path | ) | const |
Save this library under a different path.
path | the path where this library should be stored |