Geant4  10.02
pyG4FieldManager.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id: pyG4FieldManager.cc 76884 2013-11-18 12:54:03Z gcosmo $
27 // ====================================================================
28 // pyG4FieldManager.cc
29 //
30 // 2005 Q
31 // ====================================================================
32 #include <boost/python.hpp>
33 #include "G4Version.hh"
34 #include "G4FieldManager.hh"
35 #include "G4Field.hh"
36 #include "G4ChordFinder.hh"
37 #include "G4MagneticField.hh"
38 #include "G4Track.hh"
39 
40 using namespace boost::python;
41 
42 // ====================================================================
43 // miscs
44 // ====================================================================
45 #if G4VERSION_NUMBER <= 801
46 // What a hell!
48 {
49  return fChordFinder;
50 }
51 #endif
52 
53 // ====================================================================
54 // thin wrappers
55 // ====================================================================
56 namespace pyG4FieldManager {
57 
62 
63 }
64 
65 using namespace pyG4FieldManager;
66 
67 // ====================================================================
68 // module definition
69 // ====================================================================
71 {
72  class_<G4FieldManager, G4FieldManager*, boost::noncopyable>
73  ("G4FieldManager", "field manager class")
74  // constructors
75  .def(init<>())
76  .def(init<G4Field*>())
77  .def(init<G4Field*, G4ChordFinder*>())
78  .def(init<G4Field*, G4ChordFinder*, G4bool>())
79  .def(init<G4MagneticField*>())
80  // ---
81  .def("SetDetectorField", &G4FieldManager::SetDetectorField)
82  .def("GetDetectorField", &G4FieldManager::GetDetectorField,
83  return_internal_reference<>())
84  .def("DoesFieldExist", &G4FieldManager::DoesFieldExist)
85  .def("CreateChordFinder", &G4FieldManager::CreateChordFinder)
86  .def("SetChordFinder", &G4FieldManager::SetChordFinder)
87  .def("GetChordFinder", f1_GetChordFinder,
88  return_internal_reference<>())
89  .def("GetChordFinder", f2_GetChordFinder,
90  return_internal_reference<>())
91  .def("ConfigureForTrack", &G4FieldManager::ConfigureForTrack)
92  .def("GetDeltaIntersection", &G4FieldManager::GetDeltaIntersection)
93  .def("GetDeltaOneStep", &G4FieldManager::GetDeltaOneStep)
94  .def("SetAccuraciesWithDeltaOneStep",
96  .def("SetDeltaOneStep", &G4FieldManager::SetDeltaOneStep)
97  .def("SetDeltaIntersection", &G4FieldManager::SetDeltaIntersection)
98  .def("GetMinimumEpsilonStep", &G4FieldManager::GetMinimumEpsilonStep)
99  .def("SetMinimumEpsilonStep", &G4FieldManager::SetMinimumEpsilonStep)
100  .def("GetMaximumEpsilonStep", &G4FieldManager::GetMaximumEpsilonStep)
101  .def("SetMaximumEpsilonStep", &G4FieldManager::SetMaximumEpsilonStep)
102  .def("DoesFieldChangeEnergy", &G4FieldManager::DoesFieldChangeEnergy)
103  .def("SetFieldChangesEnergy", &G4FieldManager::SetFieldChangesEnergy)
104  ;
105 }
106 
G4ChordFinder * GetChordFinder()
const G4ChordFinder *(G4FieldManager::* f2_GetChordFinder)() const
G4bool SetDetectorField(G4Field *detectorField)
G4double GetDeltaOneStep() const
void SetChordFinder(G4ChordFinder *aChordFinder)
void export_G4FieldManager()
void SetAccuraciesWithDeltaOneStep(G4double valDeltaOneStep)
virtual void ConfigureForTrack(const G4Track *)
void SetMinimumEpsilonStep(G4double newEpsMin)
G4double GetMaximumEpsilonStep() const
G4bool DoesFieldExist() const
G4bool DoesFieldChangeEnergy() const
G4double GetDeltaIntersection() const
void SetDeltaIntersection(G4double valueDintersection)
void SetFieldChangesEnergy(G4bool value)
void SetMaximumEpsilonStep(G4double newEpsMax)
G4ChordFinder *(G4FieldManager::* f1_GetChordFinder)()
void CreateChordFinder(G4MagneticField *detectorMagField)
const G4Field * GetDetectorField() const
void SetDeltaOneStep(G4double valueD1step)
G4double GetMinimumEpsilonStep() const