1#include "Tracking/Digitization/SiElectrodeDataCollection.h"
4namespace digitization {
6SiElectrodeDataCollection::SiElectrodeDataCollection(
7 const SiElectrodeDataCollection& electrode_data) {
8 collection_ = electrode_data.getCollection();
9 electrode_pass_name_ = electrode_data.getPassName();
12SiElectrodeDataCollection::SiElectrodeDataCollection(
14 const std::string& passName) {
15 electrode_pass_name_ = passName;
16 for (
auto pair : electrode_charge) {
17 collection_[pair.first] = SiElectrodeData(pair.second, hit);
21std::map<int, int> SiElectrodeDataCollection::getChargeMap()
const {
22 std::map<int, int> charge_map;
24 for (
auto pair : collection_) {
25 charge_map[pair.first] = pair.second.getCharge();
31const std::string& SiElectrodeDataCollection::getPassName()
const {
32 return electrode_pass_name_;
35void SiElectrodeDataCollection::add(
36 const std::map<int, SiElectrodeData>& electrode_data_collection) {
37 for (
auto pair : electrode_data_collection) {
39 if (collection_.count(pair.first))
40 collection_[pair.first].add(pair.second);
43 collection_[pair.first] = pair.second;
47void SiElectrodeDataCollection::add(
int cellid,
48 SiElectrodeData electrode_data) {
49 if (electrode_data.isValid())
50 if (collection_.count(cellid))
51 collection_[cellid].add(electrode_data);
53 collection_[cellid] = electrode_data;
Represents a simulated tracker hit in the simulation.
The measurement calibrator can be a function or a class/struct able to retrieve the sim hits containe...