#include <Files.hxx>
Inheritance diagram for Talos::ConfigStream:
Public Member Functions | |
ConfigStream () | |
Default constructor. | |
ConfigStream (string file_name, string comments="#%", string delimiters=" \t:=|\n,;", string markup_tags="<>$") | |
Main constructor. | |
void | NoSection () |
Deselects the section. | |
void | SetSection (string section) |
Sets the current section. | |
string | GetSection () const |
Returns the current section. | |
void | SetMarkupTags (string markup_tags) |
Sets the markup tags. | |
string | GetMarkupTags () const |
Returns the markup tags. | |
bool | IsEmpty () |
Checks whether the stream or the current section is empty. | |
bool | Find (string element) |
Sets the position of the get pointer after a given element. | |
bool | FindFromBeginning (string element) |
Sets the position of the get pointer after a given element. | |
virtual string | GetElement () |
Returns the next valid element. | |
virtual string | GetLine () |
Returns the next valid line. | |
virtual bool | GetLine (string &line) |
Returns the next valid line. | |
Protected Attributes | |
string | markup_tags_ |
string | section_ |
Friends | |
class | ConfigStreams |
|
Default constructor. Nothing is performed. |
|
Main constructor. Opens a file.
|
|
Sets the position of the get pointer after a given element. Sets the position of the get pointer exactly after a given element.
Reimplemented from Talos::ExtStream. |
|
Sets the position of the get pointer after a given element. Sets the position of the get pointer exactly after a given element.
Reimplemented from Talos::ExtStream. |
|
Returns the next valid element. Returns the next valid element, i.e. the next element that is not in a line to be discarded.
Reimplemented from Talos::ExtStream. |
|
Returns the next valid line. Returns the next valid line, i.e. the next line that is not a line to be discarded and from which comments have been extracted.
Reimplemented from Talos::ExtStream. |
|
Returns the next valid line. Returns the next valid line, i.e. the next line that is not a line to be discarded and from which comments have been extracted.
Reimplemented from Talos::ExtStream. |
|
Returns the markup tags.
|
|
Returns the current section.
|
|
Checks whether the stream or the current section is empty. If no section has been selected, this method checks whether the stream has still valid elements to be read. If the stream is bound to a given section, this method checks whether there remains at least one element in the section.
Reimplemented from Talos::ExtStream. |
|
Deselects the section. Deselects the section (this is equivalent to SetSection("")). |
|
Sets the markup tags.
|
|
Sets the current section.
|