23 {
24
25
27 CHECK(h_caloCells.isValid());
28
29 const auto & allCaloCells = *h_caloCells;
30
31
32
34 ATH_MSG_ERROR(
"CaloCellCollection does not contain LAREM cells");
35 return StatusCode::FAILURE;
36 }
37
38 std::vector<const CaloCell*>
41
42
44 return
45 calocell_id->calo_sample(calocell_id->calo_cell_hash(
cell->ID())) ==
46 CaloCell_Base_ID::EMB1;
47 };
48
49
50 std::vector<const CaloCell*> emb1_cells;
51 std::copy_if(laremCells.cbegin(),
52 laremCells.cend(),
53 std::back_inserter(emb1_cells),
54 EMB1_sel);
55
56 cells.push_back(std::move(emb1_cells));
57
58 return StatusCode::SUCCESS;
59}
#define CHECK(...)
Evaluate an expression and check for errors.
const CaloCell_ID * m_calocell_id
SG::ReadHandleKey< CaloCellContainer > m_caloCellsKey
virtual StatusCode cells(std::vector< std::vector< const CaloCell * > > &, const EventContext &) const override
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())