ATLAS Offline Software
Classes | Functions | Variables
checkTP Namespace Reference

Classes

class  Columbo
 
class  DataMember
 
class  FctMember
 

Functions

def dumpDataMembers (self, klass)
 for i in xrange(klass.DataMemberSize()): mbr = klass.DataMemberAt(i).TypeOf().Name(DICTSCOPE) klassNames.append (self.loadDicts(mbr)) More...
 
def dumpFctMembers (self, klass)
 
def inspect (self, klassName)
 
def save (self, fileName="./columbo.out")
 

Variables

 __author__
 
 S
 
 SF
 
 SQ
 
 SFQ
 
 DICTSCOPE
 
 _cpp_builtins
 
 klassName
 
 columbo
 
 report
 

Function Documentation

◆ dumpDataMembers()

def checkTP.dumpDataMembers (   self,
  klass 
)

for i in xrange(klass.DataMemberSize()): mbr = klass.DataMemberAt(i).TypeOf().Name(DICTSCOPE) klassNames.append (self.loadDicts(mbr))

Definition at line 106 of file checkTP.py.

106  def dumpDataMembers(self, klass):
107  dataMembers = []
108  for i in range(klass.DataMemberSize()):
109  d = klass.DataMemberAt(i)
110  scope = klass.Name()
111  offset = '<s>' if d.IsStatic() else d.Offset()
112  fullname = '::'.join([scope, d.Name(SFQ)])
113  typename = d.TypeOf().Name(SFQ)
114  dataMembers.append( DataMember(offset, fullname, typename) )
115  return dataMembers
116 

◆ dumpFctMembers()

def checkTP.dumpFctMembers (   self,
  klass 
)

Definition at line 117 of file checkTP.py.

117  def dumpFctMembers(self, klass):
118  fctMembers = []
119  for i in range(klass.FunctionMemberSize()):
120  f = klass.FunctionMemberAt(i)
121  fctMembers.append( FctMember( f.Name(SFQ),
122  f.TypeOf().Name(SFQ) ) )
123  pass
124  return fctMembers
125 

◆ inspect()

def checkTP.inspect (   self,
  klassName 
)

Definition at line 126 of file checkTP.py.

126  def inspect(self, klassName):
127  self.report = []
128  print ("")
129  print ("#"*80)
130  print ("## loading all relevant dictionaries...")
131  try:
132  klassNames = self.loadDicts(klassName)
133  print ("#"*80)
134  except Exception as err:
135  print ("")
136  print ("#"*80)
137  print ("## ERROR while trying to load dict for [%s]" % klassName)
138  print ("## -Most probably you DIDN'T give a fully qualified name !")
139  print ("## Ex: try 'Analysis::Muon' instead of 'Muon'")
140  print ("##")
141  print ("## -Could also mean that you are missing a dictionary ")
142  print ("## of one of the base classes...")
143  print ("#"*80)
144  print (err)
145  raise
146  return
147 
148  print ("")
149  print ("#"*80)
150  print ("## infos for class [%s]:" % klassName)
151  print ("## sizeof(%s) = %i" % \
152  (klassName,
153  self.Type.SizeOf(self.Type.ByName(klassName))))
154  print ("##")
155  print ("## (offset, data member name, data member type)")
156  print ("")
157  # we want to dump from the base to the most derived class
158  klassNames.reverse()
159  for klass in klassNames:
160  line = "%s %s %s" % (
161  "-" * (40-len(klass)//2-1),
162  "[%s]" % klass,
163  "-" * (40-len(klass)//2-1) )
164 
165  print (line)
166  self.report.append(line)
167  dataMembers = self.dumpDataMembers( self.Type.ByName(klass) )
168  for i in dataMembers:
169  line = "%3s %s %-50s %s %s" % ( str(i.offset),
170  " "*5,
171  i.name,
172  " "*5, i.type )
173  print (line)
174  self.report.append(line)
175  print ("#"*80)
176  return
177 

◆ save()

def checkTP.save (   self,
  fileName = "./columbo.out" 
)

Definition at line 178 of file checkTP.py.

178  def save(self, fileName = "./columbo.out" ):
179  file = open(os.path.expandvars(os.path.expanduser(fileName)),
180  "w+")
181  for line in self.report:
182  file.writelines(line + os.linesep)
183  pass
184  file.close()
185 

Variable Documentation

◆ __author__

checkTP.__author__
private

Definition at line 23 of file checkTP.py.

◆ _cpp_builtins

checkTP._cpp_builtins
private

Definition at line 32 of file checkTP.py.

◆ columbo

checkTP.columbo

Definition at line 196 of file checkTP.py.

◆ DICTSCOPE

checkTP.DICTSCOPE

Definition at line 30 of file checkTP.py.

◆ klassName

checkTP.klassName

Definition at line 191 of file checkTP.py.

◆ report

checkTP.report

Definition at line 127 of file checkTP.py.

◆ S

checkTP.S

Definition at line 26 of file checkTP.py.

◆ SF

checkTP.SF

Definition at line 27 of file checkTP.py.

◆ SFQ

checkTP.SFQ

Definition at line 29 of file checkTP.py.

◆ SQ

checkTP.SQ

Definition at line 28 of file checkTP.py.

checkTP.dumpFctMembers
def dumpFctMembers(self, klass)
Definition: checkTP.py:117
dumpHVPathFromNtuple.append
bool append
Definition: dumpHVPathFromNtuple.py:91
checkTP.save
def save(self, fileName="./columbo.out")
Definition: checkTP.py:178
plotBeamSpotVxVal.range
range
Definition: plotBeamSpotVxVal.py:195
checkTP.inspect
def inspect(self, klassName)
Definition: checkTP.py:126
TCS::join
std::string join(const std::vector< std::string > &v, const char c=',')
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/Root/StringUtils.cxx:10
checkTP.dumpDataMembers
def dumpDataMembers(self, klass)
for i in xrange(klass.DataMemberSize()): mbr = klass.DataMemberAt(i).TypeOf().Name(DICTSCOPE) klassNa...
Definition: checkTP.py:106
Trk::open
@ open
Definition: BinningType.h:40
str
Definition: BTagTrackIpAccessor.cxx:11