Functions | |
def | indent |
Variables | |
string | data |
int | headerwidth = 46 |
tuple | labels = ('First Name','Last Name','Age','Position') |
list | lumidata |
list | lumifooter = [('%-*s'%(24,'189'),'%-*s'%(10,'17.89'),'%-*s'%(10,'16.1'),'%-*s'%(20,'3.47'))] |
list | lumiheader = [('%-*s'%(30,'Lumi Sections'),'%-*s'%(46,'Luminosity'))] |
list | rows = [row.strip().split(',') for row in data.splitlines()] |
int | width = 10 |
def tablePrinter.indent | ( | rows, | |
hasHeader = False , |
|||
headerChar = '-' , |
|||
delim = ' | ' , |
|||
justify = 'center' , |
|||
separateRows = False , |
|||
prefix = '' , |
|||
postfix = '' , |
|||
wrapfunc = lambda x:x |
|||
) |
Indents a table by column. - rows: A sequence of sequences of items, one sequence per row. - hadHeader: True if the first row consists of the column's names. - headerChar: Character to be used for the row separator line (if hasHeader==True or separateRows==True). - delim: The column delimiter. - justify: Determines how are data justified in their column. Valid values are 'left','right','center'. - separateRows: True if rows are to be separated by a line of 'headerChar's. - prefix: A string prepended to each printed row. - postfix: A string appended to each printed row. - wrapfunc: A function f(text) for wrapping text; each element in the table is first wrapped by this function.
Definition at line 8 of file tablePrinter.py.
References python.multivaluedict.map(), bookConverter.max, split, and archive.zip.
string tablePrinter.data |
Definition at line 51 of file tablePrinter.py.
int tablePrinter.headerwidth = 46 |
Definition at line 71 of file tablePrinter.py.
tuple tablePrinter.labels = ('First Name','Last Name','Age','Position') |
Definition at line 50 of file tablePrinter.py.
list tablePrinter.lumidata |
Definition at line 64 of file tablePrinter.py.
list tablePrinter.lumifooter = [('%-*s'%(24,'189'),'%-*s'%(10,'17.89'),'%-*s'%(10,'16.1'),'%-*s'%(20,'3.47'))] |
Definition at line 73 of file tablePrinter.py.
list tablePrinter.lumiheader = [('%-*s'%(30,'Lumi Sections'),'%-*s'%(46,'Luminosity'))] |
Definition at line 70 of file tablePrinter.py.
Referenced by lumi::Lumi2DB.retrieveData().
Definition at line 54 of file tablePrinter.py.
Referenced by SiPixelRecHitsValid.fillBarrel(), SiPixelRecHitsValid.fillForward(), SiPixelActionExecutor.fillSummary(), pos::PixelCalibConfiguration.PixelCalibConfiguration(), presort(), presort_egamma(), MuonResidualsFitter.read(), FWTEveViewer.SaveJpg(), FWTEveViewer.SavePng(), SiPixelCalibConfiguration.SiPixelCalibConfiguration(), and MuonResidualsFitter.write().
int tablePrinter.width = 10 |
Definition at line 59 of file tablePrinter.py.