| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

RootIOTest::OutputFrobicator::OutFrob Class Reference

Inheritance diagram for RootIOTest::OutputFrobicator::OutFrob:
[legend]
Collaboration diagram for RootIOTest::OutputFrobicator::OutFrob:
[legend]
List of all members.

Public Member Functions

def __init__
def initialize
def execute

Public Attributes

 count
 rio
 riop

Detailed Description

An algorithm that will change the RootIOCnvSvc's output file map.

Definition at line 10 of file OutputFrobicator.py.


Member Function Documentation

def RootIOTest::OutputFrobicator::OutFrob::__init__ (   self,
  name = "OutFrob" 
)

Definition at line 12 of file OutputFrobicator.py.

00014                                      :
00015         GaudiAlgo.__init__(self,name)
00016         self.count = 0
        return

def RootIOTest::OutputFrobicator::OutFrob::initialize (   self  ) 

Definition at line 17 of file OutputFrobicator.py.

00019                         :
00020         sc = GaudiAlgo.initialize(self)
00021         if sc.isFailure(): 
00022             print 'Failed to initialize GaudiAlgo base class'
00023             return sc
00024         self.rio = self.svc('IRootIOSvc','RootIOCnvSvc')
00025         if not self.rio:
00026             print 'Failed to get RootIOCnvSvc, bogus!'
00027             return FAILURE
00028         self.riop = Bindings.iProperty('RootIOCnvSvc',self.rio)
        return SUCCESS

def RootIOTest::OutputFrobicator::OutFrob::execute (   self  ) 

Definition at line 29 of file OutputFrobicator.py.

00031                      :
00032         self.count += 1 
00033         print self.count
00034 
00035         outstreams = self.riop.OutputStreams
00036         for k,v in outstreams.iteritems():
00037             print '\t%s --> %s'%(k,v)
00038             basenum,ext = os.path.splitext(v)
00039             base,num = basenum.split("_")
00040             newname = '%s_%03d%s'%(base,self.count,ext)
00041             print 'Changing output stream "%s" output file from "%s" to "%s"'%(k,v,newname)
00042             self.rio.associateOutput(newname,k)
00043             continue
00044 
00045         #for k,v in self.riop.properties().iteritems():
00046         #    print '\t"%s" --> (%s)%s [%s]'%(k,v.ptype(),v.value(),v.documentation())
00047 
00048         return SUCCESS        


Member Data Documentation

RootIOTest::OutputFrobicator::OutFrob::count

Definition at line 14 of file OutputFrobicator.py.

RootIOTest::OutputFrobicator::OutFrob::rio

Definition at line 22 of file OutputFrobicator.py.

RootIOTest::OutputFrobicator::OutFrob::riop

Definition at line 26 of file OutputFrobicator.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Mon Apr 11 20:58:42 2011 for RootIOTest by doxygen 1.4.7