From 797d373bd7403455d249ee9ce9725089a93c8754 Mon Sep 17 00:00:00 2001 From: An-Cheng Huang Date: Wed, 25 Aug 2010 17:20:21 -0700 Subject: remove sorting from unsorted API calls --- src/cstore/cstore.hpp | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'src/cstore/cstore.hpp') diff --git a/src/cstore/cstore.hpp b/src/cstore/cstore.hpp index 5da07fd..e09c015 100644 --- a/src/cstore/cstore.hpp +++ b/src/cstore/cstore.hpp @@ -192,12 +192,13 @@ public: vector& dvals); void cfgPathGetChildNodesStatus(const vector& path_comps, MapT& cmap) { - vector dummy; - cfgPathGetChildNodesStatus(path_comps, cmap, dummy); + get_child_nodes_status(path_comps, cmap, NULL); }; void cfgPathGetChildNodesStatus(const vector& path_comps, MapT& cmap, - vector& sorted_keys); + vector& sorted_keys) { + get_child_nodes_status(path_comps, cmap, &sorted_keys); + }; /* observers for "effective config". can be used both during a config * session and outside a config session. more detailed information @@ -256,12 +257,13 @@ public: bool include_deactivated = true); void cfgPathGetChildNodesStatusDA(const vector& path_comps, MapT& cmap) { - vector dummy; - cfgPathGetChildNodesStatusDA(path_comps, cmap, dummy); + get_child_nodes_status_da(path_comps, cmap, NULL); }; void cfgPathGetChildNodesStatusDA(const vector& path_comps, MapT& cmap, - vector& sorted_keys); + vector& sorted_keys) { + get_child_nodes_status_da(path_comps, cmap, &sorted_keys); + }; /* these are internal API functions and operate on current cfg and @@ -423,6 +425,12 @@ private: bool cfg_path_exists(const vector& path_comps, bool active_cfg, bool include_deactivated); bool set_cfg_path(const vector& path_comps, bool output); + void get_child_nodes_status(const vector& path_comps, + Cstore::MapT& cmap, + vector *sorted_keys); + void get_child_nodes_status_da(const vector& path_comps, + Cstore::MapT& cmap, + vector *sorted_keys); // these operate on current work path (or active with "active_cfg") bool remove_tag(); -- cgit v1.2.3