• Main Page
  • Namespaces
  • Classes
  • Files
  • File List

/home/mark/model/software/ScrumPy/ScrumPy/Bioinf/PyoCyc/Enzrxn.py

00001 
00002 import Base
00003 import Tags
00004 
00005 DefaultFile = "enzrxns.dat"
00006 
00007 
00008 class Record(Base.Record):
00009     ParentFields = [Tags.Enz,Tags.Cats]
00010     ChildFields =[Tags.Reac]
00011     RecordClass = "Enzyme reaction"
00012     def __init__(self, id,**kwargs):
00013         Base.Record.__init__(self, id,**kwargs)
00014 
00015   
00016 
00017 class DB(Base.DB):
00018     def __init__(self, path=Base.DefaultPath, file=DefaultFile, RecClass=Record, **kwargs):
00019         Base.DB.__init__(
00020             self,
00021             path,
00022             file,
00023             RecClass=Record,
00024             **kwargs
00025         )
00026 
00027     def Reaction(self, k):
00028         rv = []
00029         for r in self[k][Tags.Reac]:
00030             rv.append(self.Org.Reactions[r])
00031         return rv
00032 
00033     
00034 
00035 
00036         
00037         
00038     
00039     

Generated on Tue Sep 4 2012 15:38:01 for ScrumPy by  doxygen 1.7.1