P-E-R-R-Y
Utilitaires, contrats et vendors du moteur, en une seule doc
Loading...
Searching...
No Matches
SharedLibrary Class Reference

Encapsule le handle d'une bibliotheque dynamique. Rien de plus. More...

#include <SharedLibrary.hpp>

Public Types

using Handle = void *
using Handle = void *

Public Member Functions

 SharedLibrary (std::string path)
 ~SharedLibrary ()
 SharedLibrary (const SharedLibrary &)=delete
SharedLibrary & operator= (const SharedLibrary &)=delete
template<typename T>
T symbol (const char *name) const
const std::string & path () const
Handle handle () const
 SharedLibrary (std::string path)
 ~SharedLibrary ()
 SharedLibrary (const SharedLibrary &)=delete
SharedLibrary & operator= (const SharedLibrary &)=delete
template<typename T>
T symbol (const char *name) const
 Un symbole exporte, rendu comme un T.
const std::string & path () const
 Le chemin dont elle a ete ouverte.
Handle handle () const
 Le handle systeme, pour qui en a besoin.

Static Public Member Functions

static const char * extension ()
static const char * extension ()
 L'extension des bibliotheques de cette plateforme.

Detailed Description

Encapsule le handle d'une bibliotheque dynamique. Rien de plus.

Une bibliotheque dynamique ouverte : elle se ferme avec l'objet.

Exceptions
std::runtime_errorsi l'ouverture echoue

Member Typedef Documentation

◆ Handle [1/2]

using SharedLibrary::Handle = void *

◆ Handle [2/2]

using SharedLibrary::Handle = void *

Constructor & Destructor Documentation

◆ SharedLibrary() [1/4]

SharedLibrary::SharedLibrary ( std::string path)
inlineexplicit

◆ ~SharedLibrary() [1/2]

SharedLibrary::~SharedLibrary ( )
inline

◆ SharedLibrary() [2/4]

SharedLibrary::SharedLibrary ( const SharedLibrary & )
delete

◆ SharedLibrary() [3/4]

SharedLibrary::SharedLibrary ( std::string path)
inlineexplicit

◆ ~SharedLibrary() [2/2]

SharedLibrary::~SharedLibrary ( )
inline

◆ SharedLibrary() [4/4]

SharedLibrary::SharedLibrary ( const SharedLibrary & )
delete

Member Function Documentation

◆ extension() [1/2]

const char * SharedLibrary::extension ( )
inlinestatic

L'extension des bibliotheques de cette plateforme.

◆ extension() [2/2]

const char * SharedLibrary::extension ( )
inlinestatic

◆ handle() [1/2]

Handle SharedLibrary::handle ( ) const
inline

Le handle systeme, pour qui en a besoin.

◆ handle() [2/2]

Handle SharedLibrary::handle ( ) const
inline

◆ operator=() [1/2]

SharedLibrary & SharedLibrary::operator= ( const SharedLibrary & )
delete

◆ operator=() [2/2]

SharedLibrary & SharedLibrary::operator= ( const SharedLibrary & )
delete

◆ path() [1/2]

const std::string & SharedLibrary::path ( ) const
inline

Le chemin dont elle a ete ouverte.

◆ path() [2/2]

const std::string & SharedLibrary::path ( ) const
inline

◆ symbol() [1/2]

template<typename T>
T SharedLibrary::symbol ( const char * name) const
inline

Un symbole exporte, rendu comme un T.

Parameters
name
Returns
T nul si le symbole est absent

◆ symbol() [2/2]

template<typename T>
T SharedLibrary::symbol ( const char * name) const
inline

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