dlLibraryTable Class Reference

A table of dynamically loaded libraries. More...

Public Member Functions

 ClassName ("dlLibraryTable")
 
 dlLibraryTable ()=default
 Construct null. More...
 
 dlLibraryTable (dlLibraryTable &&)=default
 Move construct. More...
 
 dlLibraryTable (const UList< fileName > &libNames, bool verbose=true)
 Open specified libraries. Ignores duplicate names. More...
 
 dlLibraryTable (const dictionary &dict, const word &libsEntry)
 
 ~dlLibraryTable ()
 Destructor. Closes all libraries loaded by the table. More...
 
bool empty () const
 True if no there are no libraries loaded by the table. More...
 
label size () const
 The number of libraries loaded by the table. More...
 
void clear (bool verbose=true)
 Clearing closes all libraries loaded by the table. More...
 
bool append (const fileName &libName)
 Add to the list of names, but do not yet open. More...
 
label append (const UList< fileName > &libNames)
 Add to the list of names, but do not yet open. More...
 
bool open (bool verbose=true)
 
void * open (const fileName &libName, bool verbose=true)
 Open the named library, optionally warn if problems occur. More...
 
bool open (const UList< fileName > &libNames, bool verbose=true)
 Open the named libraries, optionally warn if problems occur. More...
 
bool close (const fileName &libName, bool verbose=true)
 Close the named library, optionally warn if problems occur. More...
 
void * findLibrary (const fileName &libName)
 Find the handle of the named library. More...
 
bool open (const dictionary &dict, const word &libsEntry)
 
template<class TablePtr >
bool open (const dictionary &dict, const word &libsEntry, const TablePtr &tablePtr)
 
dlLibraryTableoperator= (dlLibraryTable &&)=default
 Move assignment. More...
 

Detailed Description

A table of dynamically loaded libraries.

Source files

Definition at line 51 of file dlLibraryTable.H.

Constructor & Destructor Documentation

◆ dlLibraryTable() [1/4]

dlLibraryTable ( )
default

Construct null.

◆ dlLibraryTable() [2/4]

dlLibraryTable ( dlLibraryTable &&  )
default

Move construct.

◆ dlLibraryTable() [3/4]

dlLibraryTable ( const UList< fileName > &  libNames,
bool  verbose = true 
)
explicit

Open specified libraries. Ignores duplicate names.

Definition at line 76 of file dlLibraryTable.C.

References dlLibraryTable::open().

Here is the call graph for this function:

◆ dlLibraryTable() [4/4]

dlLibraryTable ( const dictionary dict,
const word libsEntry 
)

Open all libraries listed in the 'libsEntry' entry in the given dictionary. Verbose = true.

Definition at line 86 of file dlLibraryTable.C.

References dict, and dlLibraryTable::open().

Here is the call graph for this function:

◆ ~dlLibraryTable()

Destructor. Closes all libraries loaded by the table.

Definition at line 97 of file dlLibraryTable.C.

References clear().

Here is the call graph for this function:

Member Function Documentation

◆ ClassName()

ClassName ( "dlLibraryTable"  )

◆ empty()

bool empty ( ) const

True if no there are no libraries loaded by the table.

Definition at line 105 of file dlLibraryTable.C.

◆ size()

Foam::label size ( ) const

The number of libraries loaded by the table.

Definition at line 119 of file dlLibraryTable.C.

◆ clear()

void clear ( bool  verbose = true)

Clearing closes all libraries loaded by the table.

Definition at line 135 of file dlLibraryTable.C.

References DebugInFunction, Foam::dlClose(), Foam::endl(), forAll, forAllReverse, Foam::name(), Foam::nl, and WarningInFunction.

Here is the call graph for this function:

◆ append() [1/2]

bool append ( const fileName libName)

Add to the list of names, but do not yet open.

Ignores duplicate names.

Definition at line 197 of file dlLibraryTable.C.

◆ append() [2/2]

Foam::label append ( const UList< fileName > &  libNames)

Add to the list of names, but do not yet open.

Ignores duplicate names.

Definition at line 211 of file dlLibraryTable.C.

References append().

Here is the call graph for this function:

◆ open() [1/5]

bool open ( bool  verbose = true)

Open named, but unopened libraries. These names will normally have been added with the append() method.

Definition at line 227 of file dlLibraryTable.C.

References forAll.

Referenced by dlLibraryTable::dlLibraryTable(), codeStream::getFunction(), and dlLibraryTable::open().

Here is the caller graph for this function:

◆ open() [2/5]

void * open ( const fileName libName,
bool  verbose = true 
)

Open the named library, optionally warn if problems occur.

Definition at line 258 of file dlLibraryTable.C.

◆ open() [3/5]

bool open ( const UList< fileName > &  libNames,
bool  verbose = true 
)

Open the named libraries, optionally warn if problems occur.

Ignores duplicate names.

Definition at line 276 of file dlLibraryTable.C.

References dlLibraryTable::open().

Here is the call graph for this function:

◆ close()

bool close ( const fileName libName,
bool  verbose = true 
)

Close the named library, optionally warn if problems occur.

Definition at line 303 of file dlLibraryTable.C.

References DebugInFunction, Foam::dlClose(), Foam::endl(), Foam::name(), Foam::nl, and WarningInFunction.

Here is the call graph for this function:

◆ findLibrary()

void * findLibrary ( const fileName libName)

Find the handle of the named library.

Definition at line 334 of file dlLibraryTable.C.

Referenced by codeStream::getFunction().

Here is the caller graph for this function:

◆ open() [4/5]

bool open ( const dictionary dict,
const word libsEntry 
)

Open all libraries listed in the 'libsEntry' entry in the given dictionary.

Definition at line 348 of file dlLibraryTable.C.

References dict, dlLibraryTable::open(), and dictionary::readIfPresent().

Here is the call graph for this function:

◆ open() [5/5]

bool open ( const dictionary dict,
const word libsEntry,
const TablePtr &  tablePtr 
)

Open all libraries listed in the 'libsEntry' entry in the given dictionary and check the additions to the given constructor table

Definition at line 37 of file dlLibraryTableTemplates.C.

References Foam::expressions::patchExpr::debug, dict, Foam::endl(), Foam::nl, and WarningInFunction.

Here is the call graph for this function:

◆ operator=()

dlLibraryTable& operator= ( dlLibraryTable &&  )
default

Move assignment.


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