CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SurveyError.h
Go to the documentation of this file.
1 #ifndef CondFormats_Alignment_SurveyError_H
2 #define CondFormats_Alignment_SurveyError_H
3 
20 
22 
24 {
27 
28  public:
29 
30  inline SurveyError(
31  uint8_t structureType = 0, // default unknown
32  align::ID rawId = 0, // default unknown
33  const ErrorMatrix& = ErrorMatrix() // default 0
34  );
35 
36  inline uint8_t structureType() const;
37 
38  inline align::ID rawId() const;
39 
40  inline ErrorMatrix matrix() const;
41 
42 private:
43 
44  static const unsigned int nPar_ = ErrorMatrix::kRows;
45  static const unsigned int size_ = nPar_ * (nPar_ + 1) / 2;
46 
47  uint8_t m_structureType;
49 
51 
53 };
54 
55 SurveyError::SurveyError(uint8_t structureType,
56  align::ID rawId,
57  const ErrorMatrix& cov):
58  m_structureType(structureType),
59  m_rawId(rawId)
60 {
61  const Scalar* data = cov.Array(); // lower triangular of cov
62 
63  for (unsigned int i = 0; i < size_; ++i) m_errors[i] = data[i];
64 }
65 
67 {
68  return m_structureType;
69 }
70 
72 {
73  return m_rawId;
74 }
75 
77 {
79 }
80 
81 #endif
static const unsigned int nPar_
Definition: SurveyError.h:44
int i
Definition: DBlmapReader.cc:9
ErrorMatrix matrix() const
Definition: SurveyError.h:76
uint32_t ID
Definition: Definitions.h:26
uint8_t m_structureType
Definition: SurveyError.h:47
Scalar m_errors[size_]
Definition: SurveyError.h:50
uint8_t structureType() const
Definition: SurveyError.h:66
align::ID rawId() const
Definition: SurveyError.h:71
align::ID m_rawId
Definition: SurveyError.h:48
ErrorMatrix::value_type Scalar
Definition: SurveyError.h:26
SurveyError(uint8_t structureType=0, align::ID rawId=0, const ErrorMatrix &=ErrorMatrix())
Definition: SurveyError.h:55
#define COND_SERIALIZABLE
Definition: Serializable.h:37
static const unsigned int size_
Definition: SurveyError.h:45
align::ErrorMatrix ErrorMatrix
Definition: SurveyError.h:25
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
math::Error< 6 >::type ErrorMatrix
Definition: Definitions.h:39