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
Hypertable
RangeServer
CellCacheAllocator.h
Go to the documentation of this file.
1
/* -*- c++ -*-
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
20
#ifndef HYPERTABLE_CELLCACHE_ALLOCATOR_H
21
#define HYPERTABLE_CELLCACHE_ALLOCATOR_H
22
23
#include "
Common/PageArenaAllocator.h
"
24
25
namespace
Hypertable
{
26
27
struct
CellCachePageAllocator
:
DefaultPageAllocator
{
28
void
*
allocate
(
size_t
sz);
29
void
freed
(
size_t
sz);
30
};
31
32
typedef
PageArena<uint8_t, CellCachePageAllocator>
CellCacheArena
;
33
34
template
<
typename
T,
class
Impl = PageArenaAllocator<T, CellCacheArena> >
35
struct
CellCacheAllocator
: Impl {
36
template
<
typename
U>
37
CellCacheAllocator
(
const
PageArenaAllocator<U, CellCacheArena>
&other)
38
: Impl(other) {}
39
40
template
<
typename
U>
41
struct
rebind
{
typedef
PageArenaAllocator<U, CellCacheArena>
other
; };
42
43
CellCacheAllocator
() {}
44
CellCacheAllocator
(CellCacheArena &arena) : Impl(arena) {}
45
};
46
47
}
// namespace Hypertable
48
49
#endif
/* HYPERTABLE_CELLCACHE_ALLOCATOR_H */
Hypertable::DefaultPageAllocator
A memory allocator using std::malloc() and std::free().
Definition:
PageArena.h:52
Hypertable::CellCacheAllocator::rebind
Definition:
CellCacheAllocator.h:41
Hypertable::CellCacheAllocator::rebind::other
PageArenaAllocator< U, CellCacheArena > other
Definition:
CellCacheAllocator.h:41
PageArenaAllocator.h
PageArena memory allocator for STL classes.
Hypertable::PageArenaAllocator
The PageArenaAllocator is a STL allocator based on PageArena.
Definition:
PageArenaAllocator.h:47
Hypertable::CellCacheAllocator::CellCacheAllocator
CellCacheAllocator()
Definition:
CellCacheAllocator.h:43
Hypertable::CellCacheAllocator::CellCacheAllocator
CellCacheAllocator(CellCacheArena &arena)
Definition:
CellCacheAllocator.h:44
Hypertable::CellCacheAllocator
Definition:
CellCacheAllocator.h:35
Hypertable::CellCacheArena
PageArena< uint8_t, CellCachePageAllocator > CellCacheArena
Definition:
CellCacheAllocator.h:32
Hypertable::CellCachePageAllocator::freed
void freed(size_t sz)
Definition:
CellCacheAllocator.cc:31
Hypertable::PageArena< uint8_t, CellCachePageAllocator >
Hypertable::CellCachePageAllocator::allocate
void * allocate(size_t sz)
Definition:
CellCacheAllocator.cc:26
Hypertable::CellCachePageAllocator
Definition:
CellCacheAllocator.h:27
Hypertable
Hypertable definitions
Definition:
ApplicationHandler.h:36
Hypertable::CellCacheAllocator::CellCacheAllocator
CellCacheAllocator(const PageArenaAllocator< U, CellCacheArena > &other)
Definition:
CellCacheAllocator.h:37
Generated on Tue Dec 22 2015 18:43:15 for Hypertable by
1.8.8