ATLAS Offline Software
GenericTOBArray.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 // TOBArray.cxx
5 // TopoCore
6 // Created by Joerg Stelzer on 11/17/12.
7 //
8 // Adapted for GlobalL1TopoSim
9 
10 
11 #include "GenericTOBArray.h"
13 
14 #include <algorithm>
15 
16 namespace GlobalSim {
17 
18  void
21  }
22 
23  void
25  std::sort(m_data.begin(), m_data.end(), fnc);
26  }
27 
28  void GenericTOBArray::print(std::ostream& os) const {
29  for(const_iterator tob = m_data.begin(); tob != m_data.end(); ++tob) {
30  if( tob!=begin() ) os << std::endl;
31  os << **tob;
32  }
33  }
34 }
35 
36 std::ostream& operator << (std::ostream& os,
37  const GlobalSim::GenericTOBArray& gta) {
38  os << "GenericTOB. name: " << gta.name() << ":\n";
39  gta.print(os);
40  os << '\n';
41  return os;
42 }
43 
44 
45 
46 
TCS::DataArrayImpl< TCS::GenericTOB >::const_iterator
data_t::const_iterator const_iterator
Definition: DataArrayImpl.h:18
CompositeTOB.h
TCS::DataArray::name
const std::string & name() const
Definition: DataArray.h:20
GlobalSim::GenericTOBArray::push_back
void push_back(const TCS::CompositeTOB &tob)
Definition: GenericTOBArray.cxx:19
TCS::CompositeTOB::createOnHeap
static CompositeTOB * createOnHeap(const CompositeTOB &tob)
Definition: CompositeTOB.cxx:35
GenericTOBArray.h
GlobalSim
AlgTool to obtain a selection of eFex RoIs read in from the event store.
Definition: dump.h:8
TCS::CompositeTOB
Definition: CompositeTOB.h:16
GlobalSim::GenericTOBArray::print
virtual void print(std::ostream &os) const override
Definition: GenericTOBArray.cxx:28
GlobalSim::GenericTOBArray::sort
void sort(sort_fnc)
Definition: GenericTOBArray.cxx:24
GlobalSim::GenericTOBArray
Definition: GenericTOBArray.h:32
ReadFromCoolCompare.os
os
Definition: ReadFromCoolCompare.py:231
TCS::DataArrayImpl< TCS::GenericTOB >::m_data
data_t m_data
Definition: DataArrayImpl.h:50
TCS::DataArrayImpl< TCS::GenericTOB >::begin
iterator begin()
Definition: DataArrayImpl.h:40
operator<<
std::ostream & operator<<(std::ostream &os, const GlobalSim::GenericTOBArray &gta)
Definition: GenericTOBArray.cxx:36
GlobalSim::sort_fnc
bool() sort_fnc(TCS::GenericTOB *tob1, TCS::GenericTOB *tob2)
Definition: GenericTOBArray.h:29