CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
namespaceDict.py
Go to the documentation of this file.
1 """parsing the LCGDict namespace and build dictionary
2 (quick'n'dirty solution)
3 
4 benedikt.hegner@cern.ch
5 
6 """
7 
8 import popen2
9 import string
10 
12 
13  # execute SealPluginDump to get list of plugins
14  process = popen2.Popen3('SealPluginDump')
15  output = process.fromchild.read()
16 
17  namespaceDict = {}
18 
19  for line in output.split('\n'):
20  # search for Reflex, global namespace and non templates
21  if line.find('Reflex') !=-1 and line.find(':') ==-1 and line.find('<') ==-1:
22  className = line.replace('LCGReflex/', '').strip()
23  namespaceDict[className] = line.strip()
24 
25  return namespaceDict