X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Console%2FScopedDirectory.hh;h=c226b2e94101eafda536ff4b0aafb07c6b32586a;hb=01e02e262ea327678dfa0c3f7a66d50ed91924d5;hp=e86dc59defe2e98c3181973e803717ceff89fbee;hpb=748363b235c4651b3992cc291a95dc2e18e45724;p=senf.git diff --git a/Console/ScopedDirectory.hh b/Console/ScopedDirectory.hh index e86dc59..c226b2e 100644 --- a/Console/ScopedDirectory.hh +++ b/Console/ScopedDirectory.hh @@ -50,13 +50,15 @@ namespace console { * static_cast(0), * static_cast(0), * static_cast(0), - * static_cast(0)) ) result_type; + * static_cast(0)) ) base_type; + typedef typename senf::remove_cvref::type value_type; - typedef typename boost::remove_reference::type NodeType; + typedef typename value_type::node_type NodeType; + typedef typename value_type::return_type result_type; /// Internal struct Creator { - static NodeType & create(DirectoryNode & node, Owner & owner, + static result_type create(DirectoryNode & node, Owner & owner, std::string const & name, Object const & ob); }; }; @@ -146,8 +148,8 @@ namespace console { /////////////////////////////////////////////////////////////////////////// template - typename OwnerNodeCreateTraits::NodeType & add(std::string const & name, - Object const & ob); + typename OwnerNodeCreateTraits::result_type add(std::string const & name, + Object const & ob); ///< Create new child node /**< Adds a new child node to the (proxied) DirectoryNode. How the node is added is configured @@ -166,8 +168,8 @@ namespace console { { public: template - typename NodeCreateTraits::NodeType & add(std::string const & name, - Object const & ob); + typename NodeCreateTraits::result_type add(std::string const & name, + Object const & ob); }; #ifndef DOXYGEN