INTRODUCTION Overview Download and Install Quick Start Documentation Publications NONFRAMEWORK CODE Driver Interfaces Drivers Libraries Utilities FRAMEWORK CODE Interfaces Components Libraries Utilities Full Software Listings DEVELOPER Tutorials Examples Dev Guide Dashboard PEOPLE Contributors Users Project Download Mailing lists
|
xmlattributeshelper.h00001 // ********************************************************************** 00002 // 00003 // Copyright (c) 2003-2007 ZeroC, Inc. All rights reserved. 00004 // 00005 // This copy of Ice is licensed to you under the terms described in the 00006 // ICE_LICENSE file included in this distribution. 00007 // 00008 // ********************************************************************** 00009 00010 // 00011 // This code is extracted from IceGrid 00012 // 00013 00014 #ifndef ICE_XML_ATTRIBUTES_HELPER_H 00015 #define ICE_XML_ATTRIBUTES_HELPER_H 00016 00017 // #include <Ice/Logger.h> 00018 #include <IceXML/Parser.h> 00019 #include <set> 00020 00021 namespace orcaicexml 00022 { 00023 00025 class XmlAttributesHelper 00026 { 00027 public: 00029 XmlAttributesHelper(const IceXML::Attributes&, const std::string&, int); 00030 // XmlAttributesHelper(const IceXML::Attributes&, const Ice::LoggerPtr&, const std::string&, int); 00031 00033 void checkUnknownAttributes(); 00035 bool contains(const std::string&) const; 00037 std::map<std::string, std::string> asMap() const; 00038 00040 bool asBool(const std::string&) const; 00042 bool asBool(const std::string&, bool) const; 00043 00045 std::string operator()(const std::string& attr) const; 00047 std::string operator()(const std::string& attr, const std::string& def) const; 00048 00049 private: 00050 00051 const IceXML::Attributes& _attributes; 00052 // const Ice::LoggerPtr _logger; 00053 const std::string _filename; 00054 const int _line; 00055 00056 mutable std::set<std::string> _used; 00057 }; 00058 00059 }; // namespace 00060 00061 #endif |
Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)