ATLAS Offline Software
SurfaceUniquePtrT.h
Go to the documentation of this file.
1 // This file's extension implies that it's C, but it's really -*- C++ -*-.
2 
3 /*
4  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // $Id$
16 #ifndef TRKEVENTPRIMITIVES_SURFACEUNIQUEPTRT_H
17 #define TRKEVENTPRIMITIVES_SURFACEUNIQUEPTRT_H
18 #include <memory>
19 
20 namespace Trk {
21 
22 template <class S>
24 {
25 public:
26  void operator() (const S* p) {
27  if (p && p->isFree()) { delete p; }
28  }
29 };
30 
31 template <class S>
32 using SurfaceUniquePtrT = std::unique_ptr<S, SurfaceDeleter<S> >;
33 
34 } // namespace Trk
35 
36 #endif
JetTiledMap::S
@ S
Definition: TiledEtaPhiMap.h:44
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
Trk::SurfaceDeleter
Definition: SurfaceUniquePtrT.h:24
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
Trk::SurfaceUniquePtrT
std::unique_ptr< S, SurfaceDeleter< S > > SurfaceUniquePtrT
Definition: SurfaceUniquePtrT.h:32
Trk::SurfaceDeleter::operator()
void operator()(const S *p)
Definition: SurfaceUniquePtrT.h:26