+ def locate_varname (self, varname):
+ """
+ Locates category and variable from a variable's (shell) name
+
+ Returns:
+ (variable, category) when found
+ (None, None) otherwise
+ """
+
+ for (category_id, (category, variables)) in self._variables.iteritems():
+ for variable in variables.values():
+ (id, name, value, comments) = self._sanitize_variable(category_id, variable)
+ if (id == varname):
+ return (category,variable)
+ return (None,None)
+