| # Gaudi Framework, version v23r0 |

Home |  | Generated: Mon Jan 30 2012

Public Member Functions | Private Attributes | Static Private Attributes

# Configurable::ConfigurableAlgTool Class Reference

Inheritance diagram for Configurable::ConfigurableAlgTool:
[legend]
Collaboration diagram for Configurable::ConfigurableAlgTool:
[legend]

List of all members.

## Public Member Functions
def | __init__
def | getHandle
def | getGaudiType
def | getGaudiHandle
def | getPrintTitle
def | setParent
def | getParent
def | hasParent
def | getJobOptName
def | isPublic
def | isInToolSvc
def | toStringProperty
def | getFullName
## Private Attributes
| _name
| _jobOptName
## Static Private Attributes
dictionary | __slots__

## Detailed Description

Definition at line 1006 of file Configurable.py.

## Constructor & Destructor Documentation

def Configurable::ConfigurableAlgTool::__init__ | ( |  | self,
|  |  | name = `Configurable.DefaultName`
| ) |  |

Reimplemented from Configurable::Configurable.

Definition at line 1010 of file Configurable.py.

    01011                                                          :
    01012         super( ConfigurableAlgTool, self ).__init__( name )
    01013         if '.' not in self._name:
    01014             # Public tools must have ToolSvc as parent
    01015             self._name = "ToolSvc." + self._name
    01016         name = self.getName()
    01017         name = name[ name.find('/')+1 : ]   # strips class, if any
    01018         self._jobOptName = name

## Member Function Documentation

def Configurable::ConfigurableAlgTool::getFullName | ( |  | self ) |

Reimplemented from Configurable::Configurable.

Definition at line 1076 of file Configurable.py.

    01077                             :
    01078         # for Tools, the "full name" means "Type/LocalName",
    01079         # without the names of the parents
    01080         name = self.getName()
    01081         # strip off everything before the last '.'
    01082         name = name[name.rfind('.')+1:]
    01083         return str( self.getType() + '/' + name )
    01084

def Configurable::ConfigurableAlgTool::getGaudiHandle | ( |  | self ) |

Definition at line 1026 of file Configurable.py.

    01027                               :
    01028         if self.isPublic():
    01029             return PublicToolHandle( self.toStringProperty() )
    01030         else:
    01031             return PrivateToolHandle( self.toStringProperty() )

def Configurable::ConfigurableAlgTool::getGaudiType | ( |  | self ) |

Definition at line 1023 of file Configurable.py.

    01024                             :
    01025         return 'AlgTool'

def Configurable::ConfigurableAlgTool::getHandle | ( |  | self ) |

Definition at line 1019 of file Configurable.py.

    01020                          :
    01021         # iAlgTool isn't useful, unless one knows for sure that the tool exists
    01022         return iProperty( self.getJobOptName() )

def Configurable::ConfigurableAlgTool::getJobOptName | ( |  | self ) |

Reimplemented from Configurable::Configurable.

Definition at line 1063 of file Configurable.py.

    01064                              :
    01065         return self._jobOptName

def Configurable::ConfigurableAlgTool::getParent | ( |  | self ) |

Reimplemented from Configurable::Configurable.

Definition at line 1053 of file Configurable.py.

    01054                          :
    01055         dot = self._jobOptName.rfind('.')
    01056         if dot != -1:
    01057             return self._jobOptName[:dot]
    01058         else:
    01059             return ""

def Configurable::ConfigurableAlgTool::getPrintTitle | ( |  | self ) |

Reimplemented from Configurable::Configurable.

Definition at line 1032 of file Configurable.py.

    01033                            :
    01034         if self.isPublic():
    01035             pop = 'Public '
    01036         else:
    01037             pop = 'Private '
    01038         return pop + Configurable.getPrintTitle(self)

def Configurable::ConfigurableAlgTool::hasParent | ( |  | self,
|  |  | parent
| ) |  |

Reimplemented from Configurable::Configurable.

Definition at line 1060 of file Configurable.py.

    01061                                  :
    01062         return self._jobOptName.startswith( parent + '.' )

def Configurable::ConfigurableAlgTool::isInToolSvc | ( |  | self ) |

Definition at line 1069 of file Configurable.py.

    01070                            :
    01071         return self._jobOptName.startswith('ToolSvc.')

def Configurable::ConfigurableAlgTool::isPublic | ( |  | self ) |

Reimplemented from Configurable::Configurable.

Definition at line 1066 of file Configurable.py.

    01067                         :
    01068         return self.isInToolSvc()

def Configurable::ConfigurableAlgTool::setParent | ( |  | self,
|  |  | parentName
| ) |  |

Reimplemented from Configurable::Configurable.

Definition at line 1039 of file Configurable.py.

    01040                                      :
    01041 #       print "ConfigurableAlgTool.setParent(%s@%x,%r)" % (self.getName(),id(self),parentName)
    01042 #       print "Calling stack:"
    01043 #       import traceback
    01044 #       traceback.print_stack()
    01045         # propagate parent to AlgTools in children
    01046         for c in self.getAllChildren():
    01047             if isinstance(c,ConfigurableAlgTool): c.setParent( parentName )
    01048
    01049         # update my own parent
    01050         name = self.getName()
    01051         name = name[name.rfind('.')+1:] # Name of the instance
    01052         self._jobOptName = self._name = parentName + '.' + name

def Configurable::ConfigurableAlgTool::toStringProperty | ( |  | self ) |

Definition at line 1072 of file Configurable.py.

    01073                                 :
    01074         # called on conversion to a string property for the jocat
    01075         return self.getFullName()

## Member Data Documentation

dictionary Configurable::ConfigurableAlgTool::__slots__`[static, private]`

Initial value:

    { '_jobOptName' : '', 'OutputLevel' : 0, \
           'AuditTools' : 0, 'AuditInitialize' : 0, 'AuditFinalize' : 0 }

Reimplemented from Configurable::Configurable.

Definition at line 1007 of file Configurable.py.

Configurable::ConfigurableAlgTool::_jobOptName`[private]`

Definition at line 1010 of file Configurable.py.

Configurable::ConfigurableAlgTool::_name`[private]`

Reimplemented from Configurable::Configurable.

Definition at line 1010 of file Configurable.py.

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

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v23r0/GaudiKernel/python/GaudiKernel/Configurable.py

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines