ATLAS Offline Software
Arena.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-2017 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // $Id: Arena.h 470529 2011-11-24 23:54:22Z ssnyder $
8 
215 #ifndef ATLALLOCATORS_ARENA_H
216 #define ATLALLOCATORS_ARENA_H
217 
218 
219 #include "AthAllocators/ArenaBase.h"
223 #include <cstdlib>
224 #include <string>
225 #include <ostream>
226 
227 
228 namespace SG {
229 
230 
236 class Arena
237  : public SG::ArenaBase
238 {
239 public:
246  Arena (const std::string& name, ArenaHeader* header = 0);
247 
248 
252  ~Arena();
253 
254 
258  ArenaHeader* header();
259 
260 
266 
267 
272  class Push
273  {
274  public:
275 
280  Push (Arena& a);
281 
282 
286  ~Push();
287 
288 
289  private:
292 
295  };
296 
297 
298 private:
301 };
302 
303 
304 } // namespace SG
305 
306 
307 #endif // not ATLALLOCATORS_ARENA_H
SG::Arena::Push::m_header
ArenaHeader * m_header
The ArenaHeader for the stack we're managing.
Definition: Arena.h:291
header
Definition: hcg.cxx:526
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
SG::Arena::header
ArenaHeader * header()
Return the ArenaHeader with which this Arena is associated.
Definition: Arena.cxx:49
SG::Arena::makeCurrent
ArenaBase * makeCurrent()
Make this Arena the current one for its ArenaHeader.
Definition: Arena.cxx:59
SG::Arena::Push::m_prev
ArenaBase * m_prev
The previously-current arena.
Definition: Arena.h:294
ArenaAllocatorCreator.h
Provide an interface for creating an arena Allocator. See Arena.h for an overview of the arena-based ...
ArenaHeader.h
Proxy for a group of Arenas. See Arena.h for an overview of the arena-based memory allocators.
SG::ArenaHeader
Proxy for a group of Arenas.
Definition: ArenaHeader.h:54
ArenaAllocatorBase.h
Common base class for arena allocator classes. See Arena.h for an overview of the arena-based memory ...
SG::Arena
Collection of memory allocators with a common lifetime,.
Definition: Arena.h:238
SG::ArenaBase
Part of Arena dealing with the list of allocators.
Definition: ArenaBase.h:42
SG::Arena::~Arena
~Arena()
Destructor.
Definition: Arena.cxx:40
SG::Arena::Arena
Arena(const std::string &name, ArenaHeader *header=0)
Constructor.
Definition: Arena.cxx:26
ArenaBase.h
Part of Arena dealing with the list of allocators. Broken out from Arena to avoid a dependency loop w...
a
TList * a
Definition: liststreamerinfos.cxx:10
SG::Arena::Push::~Push
~Push()
Destructor.
Definition: Arena.cxx:79
SG::Arena::m_header
ArenaHeader * m_header
The ArenaHeader with which we're associated.
Definition: Arena.h:300
SG::Arena::Push::Push
Push(Arena &a)
Constructor.
Definition: Arena.cxx:69
SG::ArenaBase::name
const std::string & name() const
Return this Arena's name.
Definition: ArenaBase.cxx:114
SG::Arena::Push
Helper class for making Arena instances current in a stack-like manner.
Definition: Arena.h:273