Beispiel #1
0
    def __init__(self,**args):
        dict_like.__init__(self,**args)
        try:
            self.db_file=args['db_file']
        except KeyError:
            a=RnaseqGlobals.conf_value('rnaseq', 'root_dir')
            b=RnaseqGlobals.conf_value('db','db_name')
            if (a==None or b==None):
                raise ProgrammerGoof("RnaseqGlobals not initialized")
            self.db_file=os.path.join(a,b)

        self.connect()                  # should this really be called in the constructor?
        self.cursor=self.dbh.cursor()
        assert(self.columns)
Beispiel #2
0
 def __init__(self,**args):
     self.attrs.update(args)
     dict_like.__init__(self,**args)