Example #1
0
 def __init__(self, stream, cols=None, number_fmt='%8.4f', col_width=8,
              col_sep='  ', output_block=False, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = stream
     if not number_fmt.startswith('%'):
         number_fmt = '%%s' % number_fmt
     self._number_fmt = number_fmt
     self._col_sep = col_sep
     self._col_width = col_width
     if operator.isSequenceType(cols) and \
             not isinstance(cols, (str, unicode)):
         cols = CaselessList(cols)
     elif operator.isNumberType(cols):
         cols = cols
     else:
         cols = None
     self._columns = cols
     self._output_block = output_block
Example #2
0
 def __init__(self, stream, cols=None, number_fmt='%8.4f', col_width=8,
              col_sep='  ', output_block=False, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = weakref.ref(stream)
     if not number_fmt.startswith('%'):
         number_fmt = '%%s' % number_fmt
     self._number_fmt = number_fmt
     self._col_sep = col_sep
     self._col_width = col_width
     if isinstance(cols, collections.Sequence) and \
             not isinstance(cols, str):
         cols = CaselessList(cols)
     elif isinstance(cols, numbers.Number):
         cols = cols
     else:
         cols = None
     self._columns = cols
     self._output_block = output_block
Example #3
0
 def __init__(self, stream, cols=None, number_fmt='%8.4f', col_width=8,
              col_sep='  ', output_block=False, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = stream
     if not number_fmt.startswith('%'):
         number_fmt = '%%s' % number_fmt
     self._number_fmt = number_fmt
     self._col_sep = col_sep
     self._col_width = col_width
     if operator.isSequenceType(cols) and \
             not isinstance(cols, (str, unicode)):
         cols = CaselessList(cols)
     elif operator.isNumberType(cols):
         cols = cols
     else:
         cols = None
     self._columns = cols
     self._output_block = output_block
Example #4
0
 def __init__(self, **pars):
     DataRecorder.__init__(self, **pars)
     self.filename = None
     self.fd = None
Example #5
0
 def __init__(self, stream, cols=None, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = stream
     self._codec = CodecFactory().getCodec('json')
Example #6
0
 def __init__(self, stream, cols=None, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = weakref.ref(stream)
Example #7
0
 def __init__(self, stream, cols=None, **pars):
     DataRecorder.__init__(self, **pars)
     self._stream = stream
     self._codec = CodecFactory().getCodec('json')
Example #8
0
 def __init__(self, **pars):
     DataRecorder.__init__(self, **pars)
Example #9
0
 def __init__(self, **pars):
     DataRecorder.__init__(self, **pars)
     self.filename = None
     self.fd = None
Example #10
0
 def __init__(self, **pars):
     DataRecorder.__init__(self, **pars)