ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PHTrackSetCopyMerging.cc
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file PHTrackSetCopyMerging.cc
2 
3 #include "AssocInfoContainerv1.h"
4 
10 
12 #include <fun4all/SubsysReco.h> // for SubsysReco
13 
14 #include <phool/PHCompositeNode.h>
15 #include <phool/PHIODataNode.h>
16 #include <phool/PHNode.h> // for PHNode
17 #include <phool/PHNodeIterator.h>
18 #include <phool/PHObject.h> // for PHObject
19 #include <phool/getClass.h>
20 #include <phool/phool.h> // for PHWHERE
21 
22 #include <iostream> // for operator<<, basic_os...
23 
24 using namespace std;
25 
27  : PHTrackSetMerging(name)
28 {
29 }
30 
31 
33 {
34 
35  if (!_track_map_in1){
36  cerr << PHWHERE << " ERROR: Can't find " << _track_map_name_in1 << endl;
38  }
39  if (!_track_map_in2){
40  cerr << PHWHERE << " ERROR: Can't find " << _track_map_name_in2 << endl;
42  }
43  //copy track map 1 to output track map
44  /*
45  // make a list of tracks that did not make the keep list
46  for(auto track_it = _track_map_in1->begin(); track_it != _track_map_in1->end(); ++track_it)
47  {
48  // auto id = track_it->first;
49  SvtxTrack *_track = track_it->second;
50 
51  _track_map_out->insert(_track);
52  */
53  //copy track map 2 to output track map
54  for(auto track_it = _track_map_in2->begin(); track_it != _track_map_in2->end(); ++track_it)
55  {
56  //auto id = track_it->first;
57  SvtxTrack *_track = track_it->second;
58 
59  // _track_map_out->insert(_track);
60  _track_map_in1->insert(_track);
61  }
62 
64 }
65 /*
66 int PHTrackSetCopyMerging::Setup(PHCompositeNode* topNode)
67 {
68  int ret = CreateNodes(topNode);
69  if (ret != Fun4AllReturnCodes::EVENT_OK) return ret;
70 
71  ret = GetNodes(topNode);
72  if (ret != Fun4AllReturnCodes::EVENT_OK) return ret;
73 
74  return Fun4AllReturnCodes::EVENT_OK;
75 }
76 
77 int PHTrackSetMerging::End(PHCompositeNode* topNode)
78 {
79  return Fun4AllReturnCodes::EVENT_OK;
80 }
81 */