ATLAS Offline Software
RtRelationMultChanContainer.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 namespace TRTCond
8 {
9 
11  {
12  // delete owned objects
13  clear() ;
14  }
15 
18  {
19  *this = rhs ;
20  }
21 
23  {
24  // this is a bit tricky since we own the contents. the following
25  // solution is not particularly efficient, but the least amount of
26  // work for me.
27 
28  // first delete owned objects
29  clear() ;
30 
31  // now create a 'FlatContainer'
32  FlatContainer allentries;
33  rhs.getall(allentries) ;
34 
35  // store them one-by-one
36  for(const auto & entry : allentries)
37  set( entry.first, *(entry.second) ) ;
38 
39  return *this ;
40  }
41 
42 }
TRTCond::MultChanContainer< RtRelationLayerContainer >::set
void set(const ExpandedIdentifier &id, const typename DaughterContainer::value_type &t)
set a value
Definition: MultChanContainer.h:219
TRTCond::MultChanContainer< RtRelationLayerContainer >::clear
void clear()
clear all layercontainers
Definition: MultChanContainer.h:303
TRTCond::RtRelationMultChanContainer::operator=
RtRelationMultChanContainer & operator=(const RtRelationMultChanContainer &rhs)
assignment
Definition: RtRelationMultChanContainer.cxx:22
TRTCond::RtRelationMultChanContainer::RtRelationMultChanContainer
RtRelationMultChanContainer()
default constructor
Definition: RtRelationMultChanContainer.h:34
TRTCond::NestedContainer
Definition: NestedContainer.h:373
TRTCond::MultChanContainer
Definition: MultChanContainer.h:44
GetAllXsec.entry
list entry
Definition: GetAllXsec.py:132
TRTCond::RtRelationMultChanContainer::~RtRelationMultChanContainer
virtual ~RtRelationMultChanContainer()
destructor
Definition: RtRelationMultChanContainer.cxx:10
TRTCond
Definition: BasicRtRelation.cxx:8
TRTCond::MultChanContainer::getall
void getall(typename DaughterContainer::FlatContainer &entries) const
get a flat vector with all values.
Definition: MultChanContainer.h:336
RtRelationMultChanContainer.h
Class for storing/accessing trt rtrelations with channels 1;95;0c.
TRTCond::RtRelationMultChanContainer::FlatContainer
RtRelationLayerContainer::FlatContainer FlatContainer
typedef
Definition: RtRelationMultChanContainer.h:32
TRTCond::RtRelationMultChanContainer
Definition: RtRelationMultChanContainer.h:29