ATLAS Offline Software
AthenaKernel/AthenaKernel/IAthenaBarCode.h
Go to the documentation of this file.
1 
3 /*
4  Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 #ifndef ATHENAKERNEL_IATHENABARCODE_H
8 #define ATHENAKERNEL_IATHENABARCODE_H
9 // //
19 
20 
21 #include <GaudiKernel/StatusCode.h>
22 
24 //
25 // Universal Object Identifier for all Navigable4Momentum Objects
26 //
27 // Class Structure:
28 // IAthenaBarCode INavigable I4Momentum
29 // | / /
30 // V / /
31 // INav4M
32 // |
33 // V
34 // IParticle
35 // |
36 // V
37 // ParticleImpl
38 //
40 
41 //Work Around dependency issue of Navigation
42 //If don't see IUserDataSvc.h yet, do the definitions here.
43 #include <stdint.h> // for uint64_t
45 
47 
49 
50 public:
51 
54 
55 public:
56 
57  //Constructors
58 
60  virtual ~IAthenaBarCode() = default;
61 
62  //All the default implementations are for the classes that derives from
63  //INav4M but not ParticleImpl
64 
65 public:
66  //Public setter and getters
68  return UNDEFINEDBARCODE;
69  }
70 
71  virtual void setAthenaBarCode(AthenaBarCode_t /*id*/) {
72  // throw std::runtime_error("IAthenaBarCode::setAthenaBarCode():: can't set AthenaBarCode in the dummy implementation");
73  }
74 
75 public:
76  //Comparing & Versioning Control
77  virtual bool hasSameAthenaBarCode(const IAthenaBarCode &/*obj*/) const {
78  return false;
79  }
80 
81  virtual bool hasSameAthenaBarCodeExceptVersion(const IAthenaBarCode &/*obj*/) const {
82  return false;
83  }
84 
86  return UNDEFINEDVERSION;
87  }
88 
89  virtual void newVersion() {
90  // throw std::runtime_error("IAthenaBarCode::newVersion():: can't newVersion() in the dummy implementation");
91  }
92 
93  virtual void setVersion(AthenaBarCodeVersion_t /*newversion*/) {
94  // throw std::runtime_error("IAthenaBarCode::setVersion():: can't setVersion() in the dummy implementation");
95  }
96 
97 };
98 
99 #endif // NAVIGATION_ATHENABARCODE_H
IAthenaBarCode::getVersion
virtual AthenaBarCodeVersion_t getVersion() const
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:85
IAthenaBarCode::newVersion
virtual void newVersion()
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:89
IAthenaBarCode::hasSameAthenaBarCodeExceptVersion
virtual bool hasSameAthenaBarCodeExceptVersion(const IAthenaBarCode &) const
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:81
IAthenaBarCode::UNDEFINEDBARCODE
static const AthenaBarCode_t UNDEFINEDBARCODE
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:52
IAthenaBarCode::IAthenaBarCode
IAthenaBarCode()
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:59
AthenaBarCode_t
uint64_t AthenaBarCode_t
barcode for all INav4Mom classes
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:44
IAthenaBarCode::~IAthenaBarCode
virtual ~IAthenaBarCode()=default
xAOD::uint64_t
uint64_t
Definition: EventInfo_v1.cxx:123
IAthenaBarCode
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:48
IAthenaBarCode::setAthenaBarCode
virtual void setAthenaBarCode(AthenaBarCode_t)
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:71
IAthenaBarCode::hasSameAthenaBarCode
virtual bool hasSameAthenaBarCode(const IAthenaBarCode &) const
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:77
IAthenaBarCode::setVersion
virtual void setVersion(AthenaBarCodeVersion_t)
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:93
IAthenaBarCode::getAthenaBarCode
virtual AthenaBarCode_t getAthenaBarCode() const
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:67
AthenaBarCodeVersion_t
AthenaBarCode_t AthenaBarCodeVersion_t
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:46
IAthenaBarCode::UNDEFINEDVERSION
static const AthenaBarCode_t UNDEFINEDVERSION
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:53