8#include "CaloEvent/CaloClusterContainer.h"
9#include "CaloDetDescr/CaloDetDescrElement.h"
12#include "GaudiKernel/MsgStream.h"
32 const std::string& name,
33 const IInterface* parent)
46 clus_iterator iter1 = clusColl->
begin();
49 for( ;iter1!=clusColl->
end(); ) {
52 clus_iterator iter2 = iter1;
53 for( iter2++ ; iter2!=clusColl->
end() ; ){
55 comparison =
compare( (*iter1) , (*iter2) );
57 if( comparison == 1 ){
60 else if( comparison == 2 ){
63 iter2 = clusColl->
erase(iter2);
74 iter1 = clusColl->
erase(iter1);
83 return StatusCode::SUCCESS;
91 double deta = fabs ( clus1->
eta() - clus2->
eta() );
92 double dphi = fabs ( clus1->
phi() - clus2->
phi() );
95 if( fabs( dphi - 6.283185 ) <
m_dphi_cut ) dphi = dphi - 6.283185;
99 if( clus2->
et() > clus1->
et() ){
102 else if( clus1->
et() >= clus2->
et() ){
Definition of CaloDetDescrManager.
An STL vector of pointers that by default owns its pointed-to elements.
int compare(xAOD::CaloCluster *clus1, xAOD::CaloCluster *clus2) const
Gaudi::Property< float > m_dphi_cut
StatusCode execute(const EventContext &ctx, xAOD::CaloClusterContainer *clusColl) const override
Execute on an entire collection of clusters.
CaloClusterRemoveDuplicates(const std::string &type, const std::string &name, const IInterface *parent)
Gaudi::Property< float > m_deta_cut
DataModel_detail::iterator< DataVector > iterator
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
iterator erase(iterator position)
Remove element at a given position.
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
virtual double eta() const
The pseudorapidity ( ) of the particle.
virtual double phi() const
The azimuthal angle ( ) of the particle.
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
CaloClusterContainer_v1 CaloClusterContainer
Define the latest version of the calorimeter cluster container.