globus_common
18.15
Toggle main menu visibility
Loading...
Searching...
No Matches
globus_memory.h
Go to the documentation of this file.
1
/*
2
* Copyright 1999-2006 University of Chicago
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
16
21
22
#if !defined(GLOBUS_MEMORY_H)
23
#define GLOBUS_MEMORY_H
24
25
/******************************************************************************
26
Include header files
27
******************************************************************************/
28
#include "
globus_types.h
"
29
#include "
globus_module.h
"
30
#include "
globus_thread.h
"
31
32
#ifdef __cplusplus
33
extern
"C"
{
34
#endif
35
45
/******************************************************************************
46
Type definitions
47
******************************************************************************/
48
49
struct
globus_memory_s;
50
typedef
struct
globus_memory_s * globus_memory_t;
51
52
globus_bool_t
53
globus_i_memory_pre_activate();
54
55
globus_bool_t
56
globus_memory_init
(
57
globus_memory_t * mem_info,
58
int
node_size,
59
int
node_count);
60
61
void
*
62
globus_memory_pop_node
(
63
globus_memory_t * mem_info);
64
65
globus_bool_t
66
globus_memory_push_node
(
67
globus_memory_t * mem_info,
68
void
* buf);
69
70
globus_bool_t
71
globus_memory_destroy
(
72
globus_memory_t * mem_info);
73
74
75
#ifdef __cplusplus
76
}
77
#endif
78
79
#endif
/* GLOBUS_MEMORY_H */
globus_module.h
Reference Counting Module Activation and Deactivation.
globus_thread.h
Globus Threading Abstraction.
globus_types.h
Common Primitive Types.
globus_bool_t
int globus_bool_t
Boolean type.
Definition
globus_types.h:93
globus_memory_push_node
globus_bool_t globus_memory_push_node(globus_memory_t *mem_info, void *buf)
Return a memory item to the pool.
Definition
globus_memory.c:236
globus_memory_destroy
globus_bool_t globus_memory_destroy(globus_memory_t *mem_info)
Destroy a memory pool.
Definition
globus_memory.c:277
globus_memory_init
globus_bool_t globus_memory_init(globus_memory_t *mem_info, int node_size, int node_count)
Initialize memory pool.
Definition
globus_memory.c:99
globus_memory_pop_node
void * globus_memory_pop_node(globus_memory_t *mem_info)
Retrieve a memory item from a pool.
Definition
globus_memory.c:191
globus_memory.h
Generated by
1.17.0