frepple::utils::XMLInputFile Class Reference

This class reads XML data from a file system. More...

#include <utils.h>

Inheritance diagram for frepple::utils::XMLInputFile:

List of all members.

Public Member Functions

string getFileName ()
void parse (Object *, bool=false)
void setFileName (const string &s)
 XMLInputFile (const string &s)
 XMLInputFile ()

Detailed Description

This class reads XML data from a file system.

The filename argument can be the name of a file or a directory. If a directory is passed, all files with the extension ".xml" will be read from it. Subdirectories are not recursed.

Definition at line 4414 of file utils.h.


Constructor & Destructor Documentation

frepple::utils::XMLInputFile::XMLInputFile ( const string &  s) [inline]

Constructor. The argument passed is the name of a file or a directory.

Definition at line 4419 of file utils.h.

frepple::utils::XMLInputFile::XMLInputFile ( ) [inline]

Default constructor.

Definition at line 4422 of file utils.h.


Member Function Documentation

string frepple::utils::XMLInputFile::getFileName ( ) [inline]

Returns the name of the file or directory to process.

Definition at line 4428 of file utils.h.

void frepple::utils::XMLInputFile::parse ( Object pRoot,
bool  validate = false 
) [virtual]

Parse the specified file. When a directory was passed as the argument a failure is flagged as soon as a single file returned a failure. All files in an directory are processed however, regardless of failure with one of the files.

Exceptions:
RuntimeExceptionGenerated in the following conditions:
  • no input file or directory has been specified.
  • read access to the input file is not available
  • the program doesn't support reading directories on your platform

Reimplemented from frepple::utils::XMLInput.

Definition at line 805 of file xmlparser.cpp.

void frepple::utils::XMLInputFile::setFileName ( const string &  s) [inline]

Update the name of the file to be processed.

Definition at line 4425 of file utils.h.


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

Documentation generated for frePPLe by  doxygen