Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4SmoothTrajectoryPoint Class Reference

#include <G4SmoothTrajectoryPoint.hh>

+ Inheritance diagram for G4SmoothTrajectoryPoint:

Public Member Functions

 G4SmoothTrajectoryPoint ()=default
 
 G4SmoothTrajectoryPoint (G4ThreeVector pos, std::vector< G4ThreeVector > *auxiliaryPoints)
 
 G4SmoothTrajectoryPoint (G4ThreeVector pos)
 
 ~G4SmoothTrajectoryPoint () override
 
 G4SmoothTrajectoryPoint (const G4SmoothTrajectoryPoint &right)
 
G4SmoothTrajectoryPointoperator= (const G4SmoothTrajectoryPoint &)=delete
 
void * operator new (size_t)
 
void operator delete (void *aTrajectoryPoint)
 
G4bool operator== (const G4SmoothTrajectoryPoint &right) const
 
const G4ThreeVector GetPosition () const override
 
const std::vector< G4ThreeVector > * GetAuxiliaryPoints () const override
 
const std::map< G4String, G4AttDef > * GetAttDefs () const override
 
std::vector< G4AttValue > * CreateAttValues () const override
 
- Public Member Functions inherited from G4VTrajectoryPoint
 G4VTrajectoryPoint ()=default
 
virtual ~G4VTrajectoryPoint ()=default
 
G4bool operator== (const G4VTrajectoryPoint &right) const
 

Detailed Description

Definition at line 48 of file G4SmoothTrajectoryPoint.hh.

Constructor & Destructor Documentation

◆ G4SmoothTrajectoryPoint() [1/4]

G4SmoothTrajectoryPoint::G4SmoothTrajectoryPoint ( )
default

◆ G4SmoothTrajectoryPoint() [2/4]

G4SmoothTrajectoryPoint::G4SmoothTrajectoryPoint ( G4ThreeVector pos,
std::vector< G4ThreeVector > * auxiliaryPoints )

Definition at line 55 of file G4SmoothTrajectoryPoint.cc.

57 : fPosition(pos), fAuxiliaryPointVector(auxiliaryPoints)
58{}

◆ G4SmoothTrajectoryPoint() [3/4]

G4SmoothTrajectoryPoint::G4SmoothTrajectoryPoint ( G4ThreeVector pos)

Definition at line 53 of file G4SmoothTrajectoryPoint.cc.

53{ fPosition = pos; }

◆ ~G4SmoothTrajectoryPoint()

G4SmoothTrajectoryPoint::~G4SmoothTrajectoryPoint ( )
override

Definition at line 64 of file G4SmoothTrajectoryPoint.cc.

64{ delete fAuxiliaryPointVector; }

◆ G4SmoothTrajectoryPoint() [4/4]

G4SmoothTrajectoryPoint::G4SmoothTrajectoryPoint ( const G4SmoothTrajectoryPoint & right)

Definition at line 60 of file G4SmoothTrajectoryPoint.cc.

61 : fPosition(right.fPosition), fAuxiliaryPointVector(right.fAuxiliaryPointVector)
62{}

Member Function Documentation

◆ CreateAttValues()

std::vector< G4AttValue > * G4SmoothTrajectoryPoint::CreateAttValues ( ) const
overridevirtual

Reimplemented from G4VTrajectoryPoint.

Definition at line 81 of file G4SmoothTrajectoryPoint.cc.

82{
83 auto values = new std::vector<G4AttValue>;
84
85 if (fAuxiliaryPointVector != nullptr) {
86 for (const auto& iAux : *fAuxiliaryPointVector) {
87 values->push_back(G4AttValue("Aux", G4BestUnit(iAux, "Length"), ""));
88 }
89 }
90
91 values->push_back(G4AttValue("Pos", G4BestUnit(fPosition, "Length"), ""));
92
93#ifdef G4ATTDEBUG
94 G4cout << G4AttCheck(values, GetAttDefs());
95#endif
96
97 return values;
98}
#define G4BestUnit(a, b)
G4GLOB_DLL std::ostream G4cout
const std::map< G4String, G4AttDef > * GetAttDefs() const override

◆ GetAttDefs()

const std::map< G4String, G4AttDef > * G4SmoothTrajectoryPoint::GetAttDefs ( ) const
overridevirtual

Reimplemented from G4VTrajectoryPoint.

Definition at line 66 of file G4SmoothTrajectoryPoint.cc.

67{
68 G4bool isNew;
69 std::map<G4String, G4AttDef>* store =
70 G4AttDefStore::GetInstance("G4SmoothTrajectoryPoint", isNew);
71 if (isNew) {
72 G4String Pos("Pos");
73 (*store)[Pos] = G4AttDef(Pos, "Step Position", "Physics", "G4BestUnit", "G4ThreeVector");
74 G4String Aux("Aux");
75 (*store)[Aux] =
76 G4AttDef(Aux, "Auxiliary Point Position", "Physics", "G4BestUnit", "G4ThreeVector");
77 }
78 return store;
79}
bool G4bool
Definition G4Types.hh:86
ush Pos
Definition deflate.h:92
std::map< G4String, G4AttDef > * GetInstance(const G4String &storeKey, G4bool &isNew)

Referenced by CreateAttValues(), G4VisCommandList::SetNewValue(), and G4VisCommandSceneAddTrajectories::SetNewValue().

◆ GetAuxiliaryPoints()

const std::vector< G4ThreeVector > * G4SmoothTrajectoryPoint::GetAuxiliaryPoints ( ) const
inlineoverridevirtual

Reimplemented from G4VTrajectoryPoint.

Definition at line 69 of file G4SmoothTrajectoryPoint.hh.

70 {
71 return fAuxiliaryPointVector;
72 }

◆ GetPosition()

const G4ThreeVector G4SmoothTrajectoryPoint::GetPosition ( ) const
inlineoverridevirtual

Implements G4VTrajectoryPoint.

Definition at line 68 of file G4SmoothTrajectoryPoint.hh.

68{ return fPosition; }

◆ operator delete()

void G4SmoothTrajectoryPoint::operator delete ( void * aTrajectoryPoint)
inline

Definition at line 94 of file G4SmoothTrajectoryPoint.hh.

95{
96 aSmoothTrajectoryPointAllocator()->FreeSingle((G4SmoothTrajectoryPoint*)aTrajectoryPoint);
97}
G4TRACKING_DLL G4Allocator< G4SmoothTrajectoryPoint > *& aSmoothTrajectoryPointAllocator()

◆ operator new()

void * G4SmoothTrajectoryPoint::operator new ( size_t )
inline

Definition at line 86 of file G4SmoothTrajectoryPoint.hh.

◆ operator=()

G4SmoothTrajectoryPoint & G4SmoothTrajectoryPoint::operator= ( const G4SmoothTrajectoryPoint & )
delete

◆ operator==()

G4bool G4SmoothTrajectoryPoint::operator== ( const G4SmoothTrajectoryPoint & right) const
inline

Definition at line 99 of file G4SmoothTrajectoryPoint.hh.

100{
101 return (this == &r);
102}

The documentation for this class was generated from the following files: