OpenWalnut
1.2.5
|
A base class for all parts of OpenWalnut which can be serialized to a project file. More...
#include <WProjectFileIO.h>
Public Member Functions | |
WProjectFileIO () | |
Default constructor. | |
virtual | ~WProjectFileIO () |
Destructor. | |
virtual bool | parse (std::string line, unsigned int lineNumber)=0 |
This method parses the specified line and interprets it. | |
virtual void | done () |
Called whenever the end of the project file has been reached. | |
virtual void | save (std::ostream &output)=0 |
Saves the state to the specified stream. |
A base class for all parts of OpenWalnut which can be serialized to a project file.
It is used by WProjectFile to actually parse the file line by line. Derive from this class if you write your own parser and use it to fill your internal data structures.
Definition at line 36 of file WProjectFileIO.h.
WProjectFileIO::WProjectFileIO | ( | ) |
Default constructor.
Definition at line 27 of file WProjectFileIO.cpp.
|
virtual |
Destructor.
Definition at line 32 of file WProjectFileIO.cpp.
|
virtual |
Called whenever the end of the project file has been reached.
This is useful if your specific parser class wants to do some post processing after parsing line by line.
Reimplemented in WModuleProjectFileCombiner, WGEProjectFileIO, and WRoiProjectFileIO.
Definition at line 37 of file WProjectFileIO.cpp.
|
pure virtual |
This method parses the specified line and interprets it.
It gets called line by line by WProjectFile.
line | the current line as string |
lineNumber | the current line number. Useful for error/warning/debugging output. |
Implemented in WModuleProjectFileCombiner, WGEProjectFileIO, and WRoiProjectFileIO.
|
pure virtual |
Saves the state to the specified stream.
output | the stream to print the state to. |
Implemented in WModuleProjectFileCombiner, WGEProjectFileIO, and WRoiProjectFileIO.