Module wmii :: Class P9_wmiir
[show private | hide private]
[frames | no frames]

Type P9_wmiir

object --+
         |
        P9_wmiir


Convenience wrapper to wmii's P9 interface

This version is implemented through pipes to wmiir (ugh!)

Fortunately, we're using P9_py instead, which is pure-python
Method Summary
  __init__(self, address)
  create(self, path, buf)
writes a string to a newly created file
  openFeed(self, path)
opens a feed at path (ie, a file which gives a continuous stream of lines), and returns a function which returns the next line from the feed
  read(self, path)
Reads the entire contents of a file
  readdir(self, path)
Reads a directory, returns list of filenames
  readList(self, path)
reads a file, returns its lines as a list
  readRules(self, path)
Reads a set of rules from a file, where the rules come in in the form 'foo -> bar', and returns this as a list of tuples
  remove(self, path)
Attempts to remove file
  write(self, path, buf, doCreate)
writes a string to file
  writeList(self, path, items)
writes the items of a list to file, one on each line
  writeRules(self, path, rules)
writes a sequence of rules, where each rule is a sequence of 2 items.
    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)

Method Details

create(self, path, buf)

writes a string to a newly created file

openFeed(self, path)

opens a feed at path (ie, a file which gives a continuous stream of lines), and returns a function which returns the next line from the feed

read(self, path)

Reads the entire contents of a file

readdir(self, path)

Reads a directory, returns list of filenames

readList(self, path)

reads a file, returns its lines as a list

readRules(self, path)

Reads a set of rules from a file, where the rules come in in the form 'foo -> bar', and returns this as a list of tuples

remove(self, path)

Attempts to remove file

write(self, path, buf, doCreate=False)

writes a string to file

writeList(self, path, items)

writes the items of a list to file, one on each line

writeRules(self, path, rules)

writes a sequence of rules, where each rule is a sequence of 2 items. Format written is 'foo -> bar'

Generated by Epydoc 2.1 on Tue Jun 12 22:49:29 2007 http://epydoc.sf.net