LArSoft  v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
pyG4NistManager.cc File Reference
#include <boost/python.hpp>
#include "G4Version.hh"

Go to the source code of this file.

Functions

void export_G4NistManager ()
 

Function Documentation

void export_G4NistManager ( )

Definition at line 92 of file pyG4NistManager.cc.

Referenced by BOOST_PYTHON_MODULE().

93 {
94 #if G4VERSION_NUMBER >= 710
95 
96  class_<G4NistManager, boost::noncopyable>
97  ("G4NistManager", "manager class for NIST materials", no_init)
98  // ---
99  .def("Instance", &G4NistManager::Instance,
100  return_value_policy<reference_existing_object>())
101  .staticmethod("Instance")
102  // ---
103  .def("SetVerbose", &G4NistManager::SetVerbose)
104  .def("GetVerbose", &G4NistManager::GetVerbose)
105  // ---
106 #if G4VERSION_NUMBER < 910
107  .def("RegisterElement", &G4NistManager::RegisterElement)
108  .def("DeRegisterElement", &G4NistManager::DeRegisterElement)
109 #endif
110  .def("GetElement", &G4NistManager::GetElement,
111  return_internal_reference<>())
112  .def("FindOrBuildElement", f1_FindOrBuildElement,
113  f_FindOrBuildElement()
114  [return_value_policy<reference_existing_object>()])
115  .def("FindOrBuildElement", f2_FindOrBuildElement,
116  f_FindOrBuildElement()
117  [return_value_policy<reference_existing_object>()])
118  .def("GetNumberOfElements", &G4NistManager::GetNumberOfElements)
119  .def("GetZ", &G4NistManager::GetZ)
120  .def("GetIsotopeMass", &G4NistManager::GetIsotopeMass)
121  .def("PrintElement", f1_PrintElement)
122  .def("PrintElement", f2_PrintElement)
123  .def("PrintG4Element", &G4NistManager::PrintG4Element)
124  // ---
125 #if G4VERSION_NUMBER < 910
126  .def("RegisterMaterial", &G4NistManager::RegisterMaterial)
127  .def("DeRegisterMaterial", &G4NistManager::DeRegisterMaterial)
128 #endif
129  .def("GetMaterial", &G4NistManager::GetMaterial,
130  return_value_policy<reference_existing_object>())
131  .def("FindOrBuildMaterial", &G4NistManager::FindOrBuildMaterial,
132  f_FindOrBuildMaterial()
133  [return_value_policy<reference_existing_object>()])
134  .def("ConstructNewMaterial", f1_ConstructNewMaterial,
135  f_ConstructNewMaterial()
136  [return_value_policy<reference_existing_object>()])
137  .def("ConstructNewMaterial", f2_ConstructNewMaterial,
138  f_ConstructNewMaterial()
139  [return_value_policy<reference_existing_object>()])
140 #if G4VERSION_NUMBER >= 910
141  .def("ConstructNewGasMaterial", &G4NistManager::ConstructNewGasMaterial,
142  f_ConstructNewGasMaterial()
143  [return_value_policy<reference_existing_object>()])
144 #endif
145  .def("GetNumberOfMaterials", &G4NistManager::GetNumberOfMaterials)
146  .def("ListMaterials", &G4NistManager::ListMaterials)
147  .def("PrintG4Material", &G4NistManager::PrintG4Material)
148  ;
149 #endif
150 }