--- trunk/src/io/SectionParser.hpp 2005/01/12 22:41:40 246 +++ trunk/src/io/SectionParser.hpp 2005/04/21 14:12:19 514 @@ -1,4 +1,4 @@ - /* +/* * Copyright (c) 2005 The University of Notre Dame. All Rights Reserved. * * The University of Notre Dame grants you ("Licensee") a @@ -48,35 +48,34 @@ namespace oopse { #include "utils/StringTokenizer.hpp" namespace oopse { + + class ForceField; + + /** + * @class SectionParser SectionParser.hpp "io/SectionParser.hpp" + * @todo document + */ + class SectionParser { + public: + virtual ~SectionParser() {} + void parse(std::istream& input, ForceField& ff, int lineNo); + + const std::string& getSectionName() const { + return sectionName_; + } + + protected: + void setSectionName(const std::string& sectionName) { + sectionName_ = sectionName; + } + + private: + bool isEndSection(const std::string& line); + virtual void parseLine(ForceField& ff, const std::string& line, int lineNo) = 0; + std::string sectionName_; + }; -class ForceField; - /** - * @class SectionParser SectionParser.hpp "io/SectionParser.hpp" - * @todo document - */ - class SectionParser { - public: - virtual ~SectionParser() {} - void parse(std::istream& input, ForceField& ff, int lineNo); - - const std::string& getSectionName() const { - return sectionName_; - } - - protected: - void setSectionName(const std::string& sectionName) { - sectionName_ = sectionName; - } - - private: - - bool isEndSection(const std::string& line); - virtual void parseLine(ForceField& ff, const std::string& line, int lineNo) = 0; - std::string sectionName_; - }; - - } #endif //IO_SECTIONPARSER_HPP