Introduce tostring function
This commit is contained in:
parent
82afb34f7a
commit
0f53a02947
2 changed files with 7 additions and 2 deletions
|
|
@ -54,3 +54,8 @@ class Path(object):
|
|||
|
||||
def get(self):
|
||||
return copy.copy(self._working_path)
|
||||
|
||||
def tostring(self):
|
||||
escape = lambda s: s.replace('/', '\/')
|
||||
path = map(escape, self._working_path)
|
||||
return '/' + '/'.join(path)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue