OpenWalnut  1.4.0
Public Member Functions | Private Attributes
WModuleContainerWrapper Class Reference

Encapsulates a module container. More...

#include <WModuleContainerWrapper.h>

List of all members.

Public Member Functions

 WModuleContainerWrapper ()
 Constructor.
 WModuleContainerWrapper (boost::shared_ptr< WModuleContainer > mc)
 Constructor.
 ~WModuleContainerWrapper ()
 Destructor.
WModuleWrapper create (std::string const &name)
 Creates a module from the prototype with the given name.
WModuleWrapper createDataModule (std::string const &filename)
 Creates a data module and load the file given via filename.
void remove (WModuleWrapper module)
 Remove a module from the container.

Private Attributes

boost::shared_ptr
< WModuleContainer
m_mc
 The module container.

Detailed Description

Encapsulates a module container.

This class is exposed to scripts.

Definition at line 41 of file WModuleContainerWrapper.h.


Constructor & Destructor Documentation

Constructor.

Creates an empty wrapper.

Definition at line 31 of file WModuleContainerWrapper.cpp.

WModuleContainerWrapper::WModuleContainerWrapper ( boost::shared_ptr< WModuleContainer mc) [explicit]

Constructor.

Parameters:
mcThe module container.

Definition at line 36 of file WModuleContainerWrapper.cpp.

Destructor.

Definition at line 41 of file WModuleContainerWrapper.cpp.


Member Function Documentation

WModuleWrapper WModuleContainerWrapper::create ( std::string const &  name)

Creates a module from the prototype with the given name.

Parameters:
nameThe name of the module prototype.
Returns:
The module.

Definition at line 45 of file WModuleContainerWrapper.cpp.

References m_mc.

WModuleWrapper WModuleContainerWrapper::createDataModule ( std::string const &  filename)

Creates a data module and load the file given via filename.

Parameters:
filenameThe name of the file to load.
Returns:
The module.

Definition at line 51 of file WModuleContainerWrapper.cpp.

References WModuleFactory::getModuleFactory(), m_mc, and WDataModule::setSuppressColormaps().

Remove a module from the container.

Parameters:
moduleThe module to remove.

Definition at line 65 of file WModuleContainerWrapper.cpp.

References WModuleWrapper::getModulePtr(), and m_mc.


Member Data Documentation

boost::shared_ptr< WModuleContainer > WModuleContainerWrapper::m_mc [private]

The module container.

Definition at line 86 of file WModuleContainerWrapper.h.

Referenced by create(), createDataModule(), and remove().


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