##// END OF EJS Templates
scmutil: rename filecacheentry to filecachesubentry...
Siddharth Agarwal -
r20043:88bd8df0 default
parent child Browse files
Show More
@@ -713,14 +713,14 b' def readrequires(opener, supported):'
713 713 "Mercurial)") % "', '".join(missings))
714 714 return requirements
715 715
716 class filecacheentry(object):
716 class filecachesubentry(object):
717 717 def __init__(self, path, stat):
718 718 self.path = path
719 719 self.cachestat = None
720 720 self._cacheable = None
721 721
722 722 if stat:
723 self.cachestat = filecacheentry.stat(self.path)
723 self.cachestat = filecachesubentry.stat(self.path)
724 724
725 725 if self.cachestat:
726 726 self._cacheable = self.cachestat.cacheable()
@@ -730,7 +730,7 b' class filecacheentry(object):'
730 730
731 731 def refresh(self):
732 732 if self.cacheable():
733 self.cachestat = filecacheentry.stat(self.path)
733 self.cachestat = filecachesubentry.stat(self.path)
734 734
735 735 def cacheable(self):
736 736 if self._cacheable is not None:
@@ -744,7 +744,7 b' class filecacheentry(object):'
744 744 if not self.cacheable():
745 745 return True
746 746
747 newstat = filecacheentry.stat(self.path)
747 newstat = filecachesubentry.stat(self.path)
748 748
749 749 # we may not know if it's cacheable yet, check again now
750 750 if newstat and self._cacheable is None:
@@ -814,7 +814,7 b' class filecache(object):'
814 814
815 815 # We stat -before- creating the object so our cache doesn't lie if
816 816 # a writer modified between the time we read and stat
817 entry = filecacheentry(path, True)
817 entry = filecachesubentry(path, True)
818 818 entry.obj = self.func(obj)
819 819
820 820 obj._filecache[self.name] = entry
@@ -826,7 +826,7 b' class filecache(object):'
826 826 if self.name not in obj._filecache:
827 827 # we add an entry for the missing value because X in __dict__
828 828 # implies X in _filecache
829 ce = filecacheentry(self.join(obj, self.path), False)
829 ce = filecachesubentry(self.join(obj, self.path), False)
830 830 obj._filecache[self.name] = ce
831 831 else:
832 832 ce = obj._filecache[self.name]
General Comments 0
You need to be logged in to leave comments. Login now