Geant4-11
pyG4Event.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// ====================================================================
27// pyG4Event.cc
28//
29// 2005 Q
30// ====================================================================
31#include <boost/python.hpp>
32#include "G4Event.hh"
33
34using namespace boost::python;
35
36// ====================================================================
37// thin wrappers
38// ====================================================================
39namespace pyG4Event {
40
42 GetPrimaryVertex, 0, 1)
43}
44
45using namespace pyG4Event;
46
47// ====================================================================
48// module definition
49// ====================================================================
51{
52 class_<G4Event, G4Event*, boost::noncopyable>("G4Event", "event class")
53 .def(init<G4int>())
54 // ---
55 .def("Print", &G4Event::Print)
56 .def("Draw", &G4Event::Draw)
57 .def("SetEventID", &G4Event::SetEventID)
58 .def("GetEventID", &G4Event::GetEventID)
59 .def("SetEventAborted", &G4Event::SetEventAborted)
60 .def("IsAborted", &G4Event::IsAborted)
61 // ---
62 .def("AddPrimaryVertex", &G4Event::AddPrimaryVertex)
63 .def("GetNumberOfPrimaryVertex", &G4Event::GetNumberOfPrimaryVertex)
64 .def("GetPrimaryVertex", &G4Event::GetPrimaryVertex,
65 f_GetPrimaryVertex()[return_internal_reference<>()])
66 // ---
67 .def("GetTrajectoryContainer", &G4Event::GetTrajectoryContainer,
68 return_internal_reference<>())
69 .def("SetUserInformation", &G4Event::SetUserInformation)
70 .def("GetUserInformation", &G4Event::GetUserInformation,
71 return_internal_reference<>())
72 ;
73
74 // reduced functionality...
75 //.def("SetHCofThisEvent", &G4Event::SetHCofThisEvent)
76 //.def("GetHCofThisEvent", &G4Event::SetHCofThisEvent,
77 // return_internal_reference<>())
78 //.def("SetDCofThisEvent", &G4Event::SetHCofThisEvent)
79 //.def("GetDCofThisEvent", &G4Event::SetHCofThisEvent,
80 // return_internal_reference<>())
81
82}
G4bool IsAborted() const
Definition: G4Event.hh:167
G4int GetNumberOfPrimaryVertex() const
Definition: G4Event.hh:133
void Print() const
Definition: G4Event.cc:85
G4TrajectoryContainer * GetTrajectoryContainer() const
Definition: G4Event.hh:160
G4PrimaryVertex * GetPrimaryVertex(G4int i=0) const
Definition: G4Event.hh:137
void SetEventAborted()
Definition: G4Event.hh:88
G4int GetEventID() const
Definition: G4Event.hh:118
void SetUserInformation(G4VUserEventInformation *anInfo)
Definition: G4Event.hh:171
void AddPrimaryVertex(G4PrimaryVertex *aPrimaryVertex)
Definition: G4Event.hh:121
void SetEventID(G4int i)
Definition: G4Event.hh:80
G4VUserEventInformation * GetUserInformation() const
Definition: G4Event.hh:173
void Draw() const
Definition: G4Event.cc:90
BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(f_ClearWaitingStack, ClearWaitingStack, 0, 1) BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(f_GetNWaitingTrack
void export_G4Event()
Definition: pyG4Event.cc:50