Base for all data loader modules. More...
#include <WDataModule.h>
Public Types | |
typedef boost::shared_ptr < WDataModule > | SPtr |
Convenience typedef for a boost::shared_ptr< WDataModule >. | |
typedef boost::shared_ptr < const WDataModule > | ConstSPtr |
Convenience typedef for a boost::shared_ptr< const WDataModule >. | |
Public Member Functions | |
WDataModule () | |
Default constructor. | |
virtual | ~WDataModule () |
Destructor. | |
virtual MODULE_TYPE | getType () const |
Gets the type of the module. | |
virtual boost::shared_ptr < WDataSet > | getDataSet ()=0 |
Getter for the dataset. | |
virtual void | setFilename (boost::filesystem::path fname)=0 |
Sets the filename of the file to load. | |
virtual boost::filesystem::path | getFilename () const =0 |
Gets the path of the file that has been loaded. |
Base for all data loader modules.
This currently is only a prototype to move WMData out of the core. Later, it will provide a whole interface to handle arbitrary data/multi-file data and other complex things.
Definition at line 36 of file WDataModule.h.
typedef boost::shared_ptr< const WDataModule > WDataModule::ConstSPtr |
Convenience typedef for a boost::shared_ptr< const WDataModule >.
Reimplemented from WModule.
Definition at line 48 of file WDataModule.h.
typedef boost::shared_ptr< WDataModule > WDataModule::SPtr |
Convenience typedef for a boost::shared_ptr< WDataModule >.
Reimplemented from WModule.
Definition at line 43 of file WDataModule.h.
WDataModule::WDataModule | ( | ) |
Default constructor.
Definition at line 27 of file WDataModule.cpp.
WDataModule::~WDataModule | ( | ) | [virtual] |
Destructor.
Definition at line 32 of file WDataModule.cpp.
virtual boost::shared_ptr< WDataSet > WDataModule::getDataSet | ( | ) | [pure virtual] |
Getter for the dataset.
virtual boost::filesystem::path WDataModule::getFilename | ( | ) | const [pure virtual] |
Gets the path of the file that has been loaded.
It always is the value which has been set during the FIRST call of setFilename.
MODULE_TYPE WDataModule::getType | ( | ) | const [virtual] |
Gets the type of the module.
This is useful for FAST differentiation between several modules like standard modules and data modules which play a special role in OpenWalnut/Kernel.
Reimplemented from WModule.
Definition at line 37 of file WDataModule.cpp.
virtual void WDataModule::setFilename | ( | boost::filesystem::path | fname | ) | [pure virtual] |
Sets the filename of the file to load.
If this method is called multiple times it has no effect. It has to be called right after construction BEFORE running the data module.
fname | the name of the file |