XCKS file parser.
More...
#include <xcksfilereader.hpp>
|
| XCKSFileReader ()=delete |
| Deleted default constructor. More...
|
|
| XCKSFileReader (XCKSReaderHandler &handler, const std::filesystem::path &baseDir) |
| Constructor. More...
|
|
void | startElement (const std::string &name, const XMLParserAttributes &atts) noexcept(false) override |
| Receives notification of the beginning of an element. More...
|
|
void | endElement (const std::string &name) noexcept(false) override |
| Receives notification of the end of an element. More...
|
|
void | characters (const std::string &chars) noexcept(false) override |
| Receives notification of character data. More...
|
|
void | fatalError (XML_Error errorCode, const std::string &errorMessage, int line, int column) noexcept override |
| Receive notification of a non-recoverable error. More...
|
|
bool | parse (const std::string &filename) |
| Parses the given file. More...
|
|
bool | parse (std::istream &is) |
| Parses the given input stream. More...
|
|
XCKS file parser.
Definition at line 41 of file xcksfilereader.hpp.
◆ XCKSFileReader() [1/2]
libxcks::XCKSFileReader::XCKSFileReader |
( |
| ) |
|
|
delete |
Deleted default constructor.
◆ XCKSFileReader() [2/2]
libxcks::XCKSFileReader::XCKSFileReader |
( |
XCKSReaderHandler & |
xcksReaderHandler, |
|
|
const std::filesystem::path & |
baseDir |
|
) |
| |
Constructor.
- Parameters
-
xcksReaderHandler | The XCKS file reader handler. |
baseDir | The base directory of the (Z)XCKS file to read. Must be an absolute path name. |
Definition at line 52 of file xcksfilereader.cpp.
◆ characters()
void libxcks::XCKSFileReader::characters |
( |
const std::string & |
chars | ) |
|
|
overridevirtualnoexcept |
◆ endElement()
void libxcks::XCKSFileReader::endElement |
( |
const std::string & |
name | ) |
|
|
overridevirtualnoexcept |
◆ fatalError()
void libxcks::XCKSFileReader::fatalError |
( |
XML_Error |
errorCode, |
|
|
const std::string & |
errorMessage, |
|
|
int |
line, |
|
|
int |
column |
|
) |
| |
|
overridevirtualnoexcept |
Receive notification of a non-recoverable error.
- Parameters
-
errorCode | The error code. |
errorMessage | The error message. |
line | The line number the text where the error has occurred. |
column | The column number where the error has occurred. |
Reimplemented from libxcks::XMLParser.
Definition at line 145 of file xcksfilereader.cpp.
◆ getVersionHandler()
Gets the handler to parse the sums' file.
- Attention
- The returned pointer is managed by
std::shared_ptr
.
- Note
- This method must be only used as a comfort method to access to the pointed instance.
- Returns
- The handler to parse the sums' file.
Definition at line 164 of file xcksfilereader.cpp.
◆ setVersionHandler()
Sets the handler to parse the sums' file.
- Parameters
-
[in] | handler | The handler to parse the sums' file. |
Definition at line 176 of file xcksfilereader.cpp.
◆ startElement()
void libxcks::XCKSFileReader::startElement |
( |
const std::string & |
name, |
|
|
const XMLParserAttributes & |
atts |
|
) |
| |
|
overridevirtualnoexcept |
Receives notification of the beginning of an element.
- Parameters
-
name | The name of the element. |
atts | The attributes attached to the element. |
Reimplemented from libxcks::XMLParser.
Definition at line 68 of file xcksfilereader.cpp.
◆ baseDirectory
const std::filesystem::path libxcks::XCKSFileReader::baseDirectory |
|
protected |
◆ readerHandler
◆ versionHandler
The documentation for this class was generated from the following files: