Package PyFoam :: Package Basics :: Module RunDatabase :: Class RunDatabase
[hide private]
[frames] | no frames]

Class RunDatabase

source code


Database with information about runs. To be queried etc

Instance Methods [hide private]
 
__adaptDatabase(self, data)
Make sure that all the required columns and tables are there
source code
 
__addColumnsToTable(self, table, data) source code
 
__addContent(self, table, data) source code
 
__flattenDict(self, oData, prefix='') source code
 
__getColumns(self, tablename) source code
 
__init__(self, name, create=False, verbose=False)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
add(self, data)
Add a dictionary with data to the database
source code
 
dumpToCSV(self, name, selection=None)
Dump the contents of the database to a csv-file
source code
 
initDatabase(self, name)
Create a new database file
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  separator = '//'
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, name, create=False, verbose=False)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • name - name of the file
  • create - should the database be created if it does not exist
Overrides: object.__init__

dumpToCSV(self, name, selection=None)

source code 

Dump the contents of the database to a csv-file

Parameters:
  • name - the CSV-file
  • selection - list of regular expressions. Only data entries fitting those will be added to the CSV-file (except for the basic run). If unset all data will be written