0.9.8.10
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
home
doug
src
hypertable
src
cc
Common
StlAllocator.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2007-2015 Hypertable, Inc.
3
*
4
* This file is part of Hypertable.
5
*
6
* Hypertable is free software; you can redistribute it and/or
7
* modify it under the terms of the GNU General Public License
8
* as published by the Free Software Foundation; either version 3
9
* of the License, or any later version.
10
*
11
* Hypertable is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
15
*
16
* You should have received a copy of the GNU General Public License
17
* along with Hypertable. If not, see <http://www.gnu.org/licenses/>
18
*/
19
24
#ifndef HYPERTABLE_STL_ALLOCATOR_H
25
#define HYPERTABLE_STL_ALLOCATOR_H
26
27
#include "
PageArenaAllocator.h
"
28
29
namespace
Hypertable
{
30
35
typedef
PageArena<uint8_t, DefaultPageAllocator>
StlArena
;
36
40
template
<
typename
T,
class
Impl = PageArenaAllocator<T, StlArena> >
41
struct
StlAllocator
: Impl {
42
template
<
typename
U>
43
StlAllocator
(
const
PageArenaAllocator<U, StlArena>
&other)
44
: Impl(other) {}
45
46
template
<
typename
U>
47
struct
rebind
{
typedef
PageArenaAllocator<U, StlArena>
other
; };
48
49
StlAllocator
() {}
50
StlAllocator
(StlArena &arena) : Impl(arena) {}
51
};
52
55
}
// namespace Hypertable
56
57
#endif
/* HYPERTABLE_STL_ALLOCATOR_H */
Hypertable::StlAllocator::rebind
Definition:
StlAllocator.h:47
PageArenaAllocator.h
PageArena memory allocator for STL classes.
Hypertable::PageArenaAllocator
The PageArenaAllocator is a STL allocator based on PageArena.
Definition:
PageArenaAllocator.h:47
Hypertable::StlAllocator::rebind::other
PageArenaAllocator< U, StlArena > other
Definition:
StlAllocator.h:47
Hypertable::StlAllocator::StlAllocator
StlAllocator(StlArena &arena)
Definition:
StlAllocator.h:50
Hypertable::StlAllocator::StlAllocator
StlAllocator()
Definition:
StlAllocator.h:49
Hypertable::StlAllocator
Stl compatible memory allocator based on a PageArena.
Definition:
StlAllocator.h:41
Hypertable::PageArena
The PageArena allocator is simple and fast, avoiding individual mallocs/frees.
Definition:
PageArena.h:69
Hypertable
Hypertable definitions
Definition:
ApplicationHandler.h:36
Hypertable::StlAllocator::StlAllocator
StlAllocator(const PageArenaAllocator< U, StlArena > &other)
Definition:
StlAllocator.h:43
Hypertable::StlArena
PageArena< uint8_t, DefaultPageAllocator > StlArena
Definition:
StlAllocator.h:35
Generated on Tue Dec 22 2015 18:43:07 for Hypertable by
1.8.8