[PATCH 31 of 41] basefilectx: move path from filectx
Sean Farley
sean.michael.farley at gmail.com
Mon Aug 12 11:27:27 CDT 2013
# HG changeset patch
# User Sean Farley <sean.michael.farley at gmail.com>
# Date 1376279778 18000
# Sun Aug 11 22:56:18 2013 -0500
# Node ID 2eacec85b30a273d5f1bbe2f322feb28273b6af0
# Parent fd088bd643f300091ca45961c81b88bafdf162eb
basefilectx: move path from filectx
diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -512,10 +512,13 @@
def manifest(self):
return self._changectx.manifest()
def changectx(self):
return self._changectx
+ def path(self):
+ return self._path
+
class filectx(basefilectx):
"""A filecontext object makes access to data related to a particular
filerevision convenient."""
def __init__(self, repo, path, changeid=None, fileid=None,
filelog=None, changectx=None):
@@ -569,12 +572,10 @@
return filectx(self._repo, self._path, fileid=fileid,
filelog=self._filelog)
def data(self):
return self._filelog.read(self._filenode)
- def path(self):
- return self._path
def size(self):
return self._filelog.size(self._filerev)
def isbinary(self):
try:
More information about the Mercurial-devel
mailing list