Text-based log object. More...
Public Member Functions | |
def | __init__ |
def | __str__ |
def | write |
Private Member Functions | |
def | _close |
def | _get_cur_pos |
def | _open |
Private Attributes | |
_file | |
_fn | |
_is_open | |
_mode |
Text-based log object.
It only supports writing log files. It relies on the data types having suitable __repr__ methods.
Definition at line 32 of file text_log.py.
def rtshell.text_log.TextLog.__init__ | ( | self, | |
filename = '' , |
|||
args, | |||
kwargs | |||
) |
Definition at line 33 of file text_log.py.
def rtshell.text_log.TextLog.__str__ | ( | self | ) |
Reimplemented from rtshell.ilog.Log.
Definition at line 38 of file text_log.py.
def rtshell.text_log.TextLog._close | ( | self | ) | [private] |
Reimplemented from rtshell.ilog.Log.
Definition at line 50 of file text_log.py.
def rtshell.text_log.TextLog._get_cur_pos | ( | self | ) | [private] |
Get the current position in the log. Should be implemented by implementation objects. Called by the @ref position property.
Reimplemented from rtshell.ilog.Log.
Definition at line 57 of file text_log.py.
def rtshell.text_log.TextLog._open | ( | self | ) | [private] |
Reimplemented from rtshell.ilog.Log.
Definition at line 65 of file text_log.py.
def rtshell.text_log.TextLog.write | ( | self, | |
timestamp, | |||
data | |||
) |
Writes an entry to the log. The timestamp is necessary to allow reading back data at the same rate as it was recorded. It must be an object that supports comparisons using <, <=, =, >= and >. ilog.EntryTS provides a suitable object.
Reimplemented from rtshell.ilog.Log.
Definition at line 45 of file text_log.py.
rtshell::text_log.TextLog::_file [private] |
Definition at line 65 of file text_log.py.
rtshell::text_log.TextLog::_fn [private] |
Definition at line 33 of file text_log.py.
rtshell::text_log.TextLog::_is_open [private] |
Definition at line 33 of file text_log.py.
rtshell::text_log.TextLog::_mode [private] |
Reimplemented from rtshell.ilog.Log.
Definition at line 65 of file text_log.py.