Back to index

python-biopython  1.60
Public Member Functions | Public Attributes
BioSQL.BioSeqDatabase.Adaptor Class Reference

List of all members.

Public Member Functions

def __init__
def last_id
def autocommit
def commit
def rollback
def close
def fetch_dbid_by_dbname

Public Attributes


Detailed Description

Definition at line 266 of file

Constructor & Destructor Documentation

def BioSQL.BioSeqDatabase.Adaptor.__init__ (   self,

Definition at line 267 of file

00268     def __init__(self, conn, dbutils):
00269         self.conn = conn
00270         self.cursor = conn.cursor()
00271         self.dbutils = dbutils

Member Function Documentation

def BioSQL.BioSeqDatabase.Adaptor.autocommit (   self,
  y = True 
Set the autocommit mode. True values enable; False value disable.

Definition at line 275 of file

00276     def autocommit(self, y=True):
00277         """Set the autocommit mode. True values enable; False value disable."""
00278         return self.dbutils.autocommit(self.conn, y)

Close the connection. No further activity possible.

Definition at line 287 of file

00288     def close(self):
00289         """Close the connection. No further activity possible."""
00290         return self.conn.close()

Here is the caller graph for this function:

Commits the current transaction.

Definition at line 279 of file

00280     def commit(self):
00281         """Commits the current transaction."""
00282         return self.conn.commit()

Definition at line 291 of file

00292     def fetch_dbid_by_dbname(self, dbname):
00293         self.execute(
00294             r"select biodatabase_id from biodatabase where name = %s",
00295             (dbname,))
00296         rv = self.cursor.fetchall()
00297         if not rv:
00298             raise KeyError("Cannot find biodatabase with name %r" % dbname)
        # Cannot happen (UK)

Here is the call graph for this function:

def BioSQL.BioSeqDatabase.Adaptor.last_id (   self,

Definition at line 272 of file

00273     def last_id(self, table):
00274         return self.dbutils.last_id(self.cursor, table)

Rolls backs the current transaction.

Definition at line 283 of file

00284     def rollback(self):
00285         """Rolls backs the current transaction."""
00286         return self.conn.rollback()

Member Data Documentation

Definition at line 268 of file

Definition at line 269 of file

Definition at line 270 of file

The documentation for this class was generated from the following file: