Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4TypeKeyT< T > Class Template Reference

#include <G4TypeKeyT.hh>

+ Inheritance diagram for G4TypeKeyT< T >:

Public Member Functions

 G4TypeKeyT ()
 
 ~G4TypeKeyT () override=default
 
- Public Member Functions inherited from G4TypeKey
 G4TypeKey ()=default
 
virtual ~G4TypeKey ()=default
 
G4bool IsValid ()
 
Key operator() () const
 
G4bool operator== (const G4TypeKey &rhs) const
 
G4bool operator!= (const G4TypeKey &rhs) const
 
G4bool operator< (const G4TypeKey &rhs) const
 
G4bool operator> (const G4TypeKey &rhs) const
 

Additional Inherited Members

- Public Types inherited from G4TypeKey
using Key = unsigned long
 
- Protected Member Functions inherited from G4TypeKey
Key NextKey () const
 
- Protected Attributes inherited from G4TypeKey
Key fMyKey {0}
 

Detailed Description

template<typename T>
class G4TypeKeyT< T >

Definition at line 37 of file G4TypeKeyT.hh.

Constructor & Destructor Documentation

◆ G4TypeKeyT()

template<typename T >
G4TypeKeyT< T >::G4TypeKeyT ( )
inline

Definition at line 41 of file G4TypeKeyT.hh.

41 {
42 static G4ThreadLocal Key *pkey = nullptr ;
43 if (pkey == nullptr) { pkey = new Key; *pkey = NextKey(); }
44 Key &key = *pkey;
45 fMyKey = key;
46 }
unsigned long Key
Definition G4TypeKey.hh:41
Key NextKey() const
Definition G4TypeKey.hh:66
#define G4ThreadLocal
Definition tls.hh:77

◆ ~G4TypeKeyT()

template<typename T >
G4TypeKeyT< T >::~G4TypeKeyT ( )
overridedefault

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