mercurial/context.py
changeset 21466 3b1ec3d4ece6
parent 21398 ed608a544719
child 21468 870ddcf24291
equal deleted inserted replaced
21465:2edb8648c500 21466:3b1ec3d4ece6
    60         return self.filectx(key)
    60         return self.filectx(key)
    61 
    61 
    62     def __iter__(self):
    62     def __iter__(self):
    63         for f in sorted(self._manifest):
    63         for f in sorted(self._manifest):
    64             yield f
    64             yield f
       
    65 
       
    66     def _manifestmatches(self, match, s):
       
    67         """generate a new manifest filtered by the match argument
       
    68 
       
    69         This method is for internal use only and mainly exists to provide an
       
    70         object oriented way for other contexts to customize the manifest
       
    71         generation.
       
    72         """
       
    73         mf = self.manifest().copy()
       
    74         if match.always():
       
    75             return mf
       
    76         for fn in mf.keys():
       
    77             if not match(fn):
       
    78                 del mf[fn]
       
    79         return mf
    65 
    80 
    66     @propertycache
    81     @propertycache
    67     def substate(self):
    82     def substate(self):
    68         return subrepo.state(self, self._repo.ui)
    83         return subrepo.state(self, self._repo.ui)
    69 
    84