CMS 3D CMS Logo

twikiExport::Constituent Class Reference

List of all members.

Public Member Functions

def __init__
def __str__

Public Attributes

 theCount
 theDensity
 theDescription
 theL0
 theMass
 theName
 theType
 theVolume
 theX0


Detailed Description

Definition at line 6 of file twikiExport.py.


Member Function Documentation

def twikiExport::Constituent::__init__ (   self,
  line,
  predefinedMaterials 
)

Definition at line 7 of file twikiExport.py.

00007                                                  :
00008         if  len(line.split('"')) < 5 or len(line.split('"')[4].split()) < 3:
00009             raise StandardError , "not a well formed Constituent: "+constString
00010         self.theDescription = line.split('"')[1]
00011         self.theName = line.split('"')[3]
00012         self.theCount = float(line.split('"')[4].split()[1])
00013         self.theVolume = float(line.split('"')[4].split()[0]) * self.theCount
00014         self.theType = line.split('"')[4].split()[2]
00015         self.theDensity = float(predefinedMaterials[self.theName][2])
00016         self.theX0 = float(predefinedMaterials[self.theName][3]) * self.theDensity
00017         self.theL0 = float(predefinedMaterials[self.theName][4]) * self.theDensity
00018         self.theMass = self.theVolume * self.theDensity
00019 #        print "%s\tX0: %.3f\trho: %.3f\tX0': %.3f"%(self.theName, float(predefinedMaterials[self.theName][3]), float(predefinedMaterials[self.theName][2]), self.theX0)        
    def __str__(self):

def twikiExport::Constituent::__str__ (   self  ) 

Definition at line 20 of file twikiExport.py.

00020                      :
00021         return "Name: "+self.theName+" desc: "+self.theDescription+" mass "+self.theMass+" type "+self.theType+" count "+self.theCount
00022         
class Material:


Member Data Documentation

twikiExport::Constituent::theCount

Definition at line 12 of file twikiExport.py.

twikiExport::Constituent::theDensity

Definition at line 15 of file twikiExport.py.

twikiExport::Constituent::theDescription

Definition at line 10 of file twikiExport.py.

twikiExport::Constituent::theL0

Definition at line 17 of file twikiExport.py.

twikiExport::Constituent::theMass

Definition at line 18 of file twikiExport.py.

twikiExport::Constituent::theName

Definition at line 11 of file twikiExport.py.

twikiExport::Constituent::theType

Definition at line 14 of file twikiExport.py.

twikiExport::Constituent::theVolume

Definition at line 13 of file twikiExport.py.

twikiExport::Constituent::theX0

Definition at line 16 of file twikiExport.py.


The documentation for this class was generated from the following file:
Generated on Tue Jun 9 18:53:12 2009 for CMSSW by  doxygen 1.5.4