class twisted.python.filepath.AbstractFilePath: (source)
|Method||getContent||Retrieve the contents of the file at this path.|
|Method||parents||Retrieve an iterator of all the ancestors of this path.|
|Method||children||List the children of this path object.|
|Method||walk||Yield myself, then each of my children, and each of those children's children in turn.|
|Method||descendant||Retrieve a child or child's child of this path.|
|Method||segmentsFrom||Return a list of segments between a child and its ancestor.|
|Method||__hash__||Hash the same as another
|Method||getmtime||Deprecated. Use getModificationTime instead.|
|Method||getatime||Deprecated. Use getAccessTime instead.|
|Method||getctime||Deprecated. Use getStatusChangeTime instead.|
Retrieve the contents of the file at this path.
|Returns||the contents of the file (type: |
Retrieve an iterator of all the ancestors of this path.
|Returns||an iterator of all the ancestors of this path, from the most recent (its immediate parent) to the root of its filesystem.|
List the children of this path object.
|Returns||an iterable of all currently-existing children of this object.|
|Raises||OSError||If an error occurs while listing the directory. If the error is 'serious', meaning that the operation failed due to an access violation, exhaustion of some kind of resource (file descriptors or memory), OSError or a platform-specific variant will be raised.|
|UnlistableError||If the inability to list the directory is due to this path not existing or not being a directory, the more specific OSError subclass |
Yield myself, then each of my children, and each of those children's children in turn.
The optional argument
descend is a predicate that takes a FilePath, and determines whether or not that FilePath is traversed/descended into. It will be called with each path for which
descend is not specified, all directories will be traversed (including symbolic links which refer to directories).
|Parameters||descend||A one-argument callable that will return True for FilePaths that should be traversed, False otherwise.|
|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
|Parameters||ancestor||an instance of the same class as self, ostensibly an ancestor of self.|
|Returns||a list of strs|
|Raises||ValueError||If the |
Deprecated. Use getModificationTime instead.
Deprecated. Use getAccessTime instead.
Deprecated. Use getStatusChangeTime instead.