ATLAS Offline Software
Loading...
Searching...
No Matches
CPMHits_v1.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5// $Id: CPMHits_v1.cxx 638578 2015-01-09 17:00:15Z morrisj $
6
7// System include(s):
8#include <cmath>
9
10// EDM includes(s):
12
13// Local include(s):
15
16namespace xAOD{
17
22
23 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( CPMHits_v1 , int , crate , setCrate )
24 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( CPMHits_v1 , int , module , setModule )
25 AUXSTORE_PRIMITIVE_SETTER_AND_GETTER( CPMHits_v1 , int , peak , setPeak )
26 AUXSTORE_OBJECT_SETTER_AND_GETTER( CPMHits_v1 , std::vector<unsigned int> , hitsVec0 , setHitsVec0 )
27 AUXSTORE_OBJECT_SETTER_AND_GETTER( CPMHits_v1 , std::vector<unsigned int> , hitsVec1 , setHitsVec1 )
28
29 void CPMHits_v1::addHits(const std::vector<unsigned int>& hits0,const std::vector<unsigned int>& hits1)
30 {
31 setHitsVec0( hits0 );
32 setHitsVec1( hits1 );
33 }
34
35 unsigned int CPMHits_v1::hitWord0() const
36 {
37 return hitsVec0()[ peak() ];
38 }
39
40 unsigned int CPMHits_v1::hitWord1() const
41 {
42 return hitsVec1()[ peak() ];
43 }
44
45} // namespace xAOD
#define AUXSTORE_PRIMITIVE_SETTER_AND_GETTER(CL, TYPE, NAME, SETTER)
Macro creating the accessors of primitive auxiliary properties.
#define AUXSTORE_OBJECT_SETTER_AND_GETTER(CL, TYPE, NAME, SETTER)
Macro creating the accessors of complex auxiliary properties.
AuxElement()
Default constructor.
Description of CPMHits_v1.
Definition CPMHits_v1.h:23
void addHits(const std::vector< unsigned int > &hits0, const std::vector< unsigned int > &hits1)
unsigned int hitWord1() const
get hitword for hitsVec1[peak] - time slice that (hopefully) contains the collision
void setHitsVec1(const std::vector< unsigned int > &)
set hitsVec1 - hits for all time slices
const std::vector< unsigned int > & hitsVec0() const
get hitsVec0 - hits for all time slices
int peak() const
get peak
unsigned int hitWord0() const
get hitword for hitsVec0[peak] - time slice that (hopefully) contains the collision
void setHitsVec0(const std::vector< unsigned int > &)
set hitsVec0 - hits for all time slices
const std::vector< unsigned int > & hitsVec1() const
get hitsVec1 - hits for all time slices
Forward declaration.
STL namespace.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.