Provide CapFactory::parse templating the Resolvable::Kind.
authorMichael Andres <ma@suse.de>
Fri, 3 Aug 2007 11:40:44 +0000 (11:40 +0000)
committerMichael Andres <ma@suse.de>
Fri, 3 Aug 2007 11:40:44 +0000 (11:40 +0000)
zypp/CapFactory.h

index 622dc06..9f608e6 100644 (file)
@@ -60,7 +60,10 @@ namespace zypp
     */
     Capability parse( const Resolvable::Kind & refers_r,
                       const std::string & strval_r ) const;
-
+    /** \overload Templating the \c Resolvable::Kind. */
+    template<class _Res>
+    Capability parse( const std::string & strval_r ) const
+    { return parse( ResTraits<_Res>::kind, strval_r ); }
 
     /** Parse Capability providing Resolvable::Kind, name, Rel and Edition as strings.
      * \throw EXCEPTION on parse error.