Package libconfix :: Package core :: Package filesys :: Module vfs_directory :: Class VFSDirectory
[show private | hide private]
[frames | no frames]

Type VFSDirectory

object --+    
         |    
  VFSEntry --+
             |
            VFSDirectory

Known Subclasses:
Directory, OverlayDirectory

A directory node in the virtual filesystem game. As such it
provides the necessary parent/child relations.

Note that, for now, derived classes are required to use this
implementation of these relations. It is not currently possible
for derived classes to provide their own.

Method Summary
  __init__(self)
  add(self, name, entry)
Add a directory entry under the specified name.
  entries(self)
Return list of all the entries of a directory, as [(name, entry)].
  entryname(self, entry)
Return the name under which the given entry has been added.
  find(self, path)
Starting at this object, find a descendant at path.
  get(self, name)
Get a directory entry by name.
  set_filesystem(self, filesystem)
Set my and my children's filesystem.
    Inherited from VFSEntry
  abspath(self)
Return the absolute path to this object.
  del_property(self, name)
  filesystem(self)
  get_property(self, name)
  is_persistent(self)
Does this entry correspond to a physical OS file system entry that can be accessed directly? This information is quite useful under certain circumstances; for example when it is better to pass the file to python's execfile(), rather than exec'ing it from memory (execfile() gives better error messages).
  name(self)
  parent(self)
  relpath(self, from_dir)
Return the relative path from dir to this object.
  set_parent(self, parent)
  set_property(self, name, value)
  sync(self)
Write back to the backing storage, whatever this means.
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name...
  __getattribute__(...)
x.__getattribute__('name') <==> x.name...
  __hash__(x)
x.__hash__() <==> hash(x)...
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T...
  __reduce__(...)
helper for pickle...
  __reduce_ex__(...)
helper for pickle...
  __repr__(x)
x.__repr__() <==> repr(x)...
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value...
  __str__(x)
x.__str__() <==> str(x)...

Class Variable Summary
classobj AlreadyMounted = libconfix.core.filesys.vfs_directory.AlreadyMounted

Method Details

add(self, name, entry)

Add a directory entry under the specified name. Returns the
added entry (for convenience).

entries(self)

Return list of all the entries of a directory, as [(name,
entry)].

entryname(self, entry)

Return the name under which the given entry has been added.

find(self, path)

Starting at this object, find a descendant at path. If none is
found, return None.

get(self, name)

Get a directory entry by name. Return None if not found.

set_filesystem(self, filesystem)

Set my and my children's filesystem.
Overrides:
libconfix.core.filesys.vfs_entry.VFSEntry.set_filesystem

Generated by Epydoc 2.1 on Fri Nov 23 16:56:34 2007 http://epydoc.sf.net