##// END OF EJS Templates
localrepo: subclass the new `ilocalrepositoryfilestorage` Protocol class...
Matt Harbison -
r53387:ef119f91 default
parent child Browse files
Show More
@@ -86,7 +86,6 from mercurial import (
86 )
86 )
87 from mercurial.interfaces import (
87 from mercurial.interfaces import (
88 repository,
88 repository,
89 util as interfaceutil,
90 )
89 )
91 from mercurial.utils import (
90 from mercurial.utils import (
92 hashutil,
91 hashutil,
@@ -1282,8 +1281,7 def newreporequirements(orig, ui, create
1282 return requirements
1281 return requirements
1283
1282
1284
1283
1285 @interfaceutil.implementer(repository.ilocalrepositoryfilestorage)
1284 class sqlitefilestorage(repository.ilocalrepositoryfilestorage):
1286 class sqlitefilestorage:
1287 """Repository file storage backed by SQLite."""
1285 """Repository file storage backed by SQLite."""
1288
1286
1289 def file(self, path):
1287 def file(self, path):
@@ -1658,6 +1658,7 class ilocalrepositoryfilestorage(Protoc
1658 tracked file path.
1658 tracked file path.
1659 """
1659 """
1660
1660
1661 @abc.abstractmethod
1661 def file(self, f):
1662 def file(self, f):
1662 """Obtain a filelog for a tracked path.
1663 """Obtain a filelog for a tracked path.
1663
1664
@@ -1241,7 +1241,7 def makemain(**kwargs):
1241 return localrepository
1241 return localrepository
1242
1242
1243
1243
1244 class revlogfilestorage: # (repository.ilocalrepositoryfilestorage)
1244 class revlogfilestorage(repository.ilocalrepositoryfilestorage):
1245 """File storage when using revlogs."""
1245 """File storage when using revlogs."""
1246
1246
1247 def file(self, path):
1247 def file(self, path):
@@ -1256,7 +1256,7 class revlogfilestorage: # (repository.
1256 return filelog.filelog(self.svfs, path, try_split=try_split)
1256 return filelog.filelog(self.svfs, path, try_split=try_split)
1257
1257
1258
1258
1259 class revlognarrowfilestorage: # (repository.ilocalrepositoryfilestorage)
1259 class revlognarrowfilestorage(repository.ilocalrepositoryfilestorage):
1260 """File storage when using revlogs and narrow files."""
1260 """File storage when using revlogs and narrow files."""
1261
1261
1262 def file(self, path):
1262 def file(self, path):
General Comments 0
You need to be logged in to leave comments. Login now