twisted.python.logfile.BaseLogFile

Package twisted :: Package python :: Module logfile :: Class BaseLogFile |
[frames | no frames]

## Class BaseLogFile

Known Subclasses:
  `DailyLogFile`, `LogFile`

The base class for a log file that can be rotated.

Method Summary
| `__init__(self, name, directory, defaultMode)`
| `__getstate__(self)`
| `__setstate__(self, state)`
| ``_openFile`(self)` Open the log file.
| ``close`(self)` Close the file.
| ``flush`(self)` Flush the file.
| ``getCurrentLog`(self)` Return a LogReader for the current log file.
| ``shouldRotate`(self)` Override with a method to that returns true if the log should be rotated
| ``write`(self, data)` Write some data to the file.

Class Variable Summary
`list` | `synchronized` = `['write', 'rotate']`

Method Details

### _openFile(self) Open the log file.

### close(self) Close the file. The file cannot be used once it has been closed.

### flush(self) Flush the file.

### getCurrentLog(self) Return a LogReader for the current log file.

### shouldRotate(self) Override with a method to that returns true if the log should be rotated

### write(self, data) Write some data to the file.

Class Variable Details

    ### synchronized Type: `list` Value:
        ['write', 'rotate']

Generated by Epydoc 2.0 on Sat May 15 20:08:31 2004 | http://epydoc.sf.net