Part of twisted.python.filepath View Source View In Hierarchy
Known subclasses: twisted.python.filepath.FilePath, twisted.python.zippath.ZipPath
Method | getContent | Undocumented |
Method | children | Undocumented |
Method | walk | Yield myself, then each of my children, and each of those children's |
Method | sibling | Undocumented |
Method | segmentsFrom | Return a list of segments between a child and its ancestor. |
Returns | a generator yielding FilePath-like objects. |
Return a list of segments between a child and its ancestor.
For example, in the case of a path X representing /a/b/c/d and a path Y representing /a/b,Y.segmentsFrom(X)
will return
['c', 'd']
.
Parameters | ancestor | an instance of the same class as self, ostensibly an ancestor of self. |
Returns | a list of strs | |
Raises | ValueError if the 'ancestor' parameter is not actually an ancestor, i.e. a path for /x/y/z is passed as an ancestor for /a/b/c/d. |