def loads(self, requirements_text):
        lines = re.findall(Requirement.spec_regex,
                           requirements_text,
                           re.MULTILINE)
        for line in lines:
            self.add(Requirement(line[0], "".join(line[1:])))
def matchfn(self, f):
        # XXX: is_dir is set to True here for performance.
        # It should be set to whether "f" is actually a directory or not.
        return self._matcher.match_relative(f, True)