diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2011-12-13 12:37:00 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2011-12-13 12:50:34 +0100 |
commit | bcdea3b379637a98e5bbc304078149ca6c2b6e03 (patch) | |
tree | a3803df980a54ab1a03c740c3114a54ca7d12f27 /configmgr/source/writemodfile.cxx | |
parent | ddf1cf333174777e7923aa0d6126daf2c8645fed (diff) |
Simplified, type-safe C++ configuration access.
* New offapi com.sun.star.configuration entities to access the complete
configuration read-only or read/write...
* ...configmgr adapted to support those new services/singletons...
* ...new unotools/configuration.hxx is the type-safe C++ plumbing on top of
that...
* ...officecfg now generates C++ headers to access all the properties and sets
given in the .xcs files...
* ...and svl's asiancfg.cxx exemplarily makes use of the new
officecfg/Office/Common.hxx to access the configuration.
* There is still TODOs: For one, see those listed in
officecfg/registry/cppheader.xsl. For another, at least a notification
mechanism for the new read-only configuration access and the C++ wrapper is
missing.
Diffstat (limited to 'configmgr/source/writemodfile.cxx')
-rw-r--r-- | configmgr/source/writemodfile.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/configmgr/source/writemodfile.cxx b/configmgr/source/writemodfile.cxx index 1bae01ab88c5..eb896fffbf34 100644 --- a/configmgr/source/writemodfile.cxx +++ b/configmgr/source/writemodfile.cxx @@ -395,7 +395,7 @@ void writeNode( writeData(handle, RTL_CONSTASCII_STRINGPARAM("<prop oor:name=\"")); writeAttributeValue(handle, name); writeData(handle, RTL_CONSTASCII_STRINGPARAM("\" oor:op=\"fuse\">")); - for (NodeMap::iterator i(node->getMembers().begin()); + for (NodeMap::const_iterator i(node->getMembers().begin()); i != node->getMembers().end(); ++i) { writeNode(components, handle, node, i->first, i->second); @@ -443,13 +443,16 @@ void writeNode( handle, RTL_CONSTASCII_STRINGPARAM("\" oor:op=\"replace")); } writeData(handle, RTL_CONSTASCII_STRINGPARAM("\">")); - for (NodeMap::iterator i(node->getMembers().begin()); + for (NodeMap::const_iterator i(node->getMembers().begin()); i != node->getMembers().end(); ++i) { writeNode(components, handle, node, i->first, i->second); } writeData(handle, RTL_CONSTASCII_STRINGPARAM("</node>")); break; + case Node::KIND_ROOT: + assert(false); // this cannot happen + break; } } |